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 | |
/** | |
* If you need to make some of the GravityView search fields required before search is submited | |
* - add as many lines as you need to define which fields are required | |
* e.g. -> jQuery('#gv_search_XYZZ').prop('required', true ); | |
* | |
* Add this gist to your theme functions.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 | |
/* | |
Plugin Name: GravityView - Custom Required Search Fields | |
Plugin URI: https://gravityview.co/ | |
Description: Custom Add-on to make certain GravityView Search fields required before performing the search | |
Author: Katz Web Services, Inc. | |
Version: 1.0.0 | |
Author URI: http://www.katzwebservices.com | |
Copyright 2014 Katz Web Services, Inc. (email: info@katzwebservices.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 | |
/** | |
* When using the Advanced Filter extension to filter entries to show just the ones created by the user logged-in | |
* BUT remove the restriction to a certain role of users ( administrators or editors ) | |
* | |
* Replace the following to your own values: | |
* - REPLACE_BY_VIEW_ID, use the view id where this logic applies | |
* - REPLACE_BY_THE_ROLE, use 'administrator' or 'editor' or your own custom role | |
* |
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 | |
/* | |
Plugin Name: GravityView - force login before single view | |
Plugin URI: https://gravityview.co/ | |
Description: Redirect visitors to login page before seeing the single entry view | |
Author: Katz Web Services, Inc. | |
Version: 1.0.0 | |
Author URI: http://www.katzwebservices.com | |
Copyright 2015 Katz Web Services, Inc. (email: info@katzwebservices.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 | |
/* Add this to your theme's functions.php file */ | |
// Adds a 'clear' button to your GravityView Search Bar | |
add_action( 'gravityview_search_widget_fields_after', 'my_gv_clear_search_button' ); | |
function my_gv_clear_search_button() { | |
$url = strtok( add_query_arg( array() ), '?' ); | |
?> | |
<a href="<?php echo esc_url( $url ); ?>" class="button gv-search-button">Clear</a> | |
<?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 | |
/** | |
* Place this in your theme's functions.php | |
* Please adapt the form_id and the field key to your own case. | |
* This is intended to force GravityView to search for the exact value instead of be more relaxed (default search uses operator LIKE) | |
* | |
*/ | |
add_filter( 'gravityview_fe_search_criteria', 'my_gv_exact_search', 20, 2 ); |
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 allow a certain user to edit a field if that field has a specific value | |
* | |
* Replace the following to your own values: | |
* - REPLACE_BY_FORM_ID, use the form id where this logic applies | |
* - REPLACE_BY_FIELD_ID, use the field id where this logic applies | |
* | |
* |
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 | |
/* | |
* Supported on GravityView 1.6 | |
* | |
* Add this to your theme's functions.php file | |
* | |
* Replace the string 'MY NEW LABEL' for your own | |
*/ | |
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 | |
/** Modify the content returned from the Custom Content field */ | |
add_filter( 'gravityview/fields/custom/content_before', 'my_gv_custom_content_before', 10, 1 ); | |
/** | |
* Removes the custom content field's content in case a certain entry field is empty | |
* Replace the MY_FIELD_ID by the field id (check it on the Gravity Forms form definition) | |
* | |
* @param string $content Custom Content field content | |
* @return string |
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 | |
/* | |
Plugin Name: Gravity Forms MailChimp Custom Export | |
Plugin URI: http://gravityview.co/ | |
Description: Custom plugin to force updated entries to be exported with the GF MailChimp add-on | |
Author: Katz Web Services, Inc. | |
Version: 1.1.0 | |
Author URI: http://www.katzwebservices.com | |
Copyright 2014 Katz Web Services, Inc. (email: info@katzwebservices.com) |
OlderNewer