Created
April 1, 2011 03:59
-
-
Save nojimage/897705 to your computer and use it in GitHub Desktop.
for April fool setting
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- ..snip.. --> | |
<?php if (Configure::read('AprilFool')) : ?> | |
fool content write here! | |
<?php endif; ?> | |
<?php __('Any Message'); ?> | |
<!-- ..snip.. --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// app/config/bootstrap.php | |
// (..snip..) | |
// April fool | |
Configure::write('AprilFool', false); | |
$_time = time(); | |
if (strtotime('2011-04-01 00:00:00') < $_time && $_time < strtotime('2011-04-02 00:00:00')) { | |
Configure::write('AprilFool', true); | |
Configure::write('Config.language', 'apr'); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<!-- ..snip.. --> | |
<?php if (Configure::read('AprilFool')) : ?> | |
<?php echo $this->Html->css('april.css'); ?> | |
<?php endif; ?> | |
</head> | |
<body> | |
<!-- ..snip.. --> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment