Jump to content

Archived

This topic is now archived and is closed to further replies.

Redita

Search working strange / not working

Recommended Posts

Redita

Hello everyone, my first post here with something that is really strange:

 

The search is either returning results for words that are not present in the page (actually  the results snippets shows a very old version of the page, like 2 weeks old). In another case the search returns no results at all. 

 

My web: http://nexinteractive.heidicruz.com/outbound/ 

 

Two examples to replicate the problem using the search box on the nav bar on top:

 

1. Search for the word "local". You'll get 1 result, cool. But the snippet in the results page is of an old version of the page!! Click on it and it takes you to a page titled Outbound. The problem: the word "local" is nowhere in the page. It was in an older version of an iBox, which was modified and no longer contains the word "local". 

 

2. Now search for the word "skill". You'll get 0 results. But that word is in an iBox in the page titled Inbound. Same structure as the Outbound page.

 

Thank you in advance for any help you guys could give.

--------

My settings right now:

 

a. I have this option active in the Pro plugin "Enable WordPress search to look inside section content, eg. textbox/hero/etc. DMS2 Only"

b. DMS2 version 2.1.8

c. Wordpress 4.0

d. Active Plugins: Contact Form 7, DMS Professional Tools, Google Analytics by Yoast, Pagelines Updater, Wordpress Importer.

e. Debug mode: ON

Share this post


Link to post
Share on other sites
Simon

Question did you modify the ibox, reuse it, or its a new ibox.. im thinking there are multiple ibox section entries in the db and its picking the 1st it finds.

Share this post


Link to post
Share on other sites
Redita

For the Outbound page it's a reused iBox from the one in the demo content. For the Inbound page is a duplicate from the former (I think since it was linked to the template I just applied the same template). Both pages are unlinked from the templates now. There are multiple iBoxes, yes.

Share this post


Link to post
Share on other sites
Redita

Is that a problem? Multiple iBoxes? and how about the keybords the search can't find for the other page, the "inbound" titled page? I'm really baffled 

Share this post


Link to post
Share on other sites
Simon

The search is finding an old unused ibox config, you could delete it from the sections database table.

Share this post


Link to post
Share on other sites
Redita

Done. Now it's not finding anything. The entry was not in the sections database table, but in posts.

But besides that, it doesn't explain the behavior for the other page (point 2 of my original question). I'm noticing that nothing that is in the sections is being found. Only things inside the loop (wp content). For example, look for the word "prospector". It will find it because it's on a WP content/Loop section on the About page. 

 

I already have this enabled in the Pro plugin: "Enable WordPress search to look inside section content, eg. textbox/hero/etc. DMS2 Only"

 

Ideas?

Thank you man.

Share this post


Link to post
Share on other sites
Simon

It will only find text in sections that are local to the page/post. Not saved to a template.

 

For example... http://pross.org.uk/multisite-anti-spam/this post is set to local template handling: http://i.nzb.mx/image/0l2b202p2n1f this is vital as section settings are saved to the post meta area.

 

So now when i search for 'best beer' i get a result: http://pross.org.uk/?s=best+beer

Share this post


Link to post
Share on other sites
Redita

I see how it's working on your test site. But I did have them in LOCAL, as your screenshot.

Do you want an admin to my site?

 

Share this post


Link to post
Share on other sites
Simon

Sure if you want, PM me.

Share this post


Link to post
Share on other sites
Simon

GOT IT prospector now returns a result. Fixed it in the plugin.

 

 

For the sake of google... plugin didnt take into account the user changing wordpress db prefix.

Share this post


Link to post
Share on other sites
Redita
Sorry to interrupt your triumph dance (I was dancing too but then did some searches :(

The word "prospector" was an example of a word that worked because it was on the loop. It was always findable. Also I haven't change de DB prefix. This is a recent install with no one touching the DB.

Now I'm having partial results:
Some words from the iBox on the Inbound page are being found. Some are not ("global" doesn't return results).

For the Outbound page iBoxes or other sections whatsoever, nothing turn results. Searched for "dynamic" or "allow". Nothing.

Share this post


Link to post
Share on other sites
Simon

Im not sure what the page difference is, it should work.

 

The search query is very simple and unfortunately quite dumb im afraid.

Share this post


Link to post
Share on other sites

  • Similar Content

    • mtaus
      By mtaus+
      How can I remove the Search function from NavPro?
    • John Olsson
      By John Olsson+
      Hello, i'm working on a webshop, and got this code to really boost the search within WP. But when adding this code to functions.php the front end media library search flipped totally, and not working at all, any ideas what's the problem?
      function atom_search_where($where){ global $wpdb; if (is_search()) $where .= "OR (t.name LIKE '%".get_search_query()."%' AND {$wpdb->posts}.post_status = 'publish')"; return $where; } function atom_search_join($join){ global $wpdb; if (is_search()) $join .= "LEFT JOIN {$wpdb->term_relationships} tr ON {$wpdb->posts}.ID = tr.object_id INNER JOIN {$wpdb->term_taxonomy} tt ON tt.term_taxonomy_id=tr.term_taxonomy_id INNER JOIN {$wpdb->terms} t ON t.term_id = tt.term_id"; return $join; } function atom_search_groupby($groupby){ global $wpdb; // we need to group on post ID $groupby_id = "{$wpdb->posts}.ID"; if(!is_search() || strpos($groupby, $groupby_id) !== false) return $groupby; // groupby was empty, use ours if(!strlen(trim($groupby))) return $groupby_id; // wasn't empty, append ours return $groupby.", ".$groupby_id; } add_filter('posts_where','atom_search_where'); add_filter('posts_join', 'atom_search_join'); add_filter('posts_groupby', 'atom_search_groupby');  
    • Queue-it
      By Queue-it+
      HI,
      Search function doesn't seem to work. 
      When ever searching for something it redirect to the home page and add the search string to the url.
      For example searching for "cases" it would display https://queue-it.com/?s=cases
      Do you know how to solve that? 
    • MissT
      By MissT+
      The featured images from the search results page seem to be missing - the featured images are there when you view the individual posts and on the Magazine section blog page but there are broken links on the Search Results page. See screen shot...
      WP - 4.4.2
      Platform5 - 5.0.132
      Can provide a link to the site privately.
      Many thanks in advance.

    • Lisa Haran
      By Lisa Haran+
      Hi 
      I have a map here http://www.iloveoffset.com/maps/
      I want to add several pointer locations to the map, but when I do they do not appear.
      On this map there are 2 pointer locations and as you can there is only one visible.
      Earlier today I added 7 and could only see 4 so there is something odd going on.
      My theme is up to date
×