Web Development

Scriptaculous + JS optimizations can cause problems

With everyone raving about YSlow I used it to prune a new project I was doing. Well, after the results worked just great with Safari and Firefox I was thoroughly confused why it wasn't working correctly in IE. The problem was that my Script.aculo.us routines weren't working, and more specifically I was getting really weird errors when the page was loading, before any of the routines executed. Some of the errors were very vague, e.g. "'Class' is undefined", and "Effect.toggle is undefined".

Tags: 

Tip: Passing a shopping cart to Paypal Website Payments Standard

Here's a little tip for anyone using Paypal's Website Payments Standard system for electronic payments on their shopping cart. Their API allows you to pass in a complete shopping cart using a series of form fields listing the items, quantities, etc, as you'd expect. There's one tiny little detail that isn't explicitly stated - the button that you use to submit to the API must not have a name attribute otherwise it will fail. Here's a fully working example to better explain:

Tags: 

Details for iPhone web app development (UPDATED)

Some details have been made available by The University of Washington on how to develop web applications for iPhone - lots of basics in there, like keeping a good separation of HTML and CSS, but also some specifics on e.g. the screen width, some limitations in place, etc. Mandatory reading for anyone doing iPhone apps.

UPDATE: Apparently someone didn't like the info being posted publically, so someone posted a copy of the iPhone details elsewhere.

Tags: 

button_to HTML options not completely intuitive

While working on a site in Rails tonight I was adding a button_to that I wanted a JS confirmation requester. Well, based on my albeit beginner knowledge of Rails I thought the following would work:
[source:ruby]
< %= button_to "Empty Cart", :action => :empty, :confirm => "Really empty your cart?" %>
[/source]

Tags: 

Pages

Subscribe to Web Development