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
| var PaktPub = (function () { | |
| "use strict"; | |
| var freeLearningURL = 'https://www.packtpub.com/packt/offers/free-learning', | |
| logoutURL = 'https://www.packtpub.com/logout'; | |
| var notify = function (message, timeout) { | |
| var useNotificationAPI = false; | |
| if ("Notification" in window) { | |
| if (Notification.permission === "granted") { | |
| useNotificationAPI = true; | |
| } else if (Notification.permission !== 'denied') { |
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 | |
| function generate_time($timeString='now'){ | |
| $datetime = new \DateTime($timeString); | |
| $string = sprintf("%02d-%06d-%08d-%02d", | |
| mt_rand(0,99), | |
| $datetime->format('u'), | |
| ( | |
| $datetime->format('z')*24*60*60 | |
| + $datetime->format('H')*60*60 |
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 | |
| use Symfony\Component\ClassLoader\ClassMapGenerator; | |
| $loader = require_once __DIR__ . '/../app/bootstrap.php.cache'; | |
| require_once __DIR__ . '/../app/AppKernel.php'; | |
| $kernel = new AppKernel('dev', true); | |
| $kernel->loadClassCache(); | |
| $kernel->boot(); |
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 | |
| error_reporting(0); | |
| ini_set('display_errors', false); | |
| # VALIDATION | |
| if (!isset($_GET['uid'], $_GET['key'], $_GET['type'])) { | |
| http_response_code(400); | |
| die('No request params!'); | |
| } |
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
| javascript:{var%20whitespace%20=%20"-\/|.,!:;'\"%20\t\n\r{}[]()";var%20stack%20=%20[];var%20curNIndex%20=%200;var%20curNode%20=%20null;var%20curIndex%20=%20-1;var%20state%20=%201;var%20lastword%20=%20'';String.prototype.startsWith%20=%20function(prefix)%20{return%20this.indexOf(prefix)%20===%200;};String.prototype.endsWith%20=%20function(suffix)%20{return%20this.match(suffix+"$")%20==%20suffix;};/*%20Nie%20moge%20tak%20robi%C4%87%20niestety%20*/function%20kurwizeLink(url){if(url.startsWith('javascript:'))return%20url;%20/*%20chyba%20niewiele%20moge%20zrobic%20kurwa%20*/if(url.startsWith('#'))return%20url;if(url.startsWith('https://www.google.pl'))return%20url;%20/*%20no,%20bo%20kurwa,%20bez%20jaj%20;p%20*/var%20base%20=%20'';if(!url.startsWith('http')){base%20=%20location.protocol%20+%20"://"%20+%20location.host;if(!url.startsWith('/')){var%20pathname%20=%20location.pathname;base%20+=%20pathname.substring(0,%20pathname.lastIndexOf('/'));}}return%20'http://kurwa.keraj.net/?url='+base+url;};function%20nextLette |
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 | |
| class HexTools | |
| { | |
| private static $verbalMap = [ | |
| '00' => 'zero', | |
| '-0' => '', | |
| '0-' => '', | |
| '-1' => 'one', | |
| '1-' => 'teen', |
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_PATh="/opt/php-7.1/bin/php" | |
| APP_ROOT_DIR="/web/" | |
| MAIN_LANG="pl-PL" | |
| with_dry_run="y" | |
| themes_dir_name="themes/" | |
| translations_dir_name='translations/' | |
| template_file_name='templates/example.tpl' |
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
| #!/usr/bin/env bash | |
| cd $(dirname $0) | |
| files="$@" | |
| if [[ -z "$files" ]]; then | |
| files="$(ls *.puml)" | |
| fi | |
| java -jar plantuml.jar -v -tpng $files | |
| exit |
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 | |
| if (is_file(__DIR__ . '/sites/sites.php')) { | |
| $sites = []; | |
| include __DIR__ . '/sites/sites.php'; | |
| $domains = []; | |
| foreach ($sites as $host => $locale) { | |
| $environment = preg_match('(site\.pride\.gl)', $host) ? 'stage' : 'prod'; | |
| [$language, $country] = explode('_', $locale); | |
| $domains[$country][$language][$environment] = $host; |
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
| POLICY_FILE = "${HOME}/Applications/mmpk/java.policy" | |
| SPLASH_FILE = "${HOME}/Applications/mmpk/logo5.png" | |
| JNLP_FILE = "${HOME}/Applications/mmpk/edytor_polaczen_mmpk.jnlp" | |
| APP_NAME = "Edytor-połączeń-mMPK.info" | |
| install: | |
| @printf "Prepare JAVA policy file " | |
| @echo '' > ${POLICY_FILE} | |
| @echo 'grant {' >> ${POLICY_FILE} | |
| @echo ' permission java.awt.AWTPermission "accessClipboard";' >> ${POLICY_FILE} | |
| @echo ' permission java.security.AllPermission;' >> ${POLICY_FILE} |
OlderNewer