Skip to content

Instantly share code, notes, and snippets.

View danielchikaka's full-sized avatar

Daniel Chikaka danielchikaka

View GitHub Profile
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>HTML5 Starter</title>
<link rel="stylesheet" href="" type="text/css" />
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<?php
abstract class MenuComposer
{
protected $view;
public final function compose($view)
{
$this->view = $view;
$this->addMenus();
}

#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

=======[ Media Queries - default media query break points ]=======
@media(max-width:767px) {
}
@media(min-width:768px) {
}
@media(min-width:992px) {
=======[ Media Queries - default media query break points ]=======
@media(max-width:767px) {
}
@media(min-width:768px) {
}
@media(min-width:992px) {
$(window).on("scroll", function() {
var scrollHeight = $(document).height();
var scrollPosition = $(window).height() + $(window).scrollTop();
if ((scrollHeight - scrollPosition) / scrollHeight === 0) {
// when scroll to bottom of the page
}
});
Function.prototype.compose = function(argFunction) {
var invokingFunction = this;
return function() {
return invokingFunction.call(this, argFunction.apply(this,arguments));
}
}
@danielchikaka
danielchikaka / angular-remove-white-space-filter.js
Last active August 29, 2015 14:25 — forked from builtbylane/angular-remove-white-space-filter.js
AngularJS – filter: removes white space from text. useful for html values that cannot have spaces
/**
* Description:
* removes white space from text. useful for html values that cannot have spaces
* Usage:
* {{some_text | nospace}}
*/
app.filter('nospace', function () {
return function (value) {
return (!value) ? '' : value.replace(/ /g, '');
@danielchikaka
danielchikaka / 01_Laravel 5 Simple ACL manager_Readme.md
Created March 8, 2016 07:01 — forked from amochohan/01_Laravel 5 Simple ACL manager_Readme.md
Laravel 5 Simple ACL - Protect routes by an account / role type

#Laravel 5 Simple ACL manager

Protect your routes with user roles. Simply add a 'role_id' to the User model, install the roles table and seed if you need some example roles to get going.

If the user has a 'Root' role, then they can perform any actions.

Installation

Simply copy the files across into the appropriate directories, and register the middleware in App\Http\Kernel.php