Please login or register.

Login with username, password and session length
Advanced search  

News:

Latest sNews - sNews 1.7 - with its own forums - for discussion and user mods.

Pages: 1 [2]

Author Topic: [MOD] Site Offline  (Read 4405 times)

Pein

  • Newbie
  • *
  • Karma: 0
  • Posts: 28
  • n0 n33d t0 b3 l33t
Re: [MOD] Site Offline
« Reply #15 on: December 24, 2010, 01:34:14 PM »

It works great in the newest sNews!

But a little change has been done.

Changes:
4. In function settings()
Find
Code: [Select]
echo '<p><a onclick="toggle(\'sub5\')" style="cursor: pointer;" title="'.l('a_openclose').''.l('comments').'">'.l('comments').'</a></p>';
Add before it:
Code: [Select]
# Offline status
echo '<p><a onclick="toggle(\'sub5\')" style="cursor: pointer;" title="'.l('a_openclose').''.l('offline').'">'.l('offline_maint').'</a></p>';   
echo '<div id="sub5" style="display: none;">';
echo html_input('checkbox', 'offline', 'offline', '', l('offline'), '', '', '', '', (s('offline') == 'on' ? 'ok' : ''), '', '', '', '', '');
$message = retrieve('text','articles','title','Offline');
echo html_input('textarea', 'offline_mess', 'offline_mess', $message, l('offline_mess'), '', '', '', '', '', '2', '100', '', '', '');
echo '</div>';

But ive got a problem, when i change the status to ON, i cant see the page aswell, but still im logged in as admin.
What can be here the problem?

Thanks!
Dai
Logged
Pages: 1 [2]