1 (edited by mi 2004-12-03 14:49)

Topic: Editing functions.php gives error!

Editing functions.php in any way whatsoever gives error:
"cannot change headers, headers already sent from ...." etc.

I wanted to add a link inside the area after check if a member or not, so as to have link only visible if you are a member. But even just touching the file, removing a totally empty line...gives the error...

I cleaned browser cache, restarted browser, etc - nothing helped .... what gives?

(oh, i am still on 1.1.5)

edit: only remedy was to copy a fresh functions.php from local disk... undoing and resaving any change still gave the error.

New Friendly web-shop! • SO happy with PunBB! • Now punBB 1.4.x on ALL forums (won't tell how many or their addresses to avoid spam-regs)

Re: Editing functions.php gives error!

My guess is that your editor, for some odd reason, adds a linebreak before the first <?php or something odd like that. The only reason "cannot change headers, headers already sent from..." would pop up is if functions.php was outputting data (and it shouldn't unless you call a function that outputs data). Try modifying it in a different editor.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

3 (edited by mi 2004-12-04 17:00)

Re: Editing functions.php gives error!

odd indeed!
using good'ol dreamweaver and never happened before...edited a good number of php files, i have...

}
^

after the very last "parenthesis", it added the funny character... just so you know you were right wink

edit: works like a charm now, editing in other text editor - got much into right place now on navigation-line - again: THANK you for unparallelled support!

New Friendly web-shop! • SO happy with PunBB! • Now punBB 1.4.x on ALL forums (won't tell how many or their addresses to avoid spam-regs)