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
/* START Make the WooCommerce Cart Table Responsive for Mobile */ | |
/* CSS published in http://www.jeremycarter.com.au/optimising-woocommerce-checkout-for-mobile/ */ | |
@media screen and (max-width: 600px) { | |
/* Force table to not be like tables anymore */ | |
.woocommerce-page table.shop_table, | |
.woocommerce-page table.shop_table thead, | |
.woocommerce-page table.shop_table tbody, | |
.woocommerce-page table.shop_table th, |
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 | |
/** | |
* Gravity Wiz // Gravity Forms Populate With Entries | |
* | |
* Populate choice-based fields (i.e. drop downs, radios, checkboxes) with data from Gravity Form entries. | |
* | |
* @version 1.0 | |
* @author David Smith <[email protected]> | |
* @license GPL-2.0+ | |
* @link http://gravitywiz.com/... |
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 | |
new GW_Sample_Class( array( | |
'form_id' => 1, | |
'target_field_id' => 7, | |
'modifier' => '+1 year' | |
) ); | |
new GW_Sample_Class( array( | |
'form_id' => 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
<?php | |
/** | |
* Gravity Wiz // Gravity Forms // Remove query args from Save & Continue's "resume url". | |
* | |
* If form is access from the url: | |
* | |
* http://mysite.com/form-page/?boom=1 | |
* | |
* Reume URL would be: | |
* |
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
/** | |
* Gravity Perks // GP Unique ID // Prepend Date to Unique ID | |
*/ | |
add_filter( 'gpui_unique_id', 'add_date_to_unique_id', 10, 3 ); | |
function add_date_to_unique_id( $unique, $form_id, $field_id ) { | |
if( $form_id == 1 && $field_id == 2 ) { | |
// if $unique was "123", this would change it do something like "01132015_123" | |
$unique .= date( 'mdy' ) . '_' . $unique; | |
} |
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 | |
/** | |
* Gravity Wiz // Gravity Forms // Content Template for Post Excerpt Field | |
* | |
* Gravity Forms does not currently offer a "Content Template" option for the | |
* Exceprt field. This is a simple snippet that allows you to create | |
*/ | |
// update "433" to the ID of your form | |
add_filter( 'gform_post_data_433', 'gw_post_excerpt_content_template_433', 10, 3 ); | |
function gw_post_excerpt_content_template_433( $post_data, $form, $entry ) { |
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 | |
/** | |
* Gravity Wiz // Gravity Forms // Submit to Access | |
* | |
* Require that a form be submitted before a post or page can be accessed. | |
* | |
* @version 1.1 | |
* @author David Smith <[email protected]> | |
* @license GPL-2.0+ | |
* @link http://gravitywiz.com/submit-a-gravity-form-to-access-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
{ | |
"0": { | |
"title": "A Simple Form", | |
"description": "How much simpler is the form export format in Gravity Forms 1.9?", | |
"labelPlacement": "top_label", | |
"descriptionPlacement": "below", | |
"button": { | |
"type": "text", | |
"text": "Submit", | |
"imageUrl": "" |
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
/** | |
* Gravity Perks // GP Unique ID // Populate Unique ID on Pre Submission (rather than Post Entry Creation) | |
* | |
* This method is slightly less reliable for guaranteeing a truly unique ID; however, in some cases, you may want access to the | |
* unique ID prior to the entry creation. | |
*/ | |
add_action( 'gform_pre_submission', function( $form ) { | |
if( ! function_exists( 'gp_unique_id' ) ) { | |
return; |
OlderNewer