StudioPress Community Forums

StudioPress Community Forums (http://www.studiopress.com/support/index.php)
-   General Discussion (http://www.studiopress.com/support/forumdisplay.php?f=7)
-   -   Move Search Function To Sidebar (http://www.studiopress.com/support/showthread.php?t=10088)

poodyglitz 06-20-2009 09:48 PM

Move Search Function To Sidebar
 
I'd like to take the search form out of the header and put it into the sidebar. It seems that simply moving the code doesn't do the trick. It there some PHP code that has to be altered or something?

Thanks in advance.

CharlesClarkson 06-21-2009 04:42 AM

Re: Move Search Function To Sidebar
 
Quote:

Originally Posted by poodyglitz
I'd like to take the search form out of the header and put it into the sidebar. It seems that simply moving the code doesn't do the trick. It there some PHP code that has to be altered or something?

Delete the search box and add the Search Widget.


HTH,

poodyglitz 06-21-2009 08:57 AM

Re: Move Search Function To Sidebar
 
Thanks, but the "Go" button is just the generic "Search" and doesn't match the style of the theme. How do I make that happen? You can see at:

http://www.oppgen.com

Debra 06-21-2009 09:01 AM

Re: Move Search Function To Sidebar
 
alternatively you could open sidebar.php and do this

Code:

<div id="sidebar">
               
<div class="widget">
<form id="searchform" method="get" action="<?php echo $_SERVER['PHP_SELF']; ?>">
                <input type="text" value="Search this website..." name="s" id="searchbox" onfocus="if (this.value == 'Search this website...') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Search this website...';}" />
                <input type="submit" id="searchbutton" value="GO" /></form>
</div>

        <ul id="sidebarwidgeted">


poodyglitz 06-21-2009 09:37 AM

Re: Move Search Function To Sidebar
 
Thanks, looks like it works.

Now, is there any way to center it and make the text field the same length as the "Sign up" field ? Balance is everything to us anal Art Directors. :)

Debra 06-21-2009 09:54 AM

Re: Move Search Function To Sidebar
 
look in style.css for this

#searchbox {
background: #F7F5EF !important;
width: 250px;<-----change to this
color: #495D5C;

poodyglitz 06-22-2009 11:07 AM

Re: Move Search Function To Sidebar
 
Perfectamundo!

Thanks so much!


All times are GMT -5. The time now is 03:03 AM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.