Welcome to WebmasterWorld Guest from

Forum Moderators: incrediBILL

Message Too Old, No Replies

Can this be done easily?

Updating search form for hundreds of pages



12:03 am on Jul 28, 2004 (gmt 0)

10+ Year Member

On each page of our site we have a drop down menu. Customers can search by product line or brand.

However, we are adding many new brands and many new pages. This is completely unmanagable at this point and I can't (and haven't) keep adding to this list for the hundreds of pages we have.

I'm wondering if there's any way to have something like this:

<select name="worldwide" size="1" onChange="location.href=this.form.worldwide.options[this.form.worldwide.selectedIndex].value">
<option>Search Products
<OPTION VALUE="http://www.domain.com/example1">Example</OPTION>
<OPTION VALUE="http://www.domain.com/example2">Example</OPTION>
<OPTION VALUE="http://www.domain.com/example3">Example</OPTION>

On each page of our site yet not have to manually go to each and every page everytime we add a new "example"? Some sort of redirect or java or something? Please keep in mind that I know ZERO java but maybe can buy a js or...anything?


[edited by: tedster at 12:42 am (utc) on July 28, 2004]
[edit reason] use generic domain name [/edit]


12:06 am on Jul 28, 2004 (gmt 0)

10+ Year Member

I would include the search form in an external file and then use an include on the pages (assuming you can use server side includes). This way you would only need to update that one file in the future.


12:17 am on Jul 28, 2004 (gmt 0)

10+ Year Member

LOL...and this is done how?
Let's pretend I know nothing more than basic html..which I don't. How do I get this done?
Any info is really appreciated.


12:18 am on Jul 28, 2004 (gmt 0)

WebmasterWorld Senior Member encyclo is a WebmasterWorld Top Contributor of All Time 10+ Year Member

It you are trying to manage a site of more than a few pages without either server-side includes at a minimum, it is always going to become unmanageable.

You can do a search on the forum for SSI for examples of how you can include files, but if you are building a 100 page plus site, then you really need to look at using some sort of content management system such as Mambo Server [mamboserver.com], or one of the thousands of others. They use a database for storing the information and a template system which allows you to quickly update the entire site.

Jumper Willow

12:47 am on Jul 28, 2004 (gmt 0)

10+ Year Member

While prodding through your code, I got to a website that might have been referenced in the problem.

The two basic searches are really only links to directory with an index.htm in it. If you are still comfortable with making a new directory and a new index.htm for your new product brands and modify your product categories, then I don't see how adding a line of text in the main site is a burden...

The only way to really make it more managable from what I can tell is to do a complete redesign of the way it's organized. If you are familiar with any SQL databasing, that is what I would suggest, putting all your products into the database with a title, description, cost, a "brand", and a "category." If you are unfamiliar with SQL (as I am honestly not completely familiar with it) you can setup a similar database using some PHP scripting, but in all honesty, it would be alot of inital work. In the end though, adding new products would be trivial at best.


12:48 am on Jul 28, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

And of course, you can always opt for the "other html" solution, which is to name your pages .php, then include html pages where needed for things like the drop-down under discussion. If you don't have server support for SSI, this is an effective way to handle it.

A CMS also makes sense - but maybe not for someone dealing with crunch time. Not being at all familiar with them, I have virtually no idea what the learning-curve might be....


Featured Threads

Hot Threads This Week

Hot Threads This Month