This file contains hidden or 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 | |
| $mobileType = new stdClass(); | |
| //Detect special conditions devices | |
| $mobileType->iPod = stripos($_SERVER['HTTP_USER_AGENT'],"iPod"); | |
| $mobileType->iPhone = stripos($_SERVER['HTTP_USER_AGENT'],"iPhone"); | |
| $mobileType->iPad = stripos($_SERVER['HTTP_USER_AGENT'],"iPad"); | |
| if(stripos($_SERVER['HTTP_USER_AGENT'],"Android") && stripos($_SERVER['HTTP_USER_AGENT'],"mobile")) { | |
| $mobileType->android = true; | |
| } elseif (stripos($_SERVER['HTTP_USER_AGENT'],"Android")){ | |
| $mobileType->android = false; |
This file contains hidden or 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
| var stylus = require('stylus') | |
| , nib = require('nib') | |
| , uglify = require('uglifyjs') | |
| function processStylus(input, cb) { | |
| fs.readFile(input.src, function (err, data) { | |
| if (err) return cb(err) |
This file contains hidden or 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 Symfony\Component\Security\Http\RememberMe; | |
| use Symfony\Component\Security\Core\Exception\AuthenticationException; | |
| use Symfony\Component\Security\Core\User\UserInterface; | |
| use Symfony\Component\Security\Core\Authentication\Token\RememberMeToken; | |
| use Symfony\Component\Security\Http\Logout\LogoutHandlerInterface; | |
| use Symfony\Component\Security\Core\Authentication\Token\TokenInterface; | |
| use Symfony\Component\Security\Core\Exception\UnsupportedUserException; |
This file contains hidden or 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
| cd ~ | |
| sudo rm -Rf /usr/local/share/elasticsearch | |
| sudo /usr/local/share/elasticsearch/bin/service/elasticsearch remove | |
| sudo rm /usr/local/bin/rcelasticsearch | |
| wget https://github.com/downloads/elasticsearch/elasticsearch/elasticsearch-0.19.3.tar.gz -O elasticsearch.tar.gz | |
| tar -xf elasticsearch.tar.gz | |
| rm elasticsearch.tar.gz | |
| sudo mv elasticsearch-* elasticsearch | |
| sudo mv elasticsearch /usr/local/share |
This file contains hidden or 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
| #!/bin/bash | |
| SYMFONY="Symfony_Standard_Vendors_2.0.0BETA3.tgz" | |
| APPLICATION_ROOT="/var/www" | |
| REMOTE_IP="127.0.0.1" | |
| DB_HOST="localhost" | |
| DB_DRIVER="pdo_pgsql" | |
| DB_USER="test" | |
| DB_PASSWORD="test" | |
| echo "Please enter the company name and project name (in the format CompanyName ProjectName)" |
NewerOlder