Forums

My Search Does Not Work Any Ideas (11 posts)

  1. obooty
    Member
    Posted 6 years ago #

    I have all my content on my website but when i enter something to search for nothing comes up no matter what i put in there

  2. moshu
    Member
    Posted 6 years ago #

    Help us to help you :)
    Link? Your host? Theme used? Version? Code used for search...?
    The more details the more chances somebody can help you.

  3. jimgleeson
    Member
    Posted 5 years ago #

    I have this same problem. I am using WordPress 1.5.2 kubrick theme. Here is the thing though, my blog is added to a subdirectory of my main website http://jimzworld.com. My guess is the parameters of the search are somehow causing it to search my main site as well when all I want it to do is contextually search my /wp area.

    I have looked in the "search" and "searchform" templates but there is nothing there to hint as to the cause of this. Any help on this matter would be great.

    The reason I think the search is defaulting to the main site is everytime I do a search it automatically goes to my homepage instead of displaying possible content within my blog.

  4. jimgleeson
    Member
    Posted 5 years ago #

    day 2: still no search.

  5. Evita
    Member
    Posted 5 years ago #

    Post the code of your search form so that we can help you.

  6. RaviionWordpress
    Member
    Posted 5 years ago #

  7. <?php include (TEMPLATEPATH . '/searchform.php'); ?>
  8. This is my search code,
    or all the shit about archive etc is also part of it?
    Nevermind, It works here.. I just modified the basic skin

  • Evita
    Member
    Posted 5 years ago #

    No, we need the code of the searchform.php

  • jimgleeson
    Member
    Posted 5 years ago #

    Thank you for responding to me evita. This is the code for my searchform.php for the default kubrick template using version 1.5.2.

    <form method="get" id="searchform" action="<?php echo $_SERVER['PHP_SELF']; ?>">
    <div><input type="text" value="<?php echo wp_specialchars($s, 1); ?>" name="s" id="s" />
    <input type="submit" id="searchsubmit" value="Search" />
    </div>
    </form>

    Keep in mind the unusual novelty of my situation. My portfolio site is simply the jimzworld.com and my blog is in a subdirectory addition /cgi/wp. Any help on this will be awesome.

  • jimgleeson
    Member
    Posted 5 years ago #

    Ah well, must be the strangeness of my interrogative statement. Many apologies.

  • Evita
    Member
    Posted 5 years ago #

    Try in your searchform:
    action="<?php get_settings('siteurl') ?> instead of action="<?php echo $_SERVER['PHP_SELF']; ?>

    Maybe this will crack your problem.

  • jimgleeson
    Member
    Posted 5 years ago #

    Many apologies for being so long in responding. I did not think anyone was going to answer regarding my issue. The thing is I could see what was going on in that the search form was going up to the main page: http://blogrhythm.com and of course there is nothing but a default page there.

    I added your code into the searchform and being not a complete moron instead of leaving "myurl" blank, I changed it to my url. Many thanks for your help as I knew that was exactly what I needed, I just didn't quite know how to accomplish it.

  • Topic Closed

    This topic has been closed to new replies.

    About this Topic

    Tags

    No tags yet.