- method 1 uses "get_the_excerpt()"
- method 2 uses "get_the_content()"
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 | |
/** | |
* Registers a unique widget for each individual page | |
* @author christopher james curtin <[email protected]> | |
*/ | |
//If dynamic sidebar exists | |
if (function_exists('register_sidebar')) { | |
$pages = get_pages( // First, retreive all pages that exist. | |
array ( | |
'parent' => 0, // replaces 'depth' => 1 |
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
//■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■ | |
/* | |
Plugins | |
*/ | |
//■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■ | |
var gulp = require('gulp'), | |
shell = require('gulp-shell'), | |
compass = require('gulp-compass'), | |
gutil = require('gulp-util'), |
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
Show hidden characters
{ | |
"file_exclude_patterns": | |
[ | |
"*.sass-cache", | |
"*.pyo", | |
"*.exe", | |
"*.dll", | |
"*.obj", | |
"*.o", | |
"*.a", |
[http://codex.wordpress.org/Function_Reference/wp_localize_script] [http://stackoverflow.com/questions/6808221/php-within-js-file-wordpress]
<?php wp_localize_script( $handle, $name, $data ); ?>
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 | |
//*** FOLLOWING CODE GETS the ENTERED URL from the BROWSER AND MAPS it to CORRECT ROUTER and CHANGES ALL INSTANCES in the PAGES *** // | |
// Gets URL part "subdomain.domain.com:8081" | |
// Don't forget to add the sub-directory location! | |
$wp_ubiquitousDomain = "http://" . $_SERVER['HTTP_HOST'] . "/smith/asb/wordpress/"; | |
update_option( 'siteurl', $wp_ubiquitousDomain); | |
update_option( 'home', $wp_ubiquitousDomain ); |
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
https://www.sandbox.paypal.com/cgi-bin/[email protected]&cmd=_xclick&amount=10&shipping=0&discount_num=10&discount_rate=10&discount_rate2=10&quantity=10 |
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 | |
function print_wp_shopping_cart($args = array()) { | |
$output = ""; | |
if (!cart_not_empty()) { | |
$empty_cart_text = get_option('wp_cart_empty_text'); | |
if (!empty($empty_cart_text)) { | |
$output .= '<div class="wp_cart_empty_cart_section">'; | |
if (preg_match("/http/", $empty_cart_text)) { | |
$output .= '<img src="' . $empty_cart_text . '" alt="' . $empty_cart_text . '" class="wp_cart_empty_cart_image" />'; |
OlderNewer