Skip to content

Instantly share code, notes, and snippets.

Page:
actAs :
Timestampable:
Signable:
created: { name: created_by, type: integer(11) }
updated: { name: updated_by, type: integer(11) }
I18n:
fields: [title]
actAs:
Sluggable:
<iframe src="http://www.facebook.com/plugins/likebox.php?href=http%3A%2F%2Fwww.facebook.com%2Fmaje.officiel&amp;width=197&amp;colorscheme=light&amp;show_faces=false&amp;stream=false&amp;header=true&amp;height=65" scrolling="no" frameborder="0" style="border:none; overflow:hidden;width:197px; height:65px;margin-left:-15px;" allowTransparency="true"></iframe>
<VirtualHost *:80>
ServerName mdp.wiki.dev
DocumentRoot "/var/www/wiki/web"
Alias /sf "/var/www/wiki/lib/vendor/symfony/data/web/sf"
<Directory "/var/www/wiki/web">
DirectoryIndex backend.php
AllowOverride all
// grab the initial top offset of the navigation
var $sticky_navigation = $('#site-nav');
var sticky_navigation_offset_top = 102;
// our function that decides weather the navigation bar should have "fixed" css position or not.
var sticky_navigation = function(){
var scroll_top = $(window).scrollTop(); // our current vertical position from the top
// if we've scrolled more than the navigation, change its position to fixed to stick to top, otherwise change it back to relative
if ($(window).width() > 600) {
angular.module('granon',[
'ui.router',
'ngResource',
'granon.activities.controllers',
'granon.activities.services'
]);
angular.module('granon').config(function($stateProvider, $httpProvider){
$stateProvider
.state('app',{
@while $i > 0 {
.item-#{$i} {
top: ((100 - $i) * 0.4vh);
height: percentage($i/100);
}
$i: $i - 5;
}
@nicolasbinet
nicolasbinet / routes.php
Created September 2, 2015 12:16
routes name problem
Route::group(['prefix' => 'dashboard', 'as' => 'dashboard.', 'middleware' => 'auth'], function () {
Route::get('/', ['as' => 'home', 'uses' => 'Dashboard\DashboardController@home']);
Route::resource('news', 'Dashboard\NewsController', ['as' => 'news']);
});
@nicolasbinet
nicolasbinet / gist:e0db04b92056dc7525d0
Last active November 2, 2015 11:14
Laravel validation
@if ($errors->any())
<p class="alert alert-danger">{{ trans('validation.form_not_valid') }}</p>
@endif
<div class="panel panel-default">
<div class="panel-heading">Référencement</div>
<div class="panel-body">
<div class="form-group @if ($errors->has('seo[title]')) has-error has-feedback @endif">
{!! Form::label('seo[title]', 'Titre', ['class' => 'control-label']) !!}
{!! Form::text('seo[title]', null, ['class' => 'form-control']) !!}
<?php
namespace App\Http\Requests;
use App\Http\Requests\Request;
class DashboardSerieRequest extends Request
{
/**
* Determine if the user is authorized to make this request.
"repositories": [
{
"type": "vcs",
"url": "https://github.com/nicolasbinet/Instagram-PHP-API.git"
}
],
"require": {
"cosenary/instagram": "dev-patch-getUserMedia as 2.3",
"vinkla/instagram": "^3.1"
}