Great concept. I would also be interested in even helping you develop this plugin. Simply because it is a great head start on something I already need myself. However, it’s current state has some serious design flaws. So I have made a little thing below for you to read. These are the things I will be changing within the plugin for my own site’s usage. I have also commented on why it is important to make these changes.
Tip: NEVER use ID’s unless it is a single component on a page.
Comment: When trying to iterate over multiple items on a page using jQuery
cannot find more than one instance of an ID. Items must be found through a class instead. Meaning, #odd or #even, trying to change the background color using jQuery.css() will find the first instance and quit. Even if done from within a jQuery.each() it will find the first instance and abort leaving all other items un-touched. Iterations can only be done via a class. The easy way to remember this is only a single instance can have an ID. just like a database, you cant have 2 items with the same ID.
Let’s put it this way. ID’s are actually so rarely used for this reason you never find them in professional code.
To prove my point, wordpress templates, made by wordpress, have #page & #respond but everything else is a class.
- The topic ‘Developer Necessities’ is closed to new replies.