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
jQuery(document).ready(function($){ | |
var output = document.getElementById("output").value; | |
$(document).ready(function(){ | |
$.ajax({ | |
url:'http://earthquake.usgs.gov/fdsnws/event/1/query?format=geojson&starttime=2015-11-24&endtime=', | |
type:'post', | |
dataType: 'json', |
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
#!/usr/bin/env drush php-script --everything -v | |
<?php | |
// --------------------------------------- | |
// CREDENTIALS ETC. | |
// --------------------------------------- | |
$dir = "public_html"; | |
$theme_dir = "public_html/sites/all/themes"; | |
$makefile = "site.make"; |
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
tail -f /var/log/mail.log |
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
mysqldump -h db-dev.usgs.mobomo.net -u dev_admin -pusgs2015 answers_drupal | mysql -h db-dev.usgs.mobomo.net -u dev_admin -pusgs2015 answers_jason | |
mysqldump -h db.palladium.usgs.mobomo.net -P 3306 dev -u usgs_admin -p'M0b0m0.U$g$2015' | mysql -h stage.db.palladium.usgs.mobomo.net stage -u dbadmin -p'M0b0m0.U$g$2015!' | |
mysqldump -h <database hostname> -P 3306 <database name> -u <database username> -p'<database password>' | mysql -h <database hostname> <database name> -u <database username> -p'<database password>' |
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
-// Warning Duplicate IDs | |
-$('[id]').each(function(){ | |
- var ids = $('[id="'+this.id+'"]'); | |
- if(ids.length>1 && ids[0]==this) | |
- console.warn('Multiple IDs #'+this.id); | |
-}); |
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 if( have_rows('background_images') ): ?> | |
<?php if( get_field('random_images') ): ?> | |
<ul class="slides custom_bg img_bg random"> | |
<?php else: ?> | |
<ul class="slides custom_bg img_bg"> | |
<?php endif; ?> | |
<?php $i = 0; | |
while( have_rows('background_images') ): the_row(); | |
$i++; |
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
SELECT nid FROM node WHERE type = 'blog' |
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
$('#prev-node-link').click(function(){ | |
$('.prev-next-link-prev a')[0].click(); | |
}); | |
$('#next-node-link').click(function(){ | |
$('.prev-next-link-next a')[0].click(); | |
}); |