Site Moved

This site has been moved to a new location - Bin-Blog. All new post will appear at the new location.

Bin-Blog

Preparations for Naked CSS Day

Six more hours before the Naked CSS Day is upon us. Just some points I want to make before we get to that.

First of all my sudoku pages will not be completely naked. The general formatting will be removed but the formatting for the sudoku puzzle tables will stay. This is because the layout is an important part of the functionality of puzzles.

Next, please feel free to let me know if you find any problems - or if you have any suggestions or any feedback. Just leave me a comment and I will look into it.

I have created a small PHP script that will let your visitors turn on the styles. Jut put this text in the Naked Day notification message...


You can <a href="?styles=1">Turn on the styles</a> if you wish.

Now put this PHP code in the common file...


//This goes at the top of the file
session_start(); //If you have not already started it.
if($_REQUEST['styles'] == 1) {
 $_SESSION['onstyles'] = 1;
}
// .. Lots of code ...

if((gmdate("d") == 5 and gmdate("m") == 4) //If it is the fifth of april, take down the styles.
 or ($_REQUEST['preview'] == 'nostyles') 
 and (!$_SESSION['onstyles'])) { 
   $style_info = '';
   $nostyles_msg = '<h3>What happened to the design?</h3>
<p>To know more about why styles are disabled on this website visit the
<a href="http://naked.dustindiaz.com" title="Web Standards Naked Day Host Website">
Annual CSS Naked Day</a> website for more information.<br />
You can <a href="?styles=1">Turn on the styles</a> if you wish.</p>';
  }

Please refer yesterday's post for more info.

Filed Under...

0 Comments: