I'm in an early stage of redesigning a website and have come across a very annoying problem.
The following JS snippet is necessary to show/hide an arrow to navigate across the page:
.insertBefore('ul#gallery > li:even a');
var galleryeven = $('ul#gallery > li:even:not(:last) div');
var galleryodd = $('ul#gallery > li:odd');
var galleryimg = $('ul#gallery > li > a > img');
Unfortunately it also generates an empty div <div></div> before every <a href. It's clearly visible using Firebug. Without that particular piece of code the page is working perfectly fine too, but I want the arrows to show up on mouseover.
Please find the beta page on http://beta.beautifullalaland.com/scrolltest4.html and check the code (look for <!-- script inserts <div> before a href -->). A textbox with 2 links is at the very end of the gallery.