• 0

Accordions Is it possible to make a link trigger an accordion to open?

Question

Posted · Report post

First of all, I LOVE the accordion section. I've used it on a number of sites, and it is so easy and a great way to have a lot of information without overwhelming the reader. Nice work!

 

I would love to be able to link to a page and have a specific accordion open. I tried using an anchor, but that did not work. Is this even possible? 

Share this post


Link to post
Share on other sites

33 answers to this question

  • 0

Posted · Report post

ellenmva When I disable Relevannsi, the search is still slow, and when I get the results, the links lead to error 404 pages. :(

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

flourishdesignstudio I need to see the error and can't reproduce on my end. Could you create a WordPress Admin login for me and send it to ellen @ elsue.com so I can try and troubleshoot. I'll just create a separate test page.

 

On the search, when disabling Relevanssi and getting 404 error, try going to your Settings --> Permalinks and save them again. Sometimes that will resolve a 404.

 

I'm not sure why the search is so slow, was it slow before Relevanssi or okay? 

 

Best,

 

Ellen

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

Hi Ellen!

 

I've sent you login creds. :) Thanks for looking into the problem.

 

I just tried resetting permalinks, but it dod not resolve the 404 errors. :(

 

Because the site is made up almost entirely of accordions, we did not have a search enabled before, because the results were not complete. So, I'm not sure about the speed before. Do you think it takes longer to search through custom post types? Maybe it's the number of accordions that it has to search? We do have a lot of them!

 

 

 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

flourishdesignstudio Will have to dig deeper into search, it may be the number of posts it has to search but may be some solutions, I think Relevanssi has some settings that will help. I have to go out for a bit but will take a look later today.

 

I think it may be another plugin that is causing that error, likely candidates are Duplicate Post or TinyMCE Advanced. Could you disable both of those plugins and see if the error resolves. If it does, reactivate each one and test to see if it causes the error. Let me know if it is one of them and we can go from there.

 

Best,

 

Elen

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

I just disabled both plugins, and I still get the error. And, I only started getting the error when I started working with accordions last week. (Updating and/or using short code - not sure which may be causing the issue.)

 

I just did another test and it only creates the error when I am working on pages with accordions.

 

 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

flourishdesignstudio Okay, I was able to replicate the Warning on another site which is good, didn't want to debug on your site yet couldn't replicate.

 

For now, you can get rid of the warning message by turning WP_DEBUG to false. In your wp-config.php file find the line that says

 

define('WP_DEBUG', true);

 

and change true to false.

 

What you are seeing is a warning and not an error, thus turning debug to false will make it go away.

 

I still have to find the reason it is happening. Will keep you posted.

 

On Relevanssi, you just need the Expand shortcodes option checked and pages/posts checked, not the accordion post type or taxonomy because it's a private post type, not public. The page that the accordion is on will show in the search results.

 

If you want to explore the option of having each separate accordion show in the search results that would take some customization, probably not much but make the post type public and give a slug. That won't solve the slow search.

 

Not sure why your search is slow, that shouldn't be Accordions but will test on a local install and get back to you.

 

Best,

 

Ellen

 

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

ellenmva Hi again! Thanks for working through this with me. I just checked my wp-config.php file and debug was set to false already. Should I try true?

 

I think it would be awesome if the search results would lead to an open accordion. What would that entail. Feel free to email me privately at jackie (at) flourishdesignstudio.com.

 

Thanks again!

 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now