I am trying to figure out what is the best method for taking the search box out of the #navbar region and placing it so that it is located in the uppermost right corner of my site.

I am aware that there is a search form block in the block region (#block-search-0) and a search box option in my theme setting in toggle display section(#search.) I am not sure which is the better "search" to use, or how to place it in the appropriate section.

Comments

mjasonbaker’s picture

Title: What is the best method for relocating search box » Zen Search Box issues

I took the Search box out of the navbar section and moved it up to the the <div id="logo-title"> section of the page.tpl.php. It looks like this:

      <?php if ($logo or $site_name or $site_slogan): ?>
        <div id="logo-title">

          <?php if ($search_box): ?>
            <div id="search-box">
              <?php print $search_box; ?>
            </div> <!-- /#search-box -->
          <?php endif; ?>

          <?php if ($logo): ?>
            <div id="logo"><a href="<?php print $base_path; ?>" title="<?php print t('Home'); ?>" rel="home"><img src="<?php print $logo; ?>" alt="<?php print t('Home'); ?>" id="logo-image" /></a></div>
          <?php endif; ?>

It looks great in firefox, but doesn't show in ie.

The CSS looks like this:

  #search-box /* Wrapper for the search form */
  {
    position: absolute;
    padding: 0;
    top: 75px;
    right: 10px;
  }

can anyone tell me why it is not showing in ie and how to fix this?

mjasonbaker’s picture

Title: Zen Search Box issues » Search Box disappears in ie when not logged in

my search box in the header above right sidebar and my aggregator block in the right sidebar are missing in ie7 until I login. They show fine in firefox whether I am logged in or not.

Once logged in, they show fine in ie. What am I missing, how do I fix so it also shows the same when not logged in?

mjasonbaker’s picture

Title: Search Box disappears in ie when not logged in » Search Box disappears in browsers when not logged in

Ok, so it turns out that both the search box and my aggregator block disappear in both browsers when not logged in.

Some quick advice would be appreciated.

mjasonbaker’s picture

Status: Active » Closed (works as designed)

Just needed to check permissions for both authenticated and anonymous roles.

auraz’s picture

Same problem - all good in FF3 and Opera 9,6 but in IE for anon user - logo and primary links arnt shown.
I did the same for primary - put it in header region.
For admin in IE all OK.
Have you found any solution?

avolve’s picture

An issue I am experiencing with a site my be related — the search box de-toggles itself for a custom zen sub-theme. This is for logged in users and anonymous users — I am not sure yet if this coincides with the admin account logging out, or is a time based issue. Once i go back into the them and re-select the search box, it comes back...

[Zen 6.x.1.0]

evandroks’s picture

The Solution is:

If a Block (like Search , Contact Form, etc) just appears when the user it´s logged , you have to do:

1-Go to page www.NAMEOFYOURSITE.COM/?q=admin/user/roles

(or go to User Management, Roles)

2-In Authenticated Users, click on edit permissions
Check all the boxes
Click on Save permissions

3- In Anonymous Users,
click on edit permissions
Check the following boxes:
block module - use PHP for block visibility
contact module - access site-wide contact form
locale module - translate interface
node module - access content
search module - search content e use advanced search
translation module - translate content
upload module - upload files

Click on Save permissions

Evandro
Brazil

rynsa’s picture

Title: Search Box disappears in browsers when not logged in » Search Box De-Toggles and Disappears
Project: Zen » Nitobe
Version: 6.x-1.0-beta3 » 6.x-1.1
Assigned: Unassigned » rynsa
Priority: Normal » Minor

@avolve

Were you able to resolve this issue? I'm having roughly the same problem - search box inexplicably de-toggling - though with a different theme (Nitobe). I thought it might be a permissions or roles issue but everything seems to be selected properly selected (admin > user management > roles/permissions).

Very frustrating, indeed. Holler back if you find a solution.

I checked out your site(s), by the way. Very elegant. Big fan of the bike content, too!

rynsa

avolve’s picture

@rynsa I have yet to resolve this. I checked the site again tonight to find the search box not displayed — http://www.sandon-point.org.au

The search box is enabled globally. I have enabled it on the admin theme (garland) & re-enabled it on the zen sub-theme.

It is still there since logging out this time. Will see if it stays.

wrt the bike content, do you mean http://bike.veganarky.net ??

heatherann’s picture

This totally worked for me. Thanks Evandro!

3goose’s picture

I've been very frustrated with this issue as well. I make a couple dozen themes a year, usually using Zen as a base theme. I've quit using the search box variable, toggled on in themes, and only use the block version now, because of these de-selection and disappearing issues. When it happens on a site, it usually only lasts a handful of hours at most, then is gone. When I check the admin/build/themes settings, it's been de-selected! At first i thought it was a co-worker messing with me!

theusualsuspect’s picture

I have the same issue when using print $search-box .. it mysteriously vanishes, and de-selects itselfs...I think this happens when I change something in the block configuration ...

Anonymous’s picture

Assigned: rynsa » Unassigned
Status: Closed (works as designed) » Closed (fixed)

I am closing this issue as it seems to have lost focus.

If you are experiencing an issue with the current version of Nitobe (6.x-4), please create a new issue describing the problem. Issues with and comments on the Zen theme should be made in that theme's issue queue.

harryadu’s picture

@evandroks: Beautiful!!