|
|
| Author |
Message |
Mighty Gorgon
Not So New User

Joined: 10 Aug 2007
Posts: 39
Location: Italy
|
Posted: July 15th 2008, 3:01 am Post subject: |
|
|
Well... I understand your point.
In any case I think you can follow even an alternative solution: write a PHP file which opens and edits all the overall_footer.html with the proper code inclusion.
It is not difficult, and you will have the job done in the proper way.
If you are willing to adopt this solution I may have a further look into this and let you know.  _________________ Luca |
|
| Back to top |
|
 |
Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12597
Location: Harbinger, NC, U.S.A.
|
|
| Back to top |
|
 |
Mighty Gorgon
Not So New User

Joined: 10 Aug 2007
Posts: 39
Location: Italy
|
Posted: July 18th 2008, 3:58 am Post subject: |
|
|
No problem, just let me know if is working fine. _________________ Luca |
|
| Back to top |
|
 |
Daniel St. Jules
Not So New User
Joined: 25 Jun 2008
Posts: 26
Location: Canada
|
Posted: July 18th 2008, 2:47 pm Post subject: |
|
|
Well, seeing as you're trying to implement a new feature without the creation of new template variables, I can think of one option. Assign the inclusion of the file to an already existing template variable that's common to all styles. First variable that comes to mind? {META} - it's used in both overall_header.html and simple_header.html, so your code would be included in every page. Unfortunately, I don't have access to phpBB3's source files to look for exactly where it's defined, but I'm sure it wouldn't be that difficult to locate. I'd just do a search for the word meta in functions.php or something along the lines of that. _________________ My phpBB styles: GuildWarsAlliance, DarkFantasy, 610nm, twilightBB
My Sites: Gamexe.net, TheBrawl.net
I'm also known as Daniel Exe in the phpBB community |
|
| Back to top |
|
 |
Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12597
Location: Harbinger, NC, U.S.A.
|
|
| Back to top |
|
 |
Daniel St. Jules
Not So New User
Joined: 25 Jun 2008
Posts: 26
Location: Canada
|
Posted: July 21st 2008, 9:12 pm Post subject: |
|
|
Well, had you wanted to just include a js file in every page, and that's all? Because my solution is limited to includes which could be placed between the <head> tags, so it would work fine with the inclusion of a javascript file or css stylesheet, but not much more. _________________ My phpBB styles: GuildWarsAlliance, DarkFantasy, 610nm, twilightBB
My Sites: Gamexe.net, TheBrawl.net
I'm also known as Daniel Exe in the phpBB community |
|
| Back to top |
|
 |
Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12597
Location: Harbinger, NC, U.S.A.
|
|
| Back to top |
|
 |
Daniel St. Jules
Not So New User
Joined: 25 Jun 2008
Posts: 26
Location: Canada
|
Posted: July 22nd 2008, 9:15 pm Post subject: |
|
|
Alright, to do what I had mentioned in my earlier posts, thus including a js file in every page of your phpBB3 installation without the need of modifying styles to insert new template variables, you would have to open up includes/functions.php and find:
| Code:
|
'META' => '
<meta http-equiv="refresh" content="' . $time . ';url=' . str_replace('&', '&', $url) . '" />')
|
Replace with:
| Code:
|
'META' => '<script type="text/javascript" src="file.js"></script>\n
<meta http-equiv="refresh" content="' . $time . ';url=' . str_replace('&', '&', $url) . '" />')
|
Find:
| Code:
|
|
'PRIVATE_MESSAGE_INFO_UNREAD' => $l_privmsgs_text_unread,
|
After, add:
| Code:
|
|
'META' => '<script type="text/javascript" src="file.js"></script>\n',
|
Of course, you'd then replace file.js with the full path or url to the javascript file that you'd like to include. It's a simple fix, but it gets the job done.  _________________ My phpBB styles: GuildWarsAlliance, DarkFantasy, 610nm, twilightBB
My Sites: Gamexe.net, TheBrawl.net
I'm also known as Daniel Exe in the phpBB community |
|
| Back to top |
|
 |
Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12597
Location: Harbinger, NC, U.S.A.
|
|
| Back to top |
|
 |
|