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 | |
/**************************************************** | |
CallerService.php | |
This file uses the constants.php to get parameters needed | |
to make an API call and calls the server.if you want use your | |
own credentials, you have to change the constants.php | |
Called by TransactionDetails.php, ReviewOrder.php, | |
DoDirectPaymentReceipt.php and DoExpressCheckoutPayment.php. |
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 | |
try{ | |
$serviceWsdlUri = "https://XXX.XXX.XXX.XXX/eft/Cards.asmx?WSDL"; | |
$soapClient = new SoapClient($serviceWsdlUri); | |
$username = "XXXXX"; | |
$password = "XXXXX"; | |
$cardNumber = "XXXXX"; | |
$plasticNo = ""; | |
$amount=3; |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<document signature="Army Builder Roster"> | |
<product major="3" minor="4" patch="0" build="319" /> | |
<game folder="AB40k6" game="Warhammer 40 000 6th Edition" major="1" minor="2" /> | |
<author date="20120816202332" /> | |
<roster name="" race="sm" size="0" activesize="795." racename="Codex: Space Marines"> | |
<tag group="language" tag="English" /> | |
<tag group="ruleset" tag="gnVersion" /> | |
<tag group="ruleset" tag="ohWHA" /> | |
<tag group="ruleset" tag="oh_nohvy" /> |
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 | |
global $post; | |
if ( isset($post) ) { | |
//get the ancestors | |
$familyTree = get_ancestors($post->ID,'page'); | |
array_unshift( $familyTree, $post->ID ); //add the current page to the begining of the list | |
//loop through the family tree until you find a result or exhaust the array | |
$featuredImage = ''; |
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
# BEGIN WordPress | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
RewriteRule ^index\.php$ - [L] | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteRule . /index.php [L] | |
</IfModule> |
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
/*------------------------------------- | |
/ WordPress Hooks Demo (whd) | |
-------------------------------------*/ | |
//base function | |
function whd_a_plus_b(){ | |
$a = 2; | |
$b = 3; | |
$a = apply_filters( 'whd_modify_a', $a ); // a = 8 |
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
/*base function*/ | |
function slp_show_search_form(){ | |
$showSearchForm = true; | |
$showSearchForm = apply_filters( 'slp_modify_show_search_form', $showSearchForm ); | |
$result = ""; | |
if($showSearchForm){ | |
//show the form | |
$result = "some html"; |
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
#! /bin/bash | |
# A modification of Dean Clatworthy's deploy script as found here: https://github.com/deanc/wordpress-plugin-git-svn | |
# The difference is that this script lives in the plugin's git repo & doesn't require an existing SVN repo. | |
# main config | |
PLUGINSLUG="______your-plugin-name______" | |
CURRENTDIR=`pwd` | |
MAINFILE="______your-plugin-name______.php" # this should be the name of your main php file in the wordpress plugin | |
# git config |
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
//dequeue css from plugins | |
add_action('wp_print_styles', 'mytheme_dequeue_css_from_plugins', 100); | |
function mytheme_dequeue_css_from_plugins() { | |
wp_dequeue_style( "plugin-css-file-handle" ); | |
} |
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
//include jquery - use an empty file path which is basically a promise to WP that you'll hardcode it into your theme | |
wp_deregister_script('jquery'); | |
wp_register_script('jquery', '', FALSE, '1.8.0', true); | |
wp_enqueue_script('jquery'); |
OlderNewer