Author Topic: [1.7 / 1.7.1] Edit templates = no changes being saved  (Read 15916 times)

0 Members and 1 Guest are viewing this topic.

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
[1.7 / 1.7.1] Edit templates = no changes being saved
« on: December 07, 2005, 12:51:06 AM »
On servers where register_globals in PHP settings is turned off, editing templates from ACP (Admin Control Panel) will not save the changes.

To fix that, in admin/templates.php find:
Code: [Select]
if (isset($HTTP_GET_VARS['template_folder']) || isset($HTTP_POST_VARS['template_folder'])) {Insert above:
Code: [Select]
if (isset($HTTP_POST_VARS['content'])) {
  $content = trim($HTTP_POST_VARS['content']);
}
else {
  $content = "";
}
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline tatty

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: [1.7 / 1.7.1] Edit templates = no changes being saved
« Reply #1 on: February 23, 2006, 05:28:17 PM »
Thanks for this ;)

Offline vile

  • Pre-Newbie
  • Posts: 8
    • View Profile
Re: [1.7 / 1.7.1] Edit templates = no changes being saved
« Reply #2 on: February 25, 2006, 07:14:54 PM »
hi i've got that same problem because i've got a server but is torned off register_globals
i try to talk for active that but i don't have choise, untill torn off register globals and my 4images shows error

Fatal error: Call to undefined function: show_admin_header() in /var/www/localhost/megaman/htdocs/4images/admin/home.php on line 35
i did what you say V@no but untill sohw me that error

what i must to do?

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: [1.7 / 1.7.1] Edit templates = no changes being saved
« Reply #3 on: February 25, 2006, 08:26:24 PM »
I think you did more that just that...the error comes from home.php file, and the fix above has nothing to do with that file...
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)