The Arcive of vBulletin Modifications Site. |
|
Details »»
|
|||||||||||||||||||||||||
im having a problem trying to include global.php in my main page (non-vB)
heres what the top of header.php looks like for my main site: PHP Code:
the two errors i get are: Warning: Cannot add header information - headers already sent by (output started at /home/voogru/public_html/index.php:3) in /home/voogru/public_html/forums/admin/functions.php on line 1610 Warning: Cannot add header information - headers already sent by (output started at /home/voogru/public_html/index.php:3) in /home/voogru/public_html/forums/admin/functions.php on line 1610 i tried everything i can think of, im very new to php so i need help! thanks ![]() Show Your Support
|
|||||||||||||||||||||||||
| Comments |
|
#2
|
||||
|
||||
|
In the
PHP Code:
|
|
#3
|
||||
|
||||
|
not that i know of, no
i belive /* and */ are for commenting out text, right? thats just so when i put more code i cant find different areas easier. |
|
#4
|
||||
|
||||
|
hmmm.. you probably want to have 2 diff headers. this is not the best way to do it (in my oppinion). try this:
01. open root/global.php. 02. find the code: PHP Code:
PHP Code:
PHP Code:
PHP Code:
that should solve your prob .
|
|
#5
|
||||
|
||||
|
i did that but i still get "Warning: Cannot add header information - headers already sent by (output started at /home/voogru/public_html/index.php:3) in /home/voogru/public_html/forums/admin/functions.php on line 1612" my problem is i cant figure out how to get global.php to work on a non-vb page. if someone can tell me how to include it it would be great, right now im trying to use:
PHP Code:
thanks |
|
#6
|
||||
|
||||
|
what i would me is this:
01. create a insertcode.php file with all the code i need to add in specific files and place it in root/forum. 02. call insertcode.php in each file i want to add the specific code. in this way you will never have any problems. |
|
#7
|
||||
|
||||
|
From my very limited experience, I have got these "Cannot add header information" when I have used cpheader() and another <head></head> tag in the same file. Requiring the global.php will (I am guessing) format your page with the standard headers, if your including a another file or complete .html file this might conflict?
Might be worth a try :frus: |
![]() |
|
|