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
/** | |
* Basic Expressions | |
* | |
* @author Sean Davis | |
*/ | |
package edu.umsl; | |
import java.util.Scanner; |
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 // DO NO COPY THIS LINE | |
/** | |
* Modify various queries | |
* | |
* @param $query | |
*/ | |
function vol_custom_pre_get_posts( $query ) { | |
if ( is_admin() ) { |
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 // DO NOT COPY THIS LINE | |
/** | |
* Bulk edit all downloads with variable price options | |
* | |
* This code should only be executed when needed. The purpose is to find | |
* all downloads with variable pricing, and update their respective variable | |
* pricing labels (Option Name) based strings given in the custom function. | |
* | |
* The easiest way to use the function is with the following WordPress plugins: |
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 // DO NOT COPY THIS LINE | |
/** | |
* Filter the Themedd copyright text for custom output | |
*/ | |
function custom_themedd_copyright( $copyright ) { | |
$copyright = 'Custom copyright © text with year (' . date( 'Y' ) . ') and site name (' . get_bloginfo( 'name' ) . ')!' ; | |
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 // DO NOT COPY THIS LINE | |
// PLEASE READ ALL COMMENTS | |
/** | |
* This is being provide as-is directly from a custom implementation I built for the checkout form on easydigitaldownloads.com. | |
* It's not just this part that is custom. I made various changes to the entire checkout cart, form, and behavior. So context | |
* matters. The code below is specific to repositioning the login form, putting it behind a toggle link, and making sure the | |
* form still submits via AJAX. While this will get you most of the way, you'll have to make tweaks based on your own code. | |
* |
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 | |
/** | |
* Content for the Account Dashboard tab on the Account page / The Main Account Page | |
*/ | |
global $current_user; | |
$customer = ''; | |
if ( class_exists( 'Easy_Digital_Downloads' ) ) { |
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 // DO NOT COPY THIS LINE | |
function sd_edd_fes_custom_user_meta( $payment ) { | |
$user = edd_get_payment_meta_user_info( $payment->ID ); | |
?> | |
<tr> | |
<td><strong><?php _e( 'Phone', 'easy-digital-downloads' ); ?>:</strong></td> | |
<td><?php echo get_user_meta( $user['id'], 'phone_number', true ); ?></td> | |
</tr> | |
<?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 // DO NOT COPY THIS LINE | |
// Checks Gateway email subject adjustment | |
function sd_eddcg_custom_admin_notification_subject( $subject ) { | |
$subject = 'New Pending Offline Donation'; | |
return $subject; | |
} | |
add_filter( 'eddcg_admin_purchase_notification_subject', 'sd_eddcg_custom_admin_notification_subject' ); | |
// Checks Gateway email body adjustments |
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 // DO NOT COPY THIS LINE | |
/** | |
* Prevents items from being added to the cart multiple times | |
* | |
*/ | |
function pw_edd_prevent_duplicate_cart_items( $download_id, $options ) { | |
if( edd_item_in_cart( $download_id, $options ) ) { | |
if( edd_is_ajax_enabled() ) { | |
wp_redirect( edd_get_checkout_uri() ); exit; |
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 // DO NOT COPY THIS LINE | |
function custom_edd_stripe_new_card_form() { | |
?> | |
<p id="edd-card-number-wrap"> | |
<label for="card_number" class="edd-label"> | |
<?php _e( 'Card Number', 'edds' ); ?> | |
<span class="edd-required-indicator">*</span> | |
<span class="card-type"></span> | |
</label> |
NewerOlder