Wordpress Custom Fields Search 0.3.15

Apologies to everyone who installed yesterday’s release (0.3.14), this mornings release (0.3.15) should bring back the custom fields functionality.  I was obviously a little premature in marking that one stable.  Thanks to Vytautas for pointing out the issue.

Also, the previous release fixed some problems with the method of including search forms in posts and pages.  To fix this bug though I have had to change the syntax for including presets in posts, please check the “settings/wp custom fields search” section of the site to see the new syntax.  The old method is now deprecated (meaning it works for now so that everyone has a chance to update, but I will remove it soon.)

Basically what was:

[wp-custom-fields-search 1]

Is now:

[ wp-custom-fields-search preset="1"]

Category: Open Source, Wordpress Plugins | Tags: , , 118 comments »

118 Responses to “Wordpress Custom Fields Search 0.3.15”

  1. john chandler

    Hello Don,
    Thanks for this fantastic plugin…it’s perfect for a site I’m trying to build. One question…will it work with pages as well?

    I’m creating pages that are using custom tags, but when I run a search, I’m getting no results. Is my use of pages the problem? Is there a way for it to search custom fields in pages as well?

  2. Jonathan Casuncad

    Useful plugin. I’m very thankful. I have a few question though;

    1. Why does the search results page have the headings below even if there was a result found and showing on the results page?

    Archive for Not found

    Sorry, no posts matched your criteria.

    2. Can I show all the posts that match the result on one page instead of having only 1 result and a Next Page link to the next result?

    Thanks again!

    Sincerely Yours,
    Jonathan Casuncad

  3. Don

    john: Page search functionality is not quite there yet, or at least it’s not as easy as it should be. If you put in a new field with the data type “Post Type” and the widget “Hidden Constant” and the constant value “Page”, this should start searching pages instead of posts.

    jonathon: I would guess all these issues are related to your theme. My plugin doesn’t make any attempt to display the results, it just puts them into the “search” template in your theme. This file should be called search.php in your theme folder, or if this isn’t there it will show the file index.php.

  4. john chandler

    Don,
    Works perfect. Thanks for the pointer.

    John

  5. kay

    hi
    i just download and play around this plugin with TDO Mini Form plugin
    but when im using radio button
    i get many unknown information in my radio button list as below:

    1
    Category
    CustomFieldJoiner
    cat_value
    RadioButtonField
    EqualComparison

    can you please take alook at it?

    tq

  6. john chandler

    Don,
    Plugin is working great, though I’m trying to troubleshoot one issue I’ve come across.

    I have a search that involves three custom_fields. In my sample data, I’ve found that if a post/page doesn’t have a value for one of those fields, it won’t turn up in any search no matter what. Is there a workaround for this?

  7. Jeromy

    I’m using the Flutter plugin to make custom write fields (which are added to the custom fields table in the db) – I’m able to see them all in the custom fields dropdown when adding a new search field, but even though i have posts with content in those custom fields, I still can’t get any results when I search for them. Every search just comes back with no results.

  8. Jeromy

    I think I figured it out – took some tweaking here and there but I’m getting the hang of it

  9. leen

    Hi Don,

    Thanks very much for this plugin and the work you ‘ve done!

    Also for your comments to Johns remark, I had the same problem : now resolved.

    Only this question: here you can see my testing website with wordpress cms: http://www.ballyhoo.be/wordpress/
    Is it possible to remove the display of ‘All’ for the “Hidden Constant” search button?

    Best regards!
    Leen l Belgium

  10. Scott Munson

    …”Also for your comments to Johns remark, I had the same problem : now resolved….”

    PLEASE DO TELL HOW RESOLVED…..

  11. Scott Munson

    Hi Don,
    Great plugin! Feel free to include my site as an example when it’s ready – I have alot of fields.
    But one issue. After a search can all the fields please be returned to ‘ANY’? – if not how can I put some instructions in between header and first field telling user to reset fields.
    Thanks!
    Scott.

  12. Berardo

    Hi Dan,
    another suggest: add a joiner for custom taxonomies and when is selected in data field add a dropdown menu to choose taxonomie name (e.g. actors, genres, directors).

    Power to search!

  13. Steve Coates

    Just wanted to say thanks for a great and very flexible plugin Don :-)

  14. Ria

    Hi Dan,

    Your search plugin is great btw!
    I’m using it for a clients site backend, and I’m wondering how I could work in a ‘text cleaner’ to the keyword search?
    As in – at the moment people can enter characters like quotes and symbols, and I’d like to be able to remove them for security reasons.

    Any ideas?

    Thanks

  15. flosse

    Great plugin! I searched hours and hours for a solution like this.

    Thank You!

  16. mojoflyer

    my site: http://www.carmamak.com

    I’m using custom search to do search by:
    1)Car Make(Category)
    2)Model(Custom field#1)
    3)Year(Custom field#2)
    3)Price from(Custom field#3,Text input,At Least)
    4)Price to(Custom field#3,Text input,At most)

    My post entry has fields:
    1)Category(Car Make)
    2)Model(Custom field#1)entered as text
    3)Year(Custom field#2)entered as text
    4)Price(Custom field#3)entered as text

    My problem is that when i run a custom search for price range, e.g.
    Price from: blank (at least)
    Price to: 30000 (at most)

    I get results of post with price more than 30000, for example posts with Price:259000 , 220000 also get shown in search result.
    Why is it so? Does the “At most” check for the all digits or only just the first 2 digits? It seems like only the first 2-digits is checked.

    Is there a fix to this problem?

    I’m using version 0.3.16, wordpress version 2.8.4

  17. Don

    Hi,

    Apologies to anyone waiting for replies here or by email, I am currently massively over-run with work and don’t have time to respond to you individually. I will try to look into all your requests/questions as soon as possible.

    Thanks for your patience,
    Don

  18. Eric

    Whenever I perform a search, the website template shows up as if it were the homepage. Is the a conditional tag I can use to force WordPress into thinking the WP Custom Field Search results page is a subpage, rather than a homepage?

  19. Craig

    Hi Don,

    Great plugin, this is something I have been looking for!

    Just a quick question…

    I have a number of categories, all with sub categories under them.

    I was wondering if it was possible to have multiple category fields, but then select which main category is shown there (rather than it list them all)

    So for example:

    Field 1 = (main cat) Product type: (sub cats) Electical, gift, toy, etc.

    Field 2 = (main cat) Price range: (sub cats) 0-100, 101-200, 201-300, etc.

    Maybe this could work in the same way you can include and exclude categories in the category list in wordpress?

    No rush with any help if you are busy and it is not straight forward.

    Many thanks!
    Craig

  20. Antonio

    Hi¡¡

    Thanks a lot for your plugin. It’s super.

    I’m wondering…where are stored the preset which are defined from wordpress back-end?

    Thank you Don¡¡¡

  21. Jesmi

    Hi Don,

    Yes its really great plugin! Using it will sort out alot and really a serach for such kind of plugin is finished with this.

    Thanks alot for sharing such great and for your efforts.

    Cheers:)

  22. Robert

    Hi there, I have a bit problem I have search on my webpage and I have dropdown fiels with numbers. It is sorted alphabeticaly but the problem is that the sort is like:

    10 000
    11 000
    8 000
    9 000

    = in alphabet number 1 is before 9 = 1 is being shown first but in numbers it should be not about alphabet but about value. Is there any way to change the sort?

  23. Baga

    Great plugin Don! Is it possible to build checkboxes as well as radio buttons?
    Thanks

  24. Mike McAlister

    Hi,
    First of all, thanks for putting this together! Exactly what I was looking for.

    I’m just having one small issue. Usually when you search, you see “Results for ‘term’” or “You searched for: term”. I can’t get WP to return this variable with this plugin.

    If you go to http://www.sixonefive.net/dogwalker/ and try searching “mike”, you’ll see what I mean.

    This may be because I’m using the Classipress theme, but I thought I would ask anyway. Is there a piece of code I can use besides below to give me that variable?

  25. Seborgarsen

    Hi,

    First of all, let me thank you for a great plugin.

    I am using three presets on the same page and that breaks one of them:

    Preset 1 – Top bar quick search (keywords searching all custom fields)

    these are in two divs with a show/hide jquery script:

    Preset 2 – Simple Search
    Preset 3 – Advanced Search, based on Preset 2 preset

    Everything works in Preset 3 except for text searches, drop downs are returning just fine. Even the text fields from Preset 2 are down.

    Any hints?

  26. Seborgarsen

    Nevermind. For some reason Preset 3 had a bug, fixed it by deleting it and making a new one.

  27. Seborgarsen

    I am also wondering where the fields are stored…

  28. Alex van Niekerk

    Hi, first of all, it seems like a great plugin except I cant get it working…

    When i select to search after having chosen an option from my drop down box… it says “None Found”.

    I made a test post with Tags, Custom Fields and included the text in the post. Yet none of the Data Types I selected returned any results… Its really confusing me… Is it maybe not working with my theme or what could be the problem?

    Regards,
    Alex

  29. Alex van Niekerk

    Oh, i’m using version 0.316 of the plugin and Wordpress v2.84.

    Thanks

  30. Andy R

    Great plugin! I’m actually developing a real estate website as well and it’s really handy.

    One thing that isn’t working for me is the Hidden Constant. I have a bunch of drop-downs setup and they work fine, but my Hidden Constant doesn’t seem to be taking.

    Here’s how I have it:

    data type : Category
    widget : Hidden Constant
    compare : Equals
    widget config : category name

    My searches are still always showing posts from all categories, not just the one specified in the Hidden Constant. Am I setting this up incorrectly?

    Thanks!

  31. Ervald

    I’ve added Checkbox in the drop down list if anyone is interested.

    Add this after line 507 in extra_search_fields.php

    class CheckboxField extends Field {
    function CheckboxField($options=array(),$params=array()){
    CheckboxField::__construct($options,$params);
    }
    function __construct($params=array()){
    parent::__construct($params);
    if($params['checkboxoptions']){
    $options=array();
    $optionPairs = explode(',',$params['checkboxoptions']);
    foreach($optionPairs as $option){
    list($k,$v) = explode(':',$option);
    if(!$v) $v=$k;
    $options[$k]=$v;
    }
    }
    $this->options = $options;
    }
    function getOptions($joiner,$name){
    if($this->param('fromDb',!$this->options)){
    return $joiner->getAllOptions($name);
    } else {
    return $this->options;
    }
    }
    function getInput($name,$joiner,$fieldName=null){
    if(!$fieldName) $fieldName=$name;
    $v = $this->getValue($name);
    $id = $this->getHTMLName($name);

    $options = '';
    foreach($this->getOptions($joiner,$fieldName) as $option=>$label){
    $option = htmlspecialchars($option,ENT_QUOTES);
    $label = htmlspecialchars($label,ENT_QUOTES);
    $checked = ($option==$v)?" checked='true'":"";
    $htmlId = "$id-$option";

    $options.=" $label";
    }
    return $options;
    }
    function getCSSClass(){
    return "checkbox";
    }
    function getConfigForm($id,$values){
    return "Checkbox Options";
    }
    }
    class CheckboxFromValues extends CheckboxField {
    function CheckboxFromValues($fieldName=null){
    CheckboxFromValues::__construct($fieldName);
    }

    function __construct($fieldName=null,$params){
    $params['fromDb'] = true;
    parent::__construct($options,$params);
    }
    function getConfigForm($id,$values){
    return "";
    }
    }

    Add this after line 291 in wp-custom-fields-search.php

    "CheckboxField" =>__( "Checkbox",'wp-custom-fields-search'),

  32. Alex van Niekerk

    If i have created more than one Drop Down selection method the plug in does not work.

    For instance: Cars…

    Car make: drop down list, post field: words in, “Audi,BMW,Porsche”

    No. of Doors: drop down list, post field: words in, “2,3,5″

    And it always displays “None Found”. Yet this is impossible as i have created a post containing both cases and/or more.

    PLEASE can someone help… this isnt making any sense… Its really not difficult to understand, yet i cant get it to work correctly…..

    PLEASE!!

    Thanks in advance…

  33. Alex van Niekerk

    Not Correctly… i mean its not working at all!

  34. Francisco

    Amazing Plugin… Thanks for sharing. Gretings From Chile…

  35. Baga

    @ Ervald:

    Thanks for sharing your code, I tried to follow your instructions but the checkboxes didn’t show up in the search page :-(

    This is the resulting code:


    Label option1 option2

    Could you please help me??? My mail is baga @ bagaweb . com

  36. Baga

    Mmmmm looks like the code i posted doesn’t show up the way i meant it…. Let’s try again:

    Label option1 option2

  37. Baga

    Sorry for the multiple replies, can’t get the html code to be displayed properly :-(

  38. Ryan

    I’ve managed to hack the checkboxes together thanks to a little editing of Ervalds code above. I had the same result as Baga previously but the below works for me:


    class CheckboxField extends Field {
    function CheckboxField($options=array(),$params=array()){
    CheckboxField::__construct($options,$params);
    }

    function __construct($params=array()){
    parent::__construct($params);
    if($params['checkboxoptions']){
    $options=array();
    $optionPairs = explode(',',$params['checkboxoptions']);
    foreach($optionPairs as $option){
    list($k,$v) = explode(':',$option);
    if(!$v) $v=$k;
    $options[$k]=$v;
    }
    }
    $this->options = $options;
    }
    function getOptions($joiner,$name){
    if($this->param('fromDb',!$this->options)){
    return $joiner->getAllOptions($name);
    } else {
    return $this->options;
    }
    }
    function getInput($name,$joiner,$fieldName=null){
    if(!$fieldName) $fieldName=$name;
    $v = $this->getValue($name);
    $id = $this->getHTMLName($name);

    $options = '';
    foreach($this->getOptions($joiner,$fieldName) as $option=>$label){
    $option = htmlspecialchars($option,ENT_QUOTES);
    $label = htmlspecialchars($label,ENT_QUOTES);
    $checked = ($option==$v)?" checked=\"checked\"":"";
    $htmlId = "".$id-$option."";

    $options.=" $label";
    }
    return $options;
    }
    function getCSSClass(){
    return "checkbox";
    }
    function getConfigForm($id,$values){
    return "Checkbox Options:";
    }
    }
    class CheckboxFromValues extends CheckboxField {
    function CheckboxFromValues($fieldName=null){
    CheckboxFromValues::__construct($fieldName);
    }

    function __construct($fieldName=null,$params){
    $params['fromDb'] = true;
    parent::__construct($options,$params);
    }
    function getConfigForm($id,$values){
    return "";
    }
    }

  39. Ryan

    Sorry for the double post – its stripping out the HTML which is why Ervalds code didnt work. The full code change can be found at:

    http://www.ryanmalin.co.uk/checkboxes.txt

    If the link is automatically stripped out of this post just click on my name above ;)

  40. Faisal

    Great plugin!

    Is it possible to search ‘title’ of the post and ‘one of custom fields’ through ‘one’ input box? Can someone help me in this regard.

  41. don

    Hi Faisal,

    No sorry at present this is not possible. This is on my todo list, although at present I’m not finding a lot of time to spend on this.

    Thanks,
    Don

  42. don

    Hi Alex, Sorry I didn’t get onto this sooner, do you have a url I could look at?

  43. don

    Thanks Ryan/Ervald,

    I’ve added this code into the plugin, (if that’s okay with you?) so it will be included in the next release.

  44. don

    Hi Alex, sorry to take so long getting back to you. Do you have a URL I could look at?

  45. don

    Hi Andy,

    That looks correct. Do you have a url I could look at?

    Thanks,
    Don

  46. Ryan

    No problems here though it is Ervalds code really so may want to check with him. At present its a little rough around the edges as you have to add one new field for each checkbox – which is a little backwards if you want to offer multiple choices. For example Ive created one field for each colour a user can search for which prints to screen as:

    Colour: [] Red
    Colour: [] Green
    Colour: [] Blue

    I’m going to look into changing this so that multiple checkboxes can be added under one label so it prints as:

    Colour: [] Red [] Green [] Blue

    This is a great plugin, thanks Don :) Its open to a handful of XSS vulnerabilities which I’ll email you about.

  47. Ryan

    Double post again, sorry :) Ignore the above, after looking at Ervalds code I’ve realised that its already setup to allow multiple checkboxes per field added. Simply seperate them with a comma such as: red,green,blue

    Emailed you the XSS vulns. Thanks again.

  48. Ervald

    @don

    Of course there isn’t any problem I didn’t do anything. :)

    @Ryan.

    It works for me + multiple option.

    Maybe you forgot something, or I missed a line…

    Here’s a screen:

    http://img23.imageshack.us/img23/8362/hotelsearch.gif

  49. Ervald

    It would be nice if Don could add a sorting bar based on custom fields.

  50. Ryan

    Cheers Ervald, yeh I got it working thanks :) Didnt realise the values could be comma seperated in a single field.

  51. Ryan

    @Ervald : Please can you email me a plain text copy of the code you’re using in extra_search_fields.php to achieve checkboxes with multiple options. Thought mine was working but noticed its only searching for one of the checkboxes even if multiple are ticked and cant figure out why.

    The code you posted before had text stripped out by Wordpress so would appreciate if you can email it to me at: ryan.malin[at]gmail.com

    Thanks :)

  52. Ervald

    @Ryan:

    After testing it more I realized it only showed results of the last clicked option… :(

    I was wrong, trying to figure it out how to make this possible now.

  53. Ervald

    Tried separating them by field but it doesn’t work.

  54. Ervald

    Tried retrieving from 2 Categories using Hidden field or fields (tried both) but it won’t work.

    I’m sure Don can help us achieve this.

  55. Ryan

    Both checkbox values are being sent as my URL shows:

    cs-colour-0=Red&cs-colour-0=White

    Guessing its only searching for one value as you cant use the same name in a GET clause more than once. Depending on whichever is last in the URL is the one that is searched.

  56. Ervald

    I guess we are back to radio-buttons for now…

  57. sinema

    ohh! thanks for crazy plugin.

  58. don

    Ryan/Ervald I think this could be fixed with a relatively small change to the core code, I’ll try to get this into a new release shortly. Thanks for working to improve the plugin.

  59. Jane

    I’m really struggling with the css styling. I would like my input boxes to left align but for some reason the drop down boxes hitch to the right. Any suggestions?

    http://dearauthor.com/test/advanced-search/

    Thanks folks

  60. Ryan

    @Don – Thanks :)

    @Jane: I’d suggest you use Firefox, with the Firebug plugin to help you with your CSS styling. Looks like you need to change searchforms.css, around line 15:


    .searchform-label {
    display:block;
    float:left;
    font-family:sans-serif;
    font-size:1.1em;
    font-weight:bold;
    overflow:hidden;
    padding-top:4px;
    width:35%;

    Try changing the width value to something lower than 35%. You also have 5px left-padding on your select dropdowns which is slightly knocking it out of alignment with the text input fields. Around line 340:


    .widget input#s, .widget input.field, .widget select {
    border:1px solid #CCCCCC;
    padding:3px 0 3px 5px;
    width:250px;
    }

  61. Baga

    Thanks Don, Ervald, Ryan; you’ve done an excellent job so far!

    Looking forward for a working version with multiple checkboxes. I’m actually looking for something very similar to Ervald’s hotel search.

    I wish I could help but I hardly understand some basic php :-(

  62. Ervald

    @Baga

    As soon as there’s a way to make it work I’ll post a copy of the hotel search setup.

  63. Baga

    Thanks Ervald!

    And Merry Christmas to everyone :-)

  64. Jane

    @Ryan – Thanks for the help

    .widget select { border:1px solid #CCCCCC; padding: 0px; margin: 0px;}

    worked, but I had hoped for a plugin specific styling so that it wouldn’t affect the rest of the template.

  65. Ervald

    @Jane

    Try:

    .custom_search select { border:1px solid #CCCCCC; padding: 0px; margin: 0px;}

  66. Jane

    @Ervald

    That works great. Thanks!

    Any suggestions on how to solve Mike’s question at No. 24? I have the same problem in that the search term is not shown on the results page.

  67. Ervald

    @Jane

    I have 2 different templates for search results.

    1=Custom search (search-accommodation.php)
    2=Basic WP search (search-news.php)

    I’ve edited search.php and put:

    And now the title of search-accommodation.php is something like this:

    post_count;
    echo $num.' search results for "'; the_search_query();
    ?>

  68. Ervald

    EDIT Sorry the codes didn’t came through…

    @Jane

    I have 2 different templates for search results.

    1=Custom search >(search-accommodation.php)
    2=Basic WP search >(search-news.php)

    I’ve edited search.php and put:

    ============================================

    ============================================

    And now the title of search-accommodation.php is something like this:

    ==========================================

    post_count;
    echo $num.’ search results for “‘; the_search_query();
    ?>

    ==========================================

  69. Ervald

    @Jane: Sorry again.

    Check the full code here:

    http://www.sourcepod.com/yrvgwe43-2421

  70. Rene

    Love this plugin!

    I do have one question; I’ve been able to add custom css and get the widget to look like I want but where/how can I style the button?

    You can see it on my site http://gamenightphotos.com

    I’d like to add some padding on the right side of the button as well as customize the look of the button itself.

    Thanks in advance for any help!

  71. Ervald

    @Rene

    .searchform-controls input

  72. Rene

    Ervald,

    That helped, fixed now ;)

    Thanks!

  73. Fred

    good plugin! im making a search with 2 (or more) presets, how do i make one submit button?

    thanks for the help!

  74. Pekkos

    Hi Don!
    Thanks for a great plugin, I am currently working on an archive project where custom fields search will be the essential way of getting archived items.

    However, since the project site will be in Swedish, I’ve tried to locate where you populate the first dropdown option with the word ANY, since I would like to replace that with something else.

    Good work, really!

  75. Pekkos

    Ok, found it!

  76. Jason

    Hi Don,
    Great Plugin!

    do you have any plans to create a mulitple select option? also, how many is the max number of custom fields that you would recommend making?
    Thanks,
    Jason

  77. prd717

    This plugin is exactly what I’m looking for.
    Thank you so much for your effort.
    I’m using your version 3.16 WP 2.91 firefox 3.5.7
    I have two issues I wanted to bring to your attention.

    1. I’m showing the most recent posts on the home page and showing only the titles. When performing the search I want to change the order_by.
    I accomplished this in my theme’s in index.php.
    if (is_home()!= 1) $posts = query_posts($query_string . ‘&orderby=title&order=asc’);
    I lose this custom functionality with your plugin. Can you advise in the plugin where I can insert to re-activate?

    2. In the widget I tried to add a third field to search by author.
    data type post field
    data field author
    I try the search and no results
    I go back to the config and the data field is gone.
    I tried several times and it doesn’t seem to stick.
    I finally left the data field=all and the search basically works but not entirely correctly. Thought you might want to know.

    Thanks again

  78. Zoe

    Fantastic plugin – thank you, it’s just what i needed!

    One thing I would like to change for my site and i’m strugglng with…i’m hoping someone can help me…..

    In my search form I have a dropdown for category and two custom field dropdowns, however for display purposes I do not show the field label next to the dropdown. What I actually want to do is change the default “Any” option in the dropdowns to display “Any category” etc, so effectively “Any” plus the field label to make it obvious what each dropdown is for.

    Can anyone help me achieve this? I’ve looked in the code but a bit baffled as to how to change it. Thanks in advance.

  79. sebastian

    hi Don!
    1 question :
    How to change the language in it for example?

  80. Ivan

    Hi Don. I need use Is_home() to do something and is_search() to do another thing when you plugin print search result, but search result indentify by is_home(), not is_search. Can you help me? i am realy need it

  81. Julien

    HI Don !

    How i can choose the “order display” of my category drop down ?

    And add a custom class for the sub-category to add some padding to distinguish Main category of Sub category ?

    Please help me
    Thanks a lot in advance

    I think i have to modify something here (extra_fields_search.php line 675) :

    function getTaxonomy(){
    return $this->param(’taxonomy’,'category’);
    }

  82. Eoin

    Great work Don, thanks.

    I’m trying to use this with flutter, but the dropdown only lists one element of each write panel. Is there something I’m overlooking, or are these two plugins simply incompatible?

    I don’t have a Paypal account, but if you could help I would gladly pay full professional rates.

    Eoin

  83. baga

    Hello Don, Ervald, Ryan, any news regarding the multiple checkboxes? I’d be prepared to pay for this service.

  84. Eoin

    Don,

    Problem solved, as you probably guessed. I RTFM’d a little more thoroughly. You may delete both my comments as noise if you wish.

    Thanks again,

    Eoin

  85. Amanda

    Hi, and thanks for the plugin!

    I’ve got one question, and one problem:

    Question: Any progress on getting the checkboxes mod to search for all checked values?

    Problem: Until then, I’m using select boxes, but I’m not getting an “Any” option, only the ones I’ve listed. I’m assuming that adding that option in myself will cause it to actually search for “Any” as a value… am I missing a step to have it added automatically?

    Thanks,
    Amanda

  86. Amanda

    D’oh, nevemind.

    That’s in the very first FAQ answer in the WP repository. Sorry about that!

  87. Amy

    I’m using your search already for a great idea I had to help the StoryForm community, but I had another idea for my recipe site and I was wondering if you could help me out. Is there a way to make the search exclusive instead of inclusive? Say I wanted to search all posts in a certain category WITHOUT a specific tag. Could I do that?

  88. BAC

    Hi,

    This plugin is almost exactly what I am looking for…

    Quick question:
    I need to filter a certain category out i.e. exclude=20 from the category and custom field drop downs.

    Is this possible currently? Ideally with shortcodes – i.e. [custom-field-search exclude=20]

    Some really cool features I would love to see added to this plugin are:

    1. post count next to each option (with ability to filter post count by excluding posts that are children of certain category’s)

    2. ability to select multiple options from the drop downs with check boxes after each option.

    3. place holder text that is added/removed when the form elements are given focus. (for accessibility validation)

    I may be in a position to make a small donation to aid the development of these features if it will help. Maybe give me an idea of scope and I’ll see what I can muster.

    Cheers

    BAC

  89. Martin

    Hi,
    It seems that there is a bug in your plugin. I added a list of countries (around 200) as Drop Down Options, but when I save it, the widget disappears from the front page. When I enter only around 20-30 values, it’s OK.
    Do you know how I can fix that?

  90. Martin

    One more question: In my widget users can choose from a drop-down of a list of countries and I have included all the custom fields options manually. Is there any way the user can select “Any/All” in the widget instead of selecting a specific country?

  91. Amanda

    @Martin

    I was confused about that too, but I found the explanation in the first question here:
    http://wordpress.org/extend/plugins/wp-custom-fields-search/other_notes/

    Just make the text “Any/All” as your first option, and put a colon ( : ) right in front of it.

  92. Martin

    @Amanda Thanks!!! That fixed it perfectly. Any idea about my previous question? Why does the plugin crash (disappear) after I include a lot of custom field options?

  93. Amanda

    Sorry, I don’t know. I’m a n00b with php, so I don’t know the inner workings of the plugin, I only knew your last one because I’d run into the same thing myself. Hopefully the author or another programmer can step in to help with that. Glad to have been a little bit helpful, though!

  94. fadzril m

    Hi Don,

    How to put and list specific category for dropdown? List down only subcategories name that have post?

  95. baga

    Hello Don, Ervald, Ryan, any news regarding the multiple checkboxes? I’d be prepared to pay for this service.

  96. brian

    Loving this plugin!

    Question: how do I get the search results to display in the default WP way? With this plugin deactivated, search results show up in a title list (and in my case with a thumbnail image). When I activate your plugin, the search results return as a full post.

    Thanks for the help.

  97. Danilo Naranjo

    Hello, I’m from chile.

    I have a question, as I can make the wp-custom-search, the search button is disabled if no income.

    Would greatly appreciate a response.

    Greetings.

    Bye

  98. Wes Gue

    Great plugin,

    Just one problem/question, how do i make the search output go to a page, (ie. search page) right now it just replaces the latest posts on the homepage with the results.

    Thanks in advance!

  99. Donna Vitan

    Hello,

    Awesome plugin so far. Like Wes Gue, I’m wondering how to customize/redirect to a custom search results page.

    I have customized the header banners to correspond to whatever page you are on and the search results for this does not yield the appropriate search results header banner.

    I would also like to add a few content/details to the results page.

    Any help would be greatly appreciated. Thank you.

  100. Kamil

    Hi Don!

    Great plugin! I love it!

    I was wondering if it would be possible to modify it so instead of showing all the search results it would open the first result (like I’m filling lucky on google) because the search that i’m using requires to select every option and there is allways only one search result.

    Please let me know if anyone have any ideas. Thanks!

  101. Jokke

    Hello,

    and thanks for a great plug-in. I was just wondering is it possible to add translation for the labels and the widget name.

  102. สร้างเว็บ

    Thank you for plugin, it’s very useful.

  103. Judson Jaurez

    Great job! Can’t wait to start my own blog.

  104. Jokke

    Do anybody know how to make it work with wordpress multilingual plugin http://wpml.org.

  105. Shalon Morlock

    A Fantastic wordpress post, I will be sure to save this in my Mixx account. Have a great evening.

  106. Ryan

    I haven’t tried fixing the multiple checkboxes issue as Don mentioned in an earlier post that he’d fix it in the core for the next release. I’ll be using this plugin again (needing checkboxes) on a new site Im building so will take another look then if Don hasn’t already pushed out an update :)

  107. Cou

    Hello,

    @Ryan
    Please!

  108. baga

    Ryan if you can help you’ll be our hero.

  109. Noel

    Thanks for the very useful plugin.

    Is there a premium version or a way to remove the footer “DB WordPress plugin”? This site is for a client and they don’t care about branding.

    Hope you understand.

  110. Ryan

    Sorry guys, I haven’t had any luck in getting multiple checkboxes to work :( I’ve emailed Don asking for a quote if he can fix it.

    The only way I have managed to get this to work (which was an incredibly poor hack) was to create a new field for every checkbox option (eg, one field for Red, one field for Green etc – instead of having one comma seperated list in a single field). This does work, but it required exhaustive changes to the CSS and template to hide all of the additional labels etc. It certainly couldnt be used on a live site.

  111. ole

    This is a great plugin. Is there a way to sort the search results by title or custom field value?

  112. Ton

    I am trying to decrease the size of the fields in the search form. They are too long. Here is the search form in my style.css but nothing I do is changing the length. I am doing something wrong or not in the right place. Can someone give me some advice?

    /* search form */
    .searchform {
    display: inline-block;
    font-size: 100%;
    padding: 0;
    margin-bottom: 2px;
    }
    .searchform .searchfield {
    /* width: 50px;*/
    padding: 4px 7px 2px 5px;
    color: #999;
    border: 1px solid #888;
    margin-top: 6px;
    }

    .searchform input[type="submit"].searchsubmit {
    background-repeat: no-repeat;
    background-position: 0 0;
    height: 24px;
    width: 12px;
    border: none;
    cursor: pointer;
    text-indent: -999%;
    margin: 0;
    padding: 0 3px 0 3px;
    }

    Here is the actual page.

    http://www.eyestrane.com/custom-search-page/

    Thanks!

  113. Tommy

    Don, PLEASE fix plugin for multiple checkboxes.

  114. Ash

    Great plugin ben, is there anyway of changing the plugin so it uses its own independant url when searching rather than piggy backing the root url?

    Is causing a few issues with my template and setup etc…

  115. Adam

    Great plugin! I am having some issues using this plugin with a very large database of about 20,000 posts, searching only one custom field. The results page times out for results over about 20 it seems and renders a blank page. Other than raising the max execute time for PHP, is there anything else I can do or create an error message to prevent the blank page?

  116. Joe McDonald

    Hi,

    I wonder if anyone can help me here as I am at my wits end with this as I am working on a media website for congressional clips and need a functional search:

    1) is it possible to have one field search two custom fields? Right now, unless I am doing something wrong, I can only get one custom field per entry.

    And 2) Able to only search full words. So when you type in AIG campaign does not come up. Is there a use of wildcards ect…

    Any help on this would be appreciated and if someone has experience coding this please contact me at joe@damoclesdesigns.com

    Joe

  117. Eos

    Okay, I would have saved myself an insane amount of trouble if only I’d discovered this sooner! You’re amazing for having created such a useful script.

    I’m now trying to modify the display a bit. Is there any way to replace the “ANY” in the dropdown with the “Label”?

  118. ompiang

    Cool! Thanks for shared nice info.


Leave a Reply



Back to top