Howdy.

I need to make the search box wider See the one in the upper right corner of this very page? It is 140 pixels wide. I need to double that. But I can't find where it is actually set at that width.

Can someone turn on a light for me so I can stop stabbing in the dark for this?

Thanks!

Comments

CmsTT’s picture

Hello, my friend, welcome to Drupal. To solve your problem, perhaps you can try the following. First, I recommend that you download, and install firebug extension if you are using Firefox. You can get that here

http://www.getfirebug.com/

Just, click install firebug for firefox,and restart firefox.

Now, to solve your problem. You'll need only, a few things to solve your problem. Your theme files..especially the "style.css" file. Now, I think ll you need to do, is open your style.css and find the search box class or div values and edit them (when you open the style.css from your themes folder, bring up the search function of what ever text editor you are using and type "search"into the box...this would go through thee style.css file, and locate,the settings for thee search box)

This is how firebug rendered the search box settings on this page.

#search .form-text
border:1px solid #00609D;
margin:0px 5px 0px 0px;
width:137px;

So, as you can notice ll that needs to be changed is the width value,to what ever you want.

I to am a beginner, see if it helps. (If you say the theme you use, I'll try it on my localhost, and give you exact steps)

sohopub’s picture

Sadly I tried that earlier and it didn't work. I also tried it again by C/P your code and still no dice. I have the standard drupal search box being placed into the right side bar. It's control has to be somewhere other than the themes style sheet.

Any other suggestions?

CmsTT’s picture

*Puts on thinking cap* Before,we rule out the style.css can you post the contents of the style.css that have any relevance to the search box. Other than that,I don't know any other place where this setting can be. Your last resort would be to use firebug(if you have firefox) and inspect the search box element, and see where and what are the values. Also, is the site live? If so, send me a link, and,I'll check it out. Also, do you have a custom theme? If not, tell me what theme you use, and I'll check it out. Other thn this,I think someone else,would be of more help to you.

God, bless.

sohopub’s picture

I'm using an edited version of pushbutton.

this is the CSS for the search in my stylesheet. No changes to it seem to effect the drupals search box.

#search .form-text, #search .form-submit {
  border: 1px solid #369;
  font-size: 0.85em;
  margin: 0.2em;
  width:300px;
}
#search .form-text {
  width: 9em;
}
#search .form-submit {
  height: 1.5em;
}
CmsTT’s picture

Ok, I loaded up my localserver,and loaded up Drupal with pushbutton theme. And, I think I found it. It's the "em" value that needs to be changed. THis value to be exact:

#search .form-text {
width: 9em;

You can remove the 300px, I reckon that you put that in, because it's not in the original style sheet. So, you can change the "9em" to something more suitable. Try that see if it works.

God bless.

sohopub’s picture

didn't change a thing.
It's got to be in one of the module files. Just can't pinpoint exactly where

CmsTT’s picture

double post sry.

CmsTT’s picture

That's strange because, as we speak I m watching a widen pushbutton search box. I edited my CSS file and it worked. Modules could be the problem.But the only thing related to the search bar is the core search module, and this is enabled. It, may be silly suggestion, but see if it is enabled, and check the menu settings and see if it's enabled there (silly suggestion I know...) Try that let me know the outcome

God blessings.

sohopub’s picture

Search is enabled.

This is what I want a mock up image >> http://woodpress.net/test/search.jpg

anyone else care to share?

CmsTT’s picture

That sure is strange. I got it to widen with pushbutton theme. If it's customized PLENTY more than the original then, I can't be much of assistance. Perhaps you can take a scan of the pg.tpl.php and see if any thing there can be changed. BTW, did you download firebug for firefox. That would make trouble shooting 1000 times easier.Also, if the site is live, send a link for it. But,again, it worked fine for me with push button.