Topic: javascript question
hey,
I would like to know what this code is for in header.php
// START SUBST - <body>
if (isset($focus_element))
{
$tpl_main = str_replace('<body onload="', '<body onload="document.getElementById(\''.$focus_element[0].'\').'.$focus_element[1].'.focus();', $tpl_main);
$tpl_main = str_replace('<body>', '<body onload="document.getElementById(\''.$focus_element[0].'\').'.$focus_element[1].'.focus()">', $tpl_main);
}
// END SUBST - <body>
I can't seem to figure out what it does and it is causing a conflict with a piece of javascript I have included in my header.
It doesn't seem to make any noticeable difference if I remove it.
thanks
Nick
see my hack to integrate punbb with wordpress comment system.
Illustration Community