Page 1 of 1

Javascript in Portal only

Posted: 6. August 2010 08:31
by Rene
Your Portal Version: 1.05
Your phpBB Type: Standard phpBB3
MODs installed: Yes
Your knowledge: Advanced Knowledge

What have you done before the problem was there?
Added javascript to overall_header.html

What have you already tryed to solve the problem?
Looked in the portal to see where I might include a javascript

Description and Message
Hi,
I changed the menu in the portal and have a javascript file that is needed. I added it to overall_header.html in prosilver which is fine except that when I'm not on portal.php, it throws an error since the code is only being used on the portal. It's not a huge deal. Everything still works fine it's just that I get the error in the status bar. Is there any way to add javascript to just the portal? Could I add some "page" that I could include that would add the javascript to the header or is overall_header.html the only place to do this?

thanks for any help or suggestions you might have!! :)

Re: Javascript in Portal only

Posted: 6. August 2010 12:59
by talonos
put the code inside of your menu html file instead of your overall_header. that way it will only load when the menu is loaded