WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Blix - Move Search to Sidebar (5 posts)

  1. madtripper
    Member
    Posted 8 years ago #

    I'm pretty swift with basic HTML and CSS, but all this PHP business has my feathers pretty ruffled. I figured I'd just find the "search" form code and cut and paste it from the Blix header to the sidebar but that didn't do anything except remove my search field completely.

    So I have two questions:

    1. How can I move the Blix search area from the header to the sidebar, and
    2. If I really want to get the lowdown on creating and modifying themes (um, understanding all the php code), and I have a solid HTML and CSS knowledge, where should I go? I didn't have much luck in the wiki.

    Thanks in advance,
    MT

    If you need to look at what I'm doing, it's at girltrip dot org - it kind of looks like the search is in the sidebar already but it's not - the entire sidebar has a white bg.

  2. madtripper
    Member
    Posted 8 years ago #

    Hi,

    I don't know if this question is too rookie to answer or if it doesn't make sense... but I thought I'd try again.

    Right now my search is embedded in a navigation div and it's showing up in my header with the HOME and ABOUT links. I would like to move the search area from the header to the sidebar. I've been working on this on and off for a few days. Any help would be greatly appreciated.

    My blog is at girltrip.org

    From header.php:

    <!-- navigation ................................. -->
    <div id="navigation">
    <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="get">
    <fieldset>
    <input value="<?php echo wp_specialchars($s, 1); ?>" name="s" id="s" />
    <input type="submit" value="Go!" id="searchbutton" name="searchbutton" />
    </fieldset>
    </form>

  3. carnold
    Member
    Posted 8 years ago #

    Hey, i use the blix theme too and moved the search to a left sidebar. what i did was took
    <div id="navigation">
    <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="get">
    <fieldset>
    <input value="<?php echo wp_specialchars($s, 1); ?>" name="s" id="s" />
    <input type="submit" value="Go!" id="searchbutton" name="searchbutton" />
    </fieldset>
    </form>
    and moved the entire code to where you want it. The only problem i have, is the search div (navigation) has already been used (therefore it generates a validation error). It works, just does not validate.

  4. madtripper
    Member
    Posted 8 years ago #

    Thanks! That worked perfectly... and I even managed to fix the validation. Here's how:

    1. In spring_flavour.css copy the code below /* navigation
    and paste it below itself, then on the section that you pasted in, change "navigation" to whatever you want. I added an "sb" for sidebar, making it sbnavigation.

    2. Do the same thing in layout.css.

    3. Lastly, go to sidebar.php and change the div id to match the new one you've created.

    It will pass validation. Thanks carnold :)

  5. carnold
    Member
    Posted 8 years ago #

    Yep, that worked! Thak you or the validation!!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags