Archive for December, 2008

Create a select option using javascript with the euro symbol in the text

December 5, 2008

This didn’t work:

new Option("€"+value,value);

Neither did this:

new Option("€"+value,value);

But this did:

new Option("\u20AC"+value,value);
Advertisements

Zend_Db_Adapter::update() returns number of rows in which values have been changed

December 5, 2008

… and not the number of rows that match the conditions.

Just so you know. Caught me out for a while there – I was using the return value from update() to check that certain values (including a timestamp) were set correctly while at the same time updating the timestamp, but if the method got called twice in a second I’d get zero as a return value the 2nd time because the timestamp was the same and so no values were being changed.