This file contains 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 | |
// wcf imports | |
require_once(WCF_DIR.'lib/data/user/User.class.php'); | |
require_once(WCF_DIR.'lib/data/user/option/UserOptionOutput.class.php'); | |
require_once(WCF_DIR.'lib/data/user/option/UserOptionOutputContactInformation.class.php'); | |
/** | |
* UserOptionOutputDeviantart is an implementation of UserOptionOutput for the output of a user deviantart account. | |
* | |
* @author Sascha Ehrler |
This file contains 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 | |
// wcf imports | |
require_once(WCF_DIR.'lib/data/user/User.class.php'); | |
require_once(WCF_DIR.'lib/data/user/option/UserOptionOutput.class.php'); | |
require_once(WCF_DIR.'lib/data/user/option/UserOptionOutputContactInformation.class.php'); | |
/** | |
* UserOptionOutputEmail is an implementation of UserOptionOutput for the output of a user email. | |
* | |
* @author Marcel Werk |
This file contains 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
#main { | |
border: 1px solid red; | |
margin: 5px; | |
} | |
#main > div { | |
flex-direction: row; | |
display: flex; | |
height: 500px; | |
} | |
#content, aside { |
This file contains 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
Smarty3 vs Twig vs Cytro | |
Generate templates... Done | |
Testing a lot output... | |
smarty3: !compiled and !loaded 8.6070 sec, 14.8 MiB | |
smarty3: compiled and !loaded 0.0434 sec, 7.8 MiB | |
smarty3: compiled and loaded 0.0058 sec, 7.8 MiB | |
twig: !compiled and !loaded 4.2420 sec, 67.2 MiB | |
twig: compiled and !loaded 0.0927 sec, 16.0 MiB |
This file contains 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
swap = -> | |
inputVar = parseInt document.getElementById('userInput').value | |
return undefined unless inputVar? | |
output.innerHTML = '' | |
inputVar *= -1 if inputVar < 0 | |
copy = inputVar | |
count = 1 |
This file contains 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
$sql = "UPDATE wcf".WCF_N."_page_menu_item | |
SET isLandingPage = 0"; | |
$statement = WCF::getDB()->prepareStatement($sql); | |
$statement->execute(); | |
$sql = "SELECT menuItemID | |
FROM wcf".WCF_N."_page_menu_item | |
WHERE menuPosition = ? | |
AND parentMenuItem = ? | |
AND menuItemController <> ? |
This file contains 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
/** | |
* The first commented line is your dabblet’s title | |
*/ | |
@media (max-width: 480px) { | |
#content:before {content: "width <= 480"; } | |
} | |
@media (max-device-width: 480px) { | |
#content2:before {content: "device-width <= 480"; } | |
} |
This file contains 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
#!/usr/bin/php | |
<?php | |
$type = $argv[1]; | |
echo "Forcing map-save\n"; | |
exec("screen -p 0 -S ".$type." -X eval 'stuff \"save-off\"\015'"); | |
exec("screen -p 0 -S ".$type." -X eval 'stuff \"save-all\"\015'"); | |
exec("screen -p 0 -S ".$type." -X eval 'stuff \"say Backup gestartet\"\015'"); | |
$time = time(); | |
echo "Creating backup /home/minecraft/BACKUP/".$type."/world_".date('Y.m.d_H:i:s', $time).".tar.gz\n"; | |
exec('cd /home/minecraft/'.$type.' && tar -czvf /home/minecraft/BACKUP/'.$type.'/world_'.date('Y.m.d_H:i:s', $time).'.tar.gz world_new world_new_nether plugins --exclude dynmap', $output); |
This file contains 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 | |
$start = strtotime('first day of last Month 00:00:00'); | |
$end = strtotime('last day of last month 23:59:59'); |
This file contains 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
@font-face { | |
font-family: 'FontAwesome'; | |
src: url('../font/fontawesome-webfont.eot?v=3.0.1'); | |
src: url('../font/fontawesome-webfont.eot?#iefix&v=3.0.1') format('embedded-opentype'), | |
url('../font/fontawesome-webfont.woff?v=3.0.1') format('woff'), | |
url('../font/fontawesome-webfont.ttf?v=3.0.1') format('truetype'); | |
font-weight: normal; | |
font-style: normal; | |
} |