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 | |
namespace SmartCMS; | |
use Nette, | |
Nette\Utils\Html; | |
class BootstrapHorizontalFormRenderer extends Nette\Forms\Rendering\DefaultFormRenderer | |
{ | |
public $wrappers = array( |
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
function checkScroll($parent) { | |
if($parent.scrollBottom() == 300) { | |
$('#social').css(position: 'absolute'); | |
} else { | |
$('#social').css(position: 'fixed'); | |
} | |
} | |
$(document).ready(function() { | |
checkScroll($(this)); |
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
require_once dirname(__FILE__) . '/php-excel.class.php'; | |
$visitors = $this->visitorModel->getAll(); | |
$data = array(); | |
foreach($visitors as $visitor) { | |
$row = array(); | |
$row[] = $visitor->name; | |
$row[] = $visitor->surname; | |
$data[] = $row; | |
} |
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 | |
require_once dirname(__FILE__) . '/nette.min.php'; | |
require_once dirname(__FILE__) . '/dibi.min.php'; | |
if(!isset($_GET['lang'])) { | |
die('Do parametru adresy "lang" vloz zkratku pridavaneho jazyka.'); | |
} else { | |
$lang = $_GET['lang']; | |
} |
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 | |
$row = $model->findName($name); | |
if($row === FALSE) { | |
// $name bylo nejake super exoticke, nemame ho v db | |
return 'Vážená/Vážený ' . $name; | |
} else { | |
if (count($row) == 1) { | |
// jmeno ma v db jenom jeden zaznam, napr. "Lukas"; |
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 | |
class DbRoute extends Object implements IRouter | |
{ | |
protected $absolute = FALSE; | |
public function __construct($absolute = FALSE) | |
{ | |
$this->absolute = $absolute; | |
} |
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
server { | |
error_log /var/log/nginx/skeletis-content.log; | |
rewrite_log on; | |
root /var/www/skeletis-content.cz; | |
index index.html; | |
server_name skeletis-content.cz skeletis-content.loc; | |
location ~* /(\d+)\.(jpg|jpeg|png|gif|bmp)/([a-z0-9]+)/(\d+)x(\d+) { |
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
import React from 'react'; | |
import {StackNavigator} from "react-navigation"; | |
import {AppRegistry, Button} from "react-native"; | |
class MainScreen extends React.Component { | |
static navigationOptions = { | |
title: 'Main' | |
}; | |
render() { |
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 | |
public function moveSubtree($node, $parent) | |
{ | |
$lft = $parent->getRgt(); | |
$lvl = $parent->getLvl() + 1; | |
$diff = $node->getRgt() - $node->getLft() + 1; | |
if ($lft > $node->getLft()) { |
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
curl --location --request POST 'api.plnapenezenka.cz/me/favorite-shops' \ | |
--header 'Content-Type: application/json' \ | |
--header 'Authorization: eyJ0eXAiOiJKV1QiLCJhbGciOiJub25lIiwiY3JlYXRlZEF0IjoxNTgyMTA0MTgxfQ.eyJpc3MiOiJueWtsaWNla0BnbWFpbC5jb20iLCJhdWQiOiJwaGZ6dGw1NDMyNTE0MDkyNGNhNC4zNTgzNTM1MyIsImp0aSI6IjI4MTA3IiwiaWF0IjoxNTgyMTA0MTgxLCJleHAiOjE1ODIxMDc3ODEsInZhbGlkX2Zyb20iOiIyMDIwLTAyLTE5VDEwOjIzOjAxKzAxOjAwIiwiaXNzdWVkX2F0IjoiMjAyMC0wMi0xOVQxMDoyMzowMSswMTowMCIsInZhbGlkX3RvIjoiMjAyMC0wMi0xOVQxMToyMzowMSswMTowMCJ9.' \ | |
--data-raw '{ | |
"shopId": 2534 | |
}' |
OlderNewer