This Plugin adds a search widget for the Easy Digital Downloads plugin post type independent from the regular WordPress search.
Currently, these attributes/ parameters are available:
label_text — Label text before the input field (default: Search downloads for:)placeholder_text — Input field placeholder text (default: Search downloads...)button_text — Submit button text (default: Search)class — Can be a custom class, added to the wrapper div container (default: none, empty)Place the Shortcode tag in any Post, Page, Download product, or Shortcode-aware area. A few examples:
[edd-searchbox]
--> displays search box with default values
[edd-searchbox label_text=""]
--> will display no label!
[edd-searchbox placeholder_text="Search our digital products..." class="my-custom-class"]
--> will display other placeholder, plus add custom wrapper class for custom styling :-)
(1) There's an extra CSS class included for that, named .eddsw-label so you can style it with any rules or just remove this label with display:none.
(2) Second option, you can fully remove the label by adding a constant to your theme's/child theme's functions.php file or to a functionality plugin etc. - this will work for both, Widget & Shortcode:
/** Easy Digital Downloads Search Widget: Remove Search Label */
define( 'EDDSW_SEARCH_LABEL_DISPLAY', false );
(1) You can use the translation language file to use custom wording for that - for English language the file would be /wp-content/plugins/edd-search-widget/languages/edd-search-widget-en_US.mo. Just via the appropiate language/translation file. For doing that, a .pot/.po file is always included.
(2) Second option: Or you use the built-in filter to change the string. Add the following code to your functions.php file of current them/child theme, just like that:
add_filter( 'eddsw_filter_label_string', 'custom_eddsw_label_string' );
/**
* Easy Digital Downloads Search Widget: Custom Search Label
*/
function custom_eddsw_label_string() {
return __( 'Your custom search label text', 'your-theme-textdomain' );
}
(1) See above question: via language file!
(2) Or second option, via built-in filter for your functions.php file of theme/child theme:
add_filter( 'eddsw_filter_placeholder_string', 'custom_eddsw_placeholder_string' );
/**
* Easy Digital Downloads Search Widget: Custom Placeholder Text
*/
function custom_eddsw_placeholder_string() {
return __( 'Your custom placeholder text', 'your-theme-textdomain' );
}
(1) Again, see above questions: via language file!
(2) Or second option, via built-in filter for your functions.php file of theme/child theme:
add_filter( 'eddsw_filter_search_string', 'custom_eddsw_search_string' );
/**
* Easy Digital Downloads Search Widget: Custom Search Button Text
*/
function custom_eddsw_search_string() {
return __( 'Your custom search button text', 'your-theme-textdomain' );
}
All the custom & branding stuff code above as well as theme CSS hacks can also be found as a Gist on GitHub: https://gist.github.com/2857613 (you can also add your questions/ feedback there :)
There are CSS classes for every little part included:
#edd_search-<ID>.widget_edd_search.eddsw-intro-text#eddsw-form-wrapper.eddsw-search-form.eddsw-form-container.eddsw-label.eddsw-search-field.eddsw-search-submit.eddsw-outro-textThis plugin's widget is limited to provide the widget and search functionality itself. Styling the search results output in your THEME or CHILD THEME is beyond the purpose of this plugin. You might style it yourself so it will fit your theme.
Please report in the support forum here, giving the correct name of your theme/child theme plus more info from where the theme is and where its documentation is located. For example the "iFeature Lite" theme, found on WordPress.org has issues with the CSS styling. For this example theme you found a CSS fix/hack directly here: https://gist.github.com/2857613#file_theme_ifeature_lite.css ---> Just place this additional CSS styling ad the bottom of this file /wp-content/themes/ifeature/css/style.css (please note the /css/ subfolder here!)
Requires: 3.3 or higher
Compatible up to: 3.6 Beta
Last Updated: 2013-4-29
Downloads: 3,079
0 of 1 support threads in the last two months have been resolved.
Got something to say? Need help?