Skip to content

Instantly share code, notes, and snippets.

View wodCZ's full-sized avatar

Martin Janeček wodCZ

View GitHub Profile
<?php
namespace wodCZ\Flysystem\DI;
use Nette;
use Nette\DI\CompilerExtension;
class FlysystemExtension extends CompilerExtension
{
public function loadConfiguration()

Responsive and friendly table

It's a display of tabular data, using divs because I needed a nice and friendly display for mobile.

Color coding, badges and icons

A Pen by Laura Moraiti on CodePen.

License.

@wodCZ
wodCZ / BS3FormRenderer.php
Created April 23, 2015 15:06
BS3FormRenderer
<?php
namespace App\Forms;
use Nette\Forms\Controls;
use Nette\Forms\Form;
/**
* Class BS3FormRenderer
<?php
namespace Libs\Utils;
use Kdyby\Doctrine\EntityManager;
use Nette\DI\Container;
class EntityManagerAccessor
/* global angular,ionic */
(function (angular, ionic) {
'use strict';
angular.module('jett.ionic.scroll.sista', ['ionic'])
.factory('ScrollPositions', function () {
var scrollPositions = {};
return {
set: function (state_name, scrollPos) {
@wodCZ
wodCZ / spinner.ajax.js
Created October 22, 2015 08:48
nette.ajax spinner
(function($, undefined) {
$.nette.ext('spinner', {
init: function () {
},
start: function () {
this.counter++;
if (this.counter === 1) {
$("html").addClass('wait');
@wodCZ
wodCZ / ubuntu-php-development-environment.md
Created October 25, 2015 14:18 — forked from DaRaFF/ubuntu-php-development-environment.md
Ubuntu php development environment

#Introduction If you're a php developer on ubuntu, there comes the time where you have to install/reinstall your system. I did it already a few times and i decided to write down the steps for a typical web developer stack with php. This is for a developer machine and not for a live environment!

I hope it helps you too!

fyi @mheiniger and me started with an installer here: https://github.com/mheiniger/webdev-setup

@wodCZ
wodCZ / BaseForm.php
Last active November 25, 2015 13:03
Form: fill defaults from object
<?php
namespace Libs\Forms;
use Nette\Forms\Controls;
use Nette\Utils\Strings;
use Symfony\Component\PropertyAccess\PropertyAccess;
class BaseForm extends Form
{
@wodCZ
wodCZ / force-http.tpl
Last active March 25, 2024 21:23
vestacp cert letsencrypt
server {
listen %ip%:%web_port%;
server_name %domain_idn% %alias_idn%;
location / {
rewrite ^(.*) https://%domain_idn%$1 permanent;
}
}
@wodCZ
wodCZ / FillerUtil.php
Created December 16, 2015 13:08
FillerUtil
<?php
namespace Libs\Utils;
use Nette\ComponentModel\IContainer;
use Nette\Forms\Controls\BaseControl;
use Nette\Utils\Strings;
use Symfony\Component\PropertyAccess\PropertyAccess;