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
| RENAME TABLE wp_8_options TO wp_5_options, | |
| wp_8_posts TO wp_5_posts, | |
| wp_8_commentmeta TO wp_5_commentmeta, | |
| wp_8_comments to wp_5_comments, | |
| wp_8_links to wp_5_links, | |
| wp_8_postmeta to wp_5_postmeta, | |
| wp_8_users to wp_5_users, | |
| wp_8_usermeta to wp_5_usermeta, | |
| wp_8_terms to wp_5_terms, | |
| wp_8_term_taxonomy to wp_5_term_taxonomy, |
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
| wget --limit-rate=200k --no-clobber --convert-links --random-wait -r -p -E -e robots=off -U mozilla http://www.oldwebsite.com |
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 (isset($_GET['debug']) ) { | |
| define('WP_DEBUG',true); | |
| if ( $_GET['debug']=='log') { | |
| // Enable Debug logging to the /wp-content/debug.log file | |
| // The web user will have to have write permission to the file | |
| /* uncomment next to use wordpress file default of wp-content/debug.log, make sure of write permission */ | |
| //define('WP_DEBUG_LOG', true); | |
| /* or use a file in the wp-content/uploads directory, which should always have write perms on it */ | |
| @ini_set('error_log', dirname(__FILE__) . '/wp-content/uploads/debug.log'); | |
| // Disable display of errors and warnings |
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 ($) { | |
| $.each(['show', 'hide'], function (i, ev) { | |
| var el = $.fn[ev]; | |
| $.fn[ev] = function () { | |
| this.trigger(ev); | |
| return el.apply(this, arguments); | |
| }; | |
| }); | |
| })(jQuery); |
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
| // this goes in the page template or where you need it | |
| // make sure that your add_action and your callback are in functions, not in a page template | |
| wp_enqueue_script('karla'); | |
| $ajax_nonce = wp_create_nonce( "karla-nonce" ); | |
| wp_localize_script('karla','getter',array('ajax_url' => admin_url( 'admin-ajax.php' ),'sugar'=>$_GET['sugar']), 'security'=> $ajax_nonce ); | |
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
| define('WP_DEBUG', true); | |
| define('WP_DEBUG_LOG', true); | |
| define('WP_DEBUG_DISPLAY', 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
| <?php | |
| add_action('wp_footer', 'add_char_counter'); | |
| function add_char_counter() { | |
| if ( is_page( array( 'add-a-highlight', 'add-a-publication' ) ) ) { ?> | |
| <script src="/wp-content/themes/ameriflux/library/js/textcounter.min.js"></script> | |
| <script type="text/javascript"> | |
| jQuery('.amx-title input').textcounter({ | |
| max: 250, | |
| countDownText: "Characters Left: " | |
| }); |
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
| /* http://www.gravityhelp.com/documentation/page/Dynamically_Populating_Drop_Down_Fields | |
| */ | |
| add_filter('gform_pre_render_5', 'populate_posts'); | |
| function populate_posts($form){ | |
| foreach($form['fields'] as &$field){ | |
| if( strpos($field['cssClass'], 'multi-selector') === false) /* original had a check for $field['type'] != 'select' */ | |
| continue; | |
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
| dscacheutil -flushcache;sudo killall -HUP mDNSResponder |
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
| foreach ($d = array('<br>', self::USER, self::ENDPOINT, $query_string) as $e) {echo $e . $d[0];} |