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
if (req.http.host == "crashndash.com") { | |
unset req.http.Cookie; | |
} |
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 | |
# Configuration | |
VHOST_CONF=/etc/apache2/sites-available/ | |
ROOT_UID=0 | |
WWW_ROOT=/var/www | |
MYSQL=`which mysql` | |
DRUSH=`which drush` | |
# If you don't use drush aliases, uncomment this. | |
DRUSHRC=/home/MYUSERNAME/.drush/aliases.drushrc.php |
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
function getLocationAndPost() { | |
'use strict'; | |
navigator.geolocation.getCurrentPosition(function (position) { | |
var url = 'http://example.com/enpoint' + '/node.json'; //endpoint URL | |
var lat = position.coords.latitude; | |
var lon = position.coords.longitude; | |
var date = new Date(); | |
var timestamp = Math.round(date.getTime() / 1000); | |
var node_object = { | |
"type": "some_type", //set this to your content type |
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 | |
$style = ''; | |
foreach($styles as $stylesheet) { | |
if (strpos($stylesheet['data'], 'system/system.menus.css') > 0) { | |
// Skip this one, at least for my theme. | |
continue; | |
} | |
// The following are nicked from Drupal core. | |
$contents = drupal_load_stylesheet($stylesheet['data'], TRUE); |
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
$ ssh [email protected] "drush --root=/path/in/remote/server sql-dump" | drush sql-cli |
NewerOlder