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
package template | |
import ( | |
"fmt" | |
"io" | |
"log" | |
"os" | |
"path/filepath" | |
"strings" | |
"text/template" |
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 | |
// A multi-dimensional array | |
$user = [ | |
'firstname'=>'Muzafar', | |
'lastname'=>'Jatoi', | |
'contacts'=>[ | |
[ | |
'mobile'=>'0500000000', | |
'email'=>'[email protected]', |
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 AppBundle\DataFixtures\ORM; | |
use Doctrine\Common\Persistence\ObjectManager; | |
use Doctrine\Common\DataFixtures\AbstractFixture; | |
use Doctrine\Common\DataFixtures\OrderedFixtureInterface; | |
use AppBundle\Entity\Workspace; | |
/** |
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
ip: "192.168.10.10" | |
memory: 2048 | |
cpus: 1 | |
provider: virtualbox | |
# VM Name in Virtual Box | |
name: Homestead | |
authorize: ~/.ssh/id_rsa.pub |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
# Every Vagrant development environment requires a box. You can search for | |
# boxes at https://vagrantcloud.com/search. | |
config.vm.box = "ubuntu/trusty64" | |
config.vm.provider "virtualbox" do |v| |
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
/* | |
* Automatically logout user in 1 hour on no activity | |
*/ | |
setTimeout(function(){ | |
window.open("http://www.yoursite.com/user/logout", "_self") | |
}, 1000*60*60); // logout in 1 hour |
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
# Cache and logs (Symfony2) | |
/app/cache/* | |
/app/logs/* | |
!app/cache/.gitkeep | |
!app/logs/.gitkeep | |
# Email spool folder | |
/app/spool/* | |
# Cache, session files and logs (Symfony3) |
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 AppBundle\Entity\Traits; | |
use Doctrine\ORM\Mapping as ORM; | |
/** | |
* Adds created at and updated at timestamps to entities. | |
* Entities using this must have HasLifecycleCallbacks annotation. | |
* |
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
<script type="text/javascript"> | |
jQuery(document).ready( | |
function() { | |
$(document).on("focus", ".dateInput", function() { | |
$(this).mask("99/99/9999"); | |
}); | |
} | |
); | |
</script> |
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
<html> | |
<head></head> | |
<body> | |
<form> | |
<input id="candidate_firstname" name="firstname" required="required" class="gui-input" dir="rtl" type="text" /> | |
<input id="candidate_lastname" name="lastname" required="required" class="gui-input" dir="rtl" type="text" /> | |
</form> | |
<script type="text/javascript"> | |
function restrictInputOtherThanArabic($field) |
NewerOlder