Hi there,

Since upgrading to 1.7 I noticed the tabs had been removed for our various search pages, on investigation it appears to have been removed by this snippet in apachesolr_search.module:

// Tests whether apachesolr_search is the only enabled search module (in
// which case there are no tabs).

    $active_module_info = search_get_info();

    $no_tabs = (sizeof($active_module_info) == 1 && isset($active_module_info['apachesolr_search']));

We only have the one enabled search module, but we do have multiple apache solr search pages for various areas of our site, previously these would appear as tabs which was our desired behaviour.

Is it correct for the new version to assume no tabs should be rendered if only apache solr search is enabled?

Regards

Comments

cristiroma’s picture

Status: Active » Needs review
StatusFileSize
new833 bytes

I've just hit the same issue and from the commit http://cgit.drupalcode.org/apachesolr/commit/?id=ace43a0 I don't exactly understand which problem tries to solve @ line 181. I am rolling it back and uploading a patch for this.

stefan.r’s picture

Status: Needs review » Needs work

That is indeed what we were assuming :)

There may be a case where there have to be tabs, but that should be an extra test instead of just taking out the code.

paulbeaney’s picture

StatusFileSize
new852 bytes

Hi,

I ran into the same problem, but I propose a slightly different way of getting round it: if Solr is the only search module, but there is more than one search page configured, revert to tabs, otherwise stay tabless.

Regards,

- Paul

teknocat’s picture

+1 on paulbeaney's suggestion.

I have a site where the tabs were the only way to navigate between all the different search pages on the site. Only two of them were actually accessible elsewhere, so I need to have tabs for this to be usable in my case. paulbeaney's patch makes the most sense to me.

teknocat’s picture

StatusFileSize
new100.06 KB

Having applied paulbeany's patch with success, I'm finding another problem, but I don't see how it's actually related to this module. Even though I can confirm that the tabs are having their titles set correctly, by using watchdog to log the menu items after they've been altered, reviewing the menu cache and seeing them there correctly, they all just have a generic title of "Search results" until you actually submit a search. I cannot for the life of me understand this. I don't see at what point they are being reverted to this. It makes no sense. See attached screenshot for example (or just visit http://nwtarts.com/search/artists for example).

This was also never a problem before the version 1.7 update. Does anyone else see this happening on their site?

teknocat’s picture

I have determined exactly where the second issue with the tabs are that I just commented on. I will submit a new support ticket (if there isn't one already) for that issue as it's not the same as this one. It's the title callback function that's the problem.

ecarty’s picture

What work is required on this? paulbeaney's patch (#3) worked for me too.

stefan.r’s picture

The patch needs to be reviewed to see whether the concern in #1314664: Search pages custom pages title setting does nothing is addressed, if not it may need rework

joshua.boltz’s picture

The patch for #3 fixes the issue where the tabs were not displaying for each of the Search pages setup in the Solr configuration.

kupide’s picture

Status: Needs work » Needs review
StatusFileSize
new956 bytes

Patch #3 works for me too.

I re-uploaded the patch #3 with a correct name and format.

kupide’s picture

StatusFileSize
new785 bytes

Oups, bad patch uploaded in the previous comment.

Right path here !

oliverpolden’s picture

#11 works for me and agree with the solution.

oliverpolden’s picture

Status: Needs review » Reviewed & tested by the community

  • japerry committed f4d58b0 on 7.x-1.x authored by kupide
    Issue #2333447 by kupide, cristiroma, paulbeaney, teknocat: No tabs with...
japerry’s picture

Status: Reviewed & tested by the community » Fixed

Patch #11 looks good, fixed.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.