PDA

View Full Version : Avoid changing standard JS-Objects like Date or Function



schmidetzki
17 Nov 2006, 2:31 AM
In addition to yui-ext I use this very good calendar library:
http://www.dynarch.com/projects/calendar/

However both JS-Libs extend the standard JS Date Object - in a different way :-(
Both Libs define a function Date.parseDate().
For this reason I can't use both libs at the same time (without having to patch one of them)

The yui-ext uses the name space YAHOO.ext for all its objects and functions to avoid conflicts with other libs. You should be consequent and avoid changing standard objects because otherwise you STILL are in conflict with other libs otherwise.