#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2012
    Posts
    1
    Rep Power
    0

    Website Search Form


    Hi, I'm attempting to code a website and think I might be in a little over my depth!

    I want a main page that is very simple, the main feature being an autocomplete search box that will link to one of many pages, each containing information on a certain subject. I found one on a website but of course can't post the url! So far I've found that it's a jQuery autocomplete box, but I have no idea how to store the pages it searches or how to get the box to search them.

    The rest of the website is html and css within my range, but this search box finding each exact page is essential to the functionality.

    I would very much appreciate any help.

    Is HTML even the right place to be looking or is it a php job?
  2. #2
  3. Code Monkey V. 0.9
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Mar 2005
    Location
    A Land Down Under
    Posts
    2,095
    Rep Power
    1990
    For something like this the jQuery auto-complete box is a very good example of what you want.

    These sort of things often work by sending a request to the server using AJAX to get results from a search script. For something like this you'll need the HTML for the actual page content, the jQuery and other JavaScript work for the auto-complete and AJAX processing and some sort of server-side script to do the actual searching. It is possible to set up the details of each page in a JavaScript variable when the home page is loaded and that will get rid of the AJAX side of things, but that will also mean that there's a lot of extra "useless" information loaded with that page every time.

IMN logo majestic logo threadwatch logo seochat tools logo