I am in the process of porting a CLI library from Ruby over to Node.js. In my code I execute several third party binaries when necessary. I am not sure how best to accomplish this in Node. Here’s an example in Ruby where I call PrinceXML to convert a file to a PDF: cmd = […]
I’m connecting to a web site, logging in. The website redirects me to new pages and Mechanize deals with all cookie and redirection jobs, but, I can’t get the last page. I used Firebug and did same job again and saw that there are two more pages I had to pass with Mechanize. I took […]
Recently I came across a bug/feature in several languages. I have a very basic knowledge about how it’s caused (and I’d like some detailed explanation), but when I think of all the bugs I must have made over the years, the question is how can I determine “Hey, this might cause a riddiculous bug, I’d […]
Scott Chacon’s Showoff gem is a great alternative to Powerpoint/Keynote… but the fact that it always centers content vertically is annoying. Sometimes you want to force content to the top of the slide. Additionally, there seems to be a bug in that incremental content with images isn’t considered when calculating margin-top, which results in incremental […]
I have a Rails 3 application that queries a Oracle database that stores documents. My Rails application can store the document id but not any content or other meta-data from the document. I also have to send the document number to another webserver (not controlled by my Rails application) to display the document. I wonder […]
I am working on a Rails 2.3 application and would like to refactor some of my static assets (JS, CSS) into a separate gem. The problem is that Rails 2.3 engines don’t have the support for public directories that Rails 3 engines do, so the only way to access these files from the app is […]
My project use Twitter Bootstrap CSS Framework,so my html like this. <div class=”control-group “> <label class=”control-label” for=”user_name”>Username</label> <div class=”controls”> <input data-validate=”true” id=”user_name” name=”user[name]” size=”30″ type=”text”> </div> </div> When validate failed, Client Side Validation change it to: <div class=”control-group “> <div class=”field_with_errors”> <label class=”control-label” for=”user_name”>Username</label> </div> <div class=”controls”> <div class=”field_with_errors”> <input data-validate=”true” id=”user_name” name=”user[name]” size=”30″ type=”text”> […]
I am looking for JS or Ruby library which allows me visually (user front-end) select page elements and identify theirs XPath for further use.