Home › Forums › Calendar Products › Events Calendar PRO › Hijacking Tags Search
- This topic has 25 replies, 2 voices, and was last updated 10 years, 10 months ago by
Geoff.
-
AuthorPosts
-
May 5, 2015 at 2:32 pm #960672
Ryan
ParticipantIt seems your plugin is hijacking the tag cloud search on my site. I found this thread in your forums where others seemed to be having a similar issue:
I noticed in this thread that there was a developer reply with a code snippet to fix this problem, however I cannot see the code snippet. I’m not sure if it has been deleted or if something else is going on that isn’t allowing me to see it, but it would be super helpful if you could send me that code or let me know if you have since found another solution.
Thank you so much!
May 6, 2015 at 7:22 am #960788Geoff
MemberHi Preston!
Here’s the snippet that the other thread referred to. Give that a shot and let us know if that helps. π
Cheers!
GeoffMay 6, 2015 at 7:45 am #960801Ryan
ParticipantThanks! And just to be sure, does this code get pasted into the functions.php or somewhere else?
May 6, 2015 at 7:57 am #960806Geoff
MemberYou’re spot on–it goes in functions.php. π
It may or may not need the the opening PHP tag, depending on how your functions file is formatted.
May 6, 2015 at 8:34 am #960836Ryan
ParticipantI was really hoping this would do the trick, but it seems even after pasting this code in the problem is still not fixed. Is there any other solution to this problem?
May 6, 2015 at 9:54 am #960870Geoff
MemberHey Preston–thanks for following up!
Can you elaborate a little more on how Events are hijacking Tags? I tried setting up a Tag Cloud widget on my local installation and the widget appears to be working as I would expect with Posts and Events. Is it that you want tagged Events to be removed from the widget’s filter altogether?
Thanks!
GeoffMay 6, 2015 at 10:09 am #960879Ryan
ParticipantHere is the page I am working on: http://ncsml.org/oral-histories/
The tag cloud is nested in the accordion near the top labeled “Search by Key Words”.
I have also set up the tag cloud on a separate page here (to make sure the accordion isn’t causing the error): http://ncsml.org/tag-cloud-test/
When a tag is clicked, no results come up. That is because the events calendar is “hijacking” the search to only search events’ tags. It isn’t that I necessarily don’t want events coming up in the search, it is just that we are mainly using tags to sort through portfolio posts. Each tag in the tag cloud is attached to at one portfolio post and yet the search results are coming up empty because it is only searching the events.
Hopefully I am being clear. Let me know if I can clarify any more or if you need any other info from me.
Thank you for your help!
May 6, 2015 at 2:48 pm #960971Geoff
MemberIf I didn’t mention it already–nice site! I love how it’s coming along. π
Thanks for helping elaborate on this. That helps a lot.
I tried using the Tag Cloud widget on my local setup and it seems to be working well with both posts and events there. I see you noted having tried activating a default WordPress theme (like Twenty Fifteen) and deactivating all other plugins. Did you happen to see any difference under those conditions? How about when you activate a default WordPress themeΒ and deactivate other plugins together?
These steps are outlined in greater detail here. When you test, I think it would be a good idea toΒ re-save your permalinks each time and make sure the site’s cache is flushed, if it uses caching.
Let’s give that a shot and see what we find. π
Cheers!
GeoffMay 6, 2015 at 4:44 pm #961005Ryan
ParticipantThank you for the compliment on the site. π
I have tried deactivating all plugins and switching to TwentyFifteen. I tried each separately, and then also both at the same time. Unfortunately, in all 3 scenarios I get the same result – the tags are still not pulling up any results. (images below)


I know that doesn’t seem to get us any closer to the solution. This has me stumped!
May 7, 2015 at 7:25 am #961130Geoff
MemberShoot! I thought that would help us find something.
I don’t want to fully rule out the possibility that some sort of caching is preventing this from working properly. I see you have both W3 Total Cache and Yoast SEO installed. Does your hosting provide any additional object caching? Either way, let’s try clearing the cache out from all those sources, deactivating them and trying again.
If that doesn’t reveal anything, then I think our next best route is to set up a clean install on a test server. Let me know how clearing cache goes first before we head down this road, and I’ll provide you with the steps, if needed.
Cheers!
GeoffMay 7, 2015 at 7:36 am #961134Ryan
ParticipantThis reply is private.
May 7, 2015 at 8:14 am #961156Geoff
MemberHey there, Preston!
Thanks for working with me on this so far–I appreciate your help and patience. π
I know that the thread you referred to in the beginning seems similar (and it is in some regards), but it appears to cover a different issue. Your tag archives are not 404s and no posts are displaying, whether they are posts or events. So, we need to troubleshooting this one differently.
The test site you have up is great, but I want to scale it back even further. The next thing I would like to try here is creating a fresh test site–this will avoid any disruption to your live site and ensure that we’ve effectively got a “clean canvas” to work with.
- Please install a fresh copy of WordPress in a subdirectory (if you have cPanel hosting account there will probably be a one-click install to make this really easy)
- Don’t install anything except The Events Calendar, Events Calendar PRO and Community Events
- Please also stick to a default theme–again, there’s no need to install anything else just yet!
- Create a few events and default posts–both with tags–so we have some test data to work with
- Can you replicate the same problem?
If you find you can replicate the problem under these conditions it would be awesome if you could stop and let us know so we can take a look while the site is still running under default conditions.
Thanks for your help!
Geoff
May 7, 2015 at 9:11 am #961182Ryan
ParticipantI wanted to share this with you:
https://www.dropbox.com/s/gzt13mh98nt5i5y/NCSML%20_%20Journalism%20Archives%20-%20NCSML.pdf?dl=0
It is the output from the Query Monitor plugin, which includes a ton of debugging information. I think it might make more sense to you than it would to me. Maybe there is something in there that is pointing to the problem.
I also wanted to make a note of something that may or may not make a difference – none of the events on the site are tagged. So, I still think the problem is that it is only searching events and displaying those results (which just happen to be no results because no events have those tags). I will do a test of this by adding some of the common tags to an event and seeing if the tag cloud then pulls up that event. I will let you know my results!
Thanks again for your help on this!
May 7, 2015 at 1:44 pm #961294Geoff
MemberThanks Preston! Definitely keep me posted on the progress with the fresh install–I’ll be interested to see how things work in a default condition. π
Geoff
May 8, 2015 at 8:19 am #961468Ryan
ParticipantI set up the test environment here: http://www.ncsml.org/test/
I added two posts and two events and the tag cloud search does appear to be working. What is the next step in this test?
I also added some of the tags to Events on the actual site to test out if the tag cloud search was just not working altogether, or if it was just only searching the Events posts. The event I tagged did come up in the results, but no other posts did. (screenshot below)

One other thing I noticed is that the tag search is also being affected on the backend. The tags are shown with the “Count” beside them, but when the count is clicked on it only brings up Events tagged not all posts with that tag.

-
AuthorPosts
- The topic ‘Hijacking Tags Search’ is closed to new replies.
