Jump to content
Sign in to follow this  
cfisher

Search Bar In Menu Disappears Only In IE7

Recommended Posts

cfisher

I am using WHP Version 3.0.4. I just noticed when viewing my website in IE8 in IE7 compatibility view, the search box disappears from the top menu (only in IE7). I use the template option to have this appear in the menu and are not using a widget. Suggestions? Chris

Share this post


Link to post
Share on other sites
Andrew

Can you post a link to your site?

Share this post


Link to post
Share on other sites
cmunns

This issue is that in IE7 the last submenu item extends to the end of the bar which pushes the search away. My first suggestion would be to assign a max-width to those subnav items. ` #sub_head ul li { max-width:120px; } ` Add this to your ie7.css stylesheet

Share this post


Link to post
Share on other sites
cfisher

I considered this; however, the last sub menu item "Therapy" is almost 100 px away from the search bar. I'm not sure why that would affect it (and only in IE7)? I don't doubt you though...you guys know best about these templates. Is there an easy way to add this CSS to the stylesheet without having to remember to do it with each upgrade? Thanks!!

Share this post


Link to post
Share on other sites
bryan-hadaway

Yes, when adding to Custom CSS from your Theme Options this can be saved to the db and you're not actually altering files that will get overwritten during upgrades. Thanks, Bryan

Share this post


Link to post
Share on other sites
cfisher

Oh. I get it your recommendation cmunns. You mean the drop-down sub menu for navigation. I thought you menu the sub-menu for categories. I removed the drop-down nav - not worth the hassle. Darn Internet Explorer! Always causing layout havoc.

Share this post


Link to post
Share on other sites
cfisher

Nope that that didn't fix it. You were talking about the cat sub-menu.

Share this post


Link to post
Share on other sites
cfisher

I added the CSS to the Custom CSS as suggested by Bryan. This changed, but did not fix, the search bar problem in IE7. It simply pushed the search bar off the navigation menu and onto the first post on the site. I did not want to leave this so I took a screen shot. Note that the search is under the category "therapy". Navigation-Problem.jpg

Share this post


Link to post
Share on other sites
cmunns

It's unfortunately really hard to debug a browser that doesn't have developer tools and on someone else's site, but , I think I've got a solution. Instead of ` #sub_head ul li { max-width:120px; } ` just assign a width to the parent element in general `#sub_head {width:100%;}`

Share this post


Link to post
Share on other sites
cfisher

Sorry this is such a hassle, but the new code did not work. The search bar disappeared again. I am not sure why you have trouble testing this. This problem even occurs in your demo. It is not specific to my website. Just view your WHP demo and select The Blog in IE7 compatibility view.

Share this post


Link to post
Share on other sites
cfisher

I went ahead and removed the search box from the nav bar (through the options) since none of these fixes worked. I added the Search Widget since I need to have a search function. The Search Widget does not layout right in IE 7 or IE 8. The "search button" drops below and out of alignment with the search box - looks really janky. So my options for IE is no search bar in IE7 or a jacked up one in IE 7 and IE8. There has to be a better way?

Share this post


Link to post
Share on other sites
bryan-hadaway

Back to the original issue, here is a possible solution, adding this to your Custom CSS: `#nav ul{width:940px}` You may need to play with lowering 940 to get it right. Thanks, Bryan

Share this post


Link to post
Share on other sites
cfisher

It didn't work; however, this may not be the appropriate code. I noticed when I made adjustment to the

#nav ul{width:940px}

it affected the MAIN (top) menu. The problem is the last category in the SUB NAV menu pushes the search bar off (despite the last category not even coming close to the search bar). Basically, the last category parameters extend past the end of the sub nav menu in the first column and all the way to very end of the 2nd column. As I mentioned, this issue even affects your WHP demo. Try/test it out, and you will see what I mean. It might help resolve this quicker if you test on your own demo.

Share this post


Link to post
Share on other sites
cmunns

Really sorry about this inconvenience. So apparently there were two issues with the code. If you go to your sub_head.php file there is a portion that needs to look like this `

<?php if(!is_page_template('page-highlight.php') && !pagelines('hidesearch')) include (THEME_LIB . '/_searchform.php'); ?>
  • <?php wp_list_categories('include='.pagelines('subnav_categories').'&title_li='); ?>
` This is how the code should look AFTER the second elseif statement. If you want to wait I'll be updating the theme package shortly.

Share this post


Link to post
Share on other sites
cfisher

Thanks!! I appreciate your help. I'll wait for the theme package update.

Share this post


Link to post
Share on other sites
cfisher

You guys will love this. I updated to WHP 3.0.9. All my settings, etc. transfered over fine and the template and site are running fine; however, I cannot test the fix for the search bar because when I switch the setting in WHP options to show the search in the nav bar, it will not save my settings. I then noticed that none of my settings in WHP will save now. Could be database related, but doubtful since everyone else runs fine.... but I thought I'd let you know about this before I did anything drastic. Please advise on how to proceed.

Share this post


Link to post
Share on other sites
cfisher

I was able to save a Footer Logo in WHP options; however, none the other settings with a check box work.

Share this post


Link to post
Share on other sites
Andrew

Strange, sorry about these issues... are you getting anything strange? errors or similar? Also, have you checked for a plugin incompatibility?

Share this post


Link to post
Share on other sites
cfisher

No other weird behaviors that I can detect and certainly no errors. I had not considered a plugin compatibility issue. I have not added any plugins recently and my template has always worked fine with my installed plugins. I have a look at my plugins to see if any were recently updated.

Share this post


Link to post
Share on other sites
cmunns

Christopher well if it's not one thing I guess it's something else. Are you still having difficulty saving? I recommend first backing up all your settings and options. Then I would try reverting to that backup so that it resets itself.

Share this post


Link to post
Share on other sites
cfisher

Ya. This has been something else. Thanks for hanging in there with me. I am still having the problems. I will try your backup method. One other thing that came to mind was that I did update to WP 3.0.1. Have you tried WHP with this?

Share this post


Link to post
Share on other sites
cfisher

I tried backing up my settings and then restoring them - didn't work. I then tried restoring the default settings and then restoring my custom settings with no luck. Many, but not all, of the check box settings will still not save. I'm stumped.

Share this post


Link to post
Share on other sites
cfisher

I thought about this a little... this definitely happened when I upgraded to 3.0.9. I recall just before the upgrade I was changing my settings to remove the search bar from the sub-nav and use a search widget because of the problems with IE7 (what this initial support request started with). After the upgrade, I could no longer change many of the settings. This means it could be (1) code problem in 3.0.9 (2) incompatible with Wordpress 3.0.1 (3) database problem (4) possibly (and I'm most skeptical about this one) a plug-in conflict.

Share this post


Link to post
Share on other sites
cfisher

Forgot to mention... I also re-uploaded the theme this morning with no luck.

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

Sign in to follow this  

×