Searching a web page - how ?

J

John Fitzsimons

Hi,

I want to have a booklist on a single web page (eg 500 books) and be
able to search that list. Showing the results on another page eg. 10
"hits".

Is there any software/scripts that might help me please ? This is
pretty much a "once off" exercise so would prefer a freeware, or at
least reasonably inexpensive, solution.

I know visitors could use "find" but I don't want one by one results.
I also cannot use most languages on the server I hope to use so it
may need to be a java or javascript solution.

I am supplying the booklist so an Amazon link isn't of any use either.
Any suggestions please, anyone ?

Regards, John.
 
D

Dennis M. Marks

John said:
Hi,

I want to have a booklist on a single web page (eg 500 books) and be
able to search that list. Showing the results on another page eg. 10
"hits".

Is there any software/scripts that might help me please ? This is
pretty much a "once off" exercise so would prefer a freeware, or at
least reasonably inexpensive, solution.

I know visitors could use "find" but I don't want one by one results.
I also cannot use most languages on the server I hope to use so it
may need to be a java or javascript solution.

I am supplying the booklist so an Amazon link isn't of any use either.
Any suggestions please, anyone ?

Regards, John.
I would create a javascript array containing all of the titles. This
array could be displayed on the page at startup and later searched
using a "for" loop to find matching titles or partial titles.

On my web site in the Amtrak Reference page I do a search for trains
that stop at a selected station. It might give you an idea of how to do
a search.

I don't think that there would be an easy to directly search the page
rather than an array but maybe someone has a solution.
 
L

Long - CM web hosting

:
: Hi,
:
: I want to have a booklist on a single web page (eg 500 books) and be
: able to search that list. Showing the results on another page eg. 10
: "hits".
:
: Is there any software/scripts that might help me please ? This is
: pretty much a "once off" exercise so would prefer a freeware, or at
: least reasonably inexpensive, solution.
:
: I know visitors could use "find" but I don't want one by one results.
: I also cannot use most languages on the server I hope to use so it
: may need to be a java or javascript solution.
:
: I am supplying the booklist so an Amazon link isn't of any use either.
: Any suggestions please, anyone ?
:
Try and have your page(s) indexed by a search engine, such as google
and use their free site search service.

Long
www.webcharm.ca - content management web hosting
 
H

Hywel

DELETEucwubqf02 said:
Hi,

I want to have a booklist on a single web page (eg 500 books) and be
able to search that list. Showing the results on another page eg. 10
"hits".

Is there any software/scripts that might help me please ? This is
pretty much a "once off" exercise so would prefer a freeware, or at
least reasonably inexpensive, solution.

I know visitors could use "find" but I don't want one by one results.
I also cannot use most languages on the server I hope to use so it
may need to be a java or javascript solution.

I am supplying the booklist so an Amazon link isn't of any use either.
Any suggestions please, anyone ?

Bung it all in to a database. Create your (somewhat large) index page
from that. Use PHP, ASP, PERL, or other CGI technology to search the
database.

If you go down the route of using JavaScript you may end up doubling the
amount of data you send to the client. Looping through the array to
write the data out to the screen may be slow, but could reduce the
amount of data the user needs to download.
 
L

Leslie

Hi,

I want to have a booklist on a single web page (eg 500 books) and be
able to search that list. Showing the results on another page eg. 10
"hits".

Is there any software/scripts that might help me please ? This is
pretty much a "once off" exercise so would prefer a freeware, or at
least reasonably inexpensive, solution.

I know visitors could use "find" but I don't want one by one results.
I also cannot use most languages on the server I hope to use so it
may need to be a java or javascript solution.

I am supplying the booklist so an Amazon link isn't of any use either.
Any suggestions please, anyone ?

Perhaps the free site search service offered by Atomz.com would be
useful. http://www.atomz.com/applications/search/trial.htm

I've had it on my site for quite a long time now. Easy to implement,
results on another page and free.

Leslie
"I refuse to have a battle of wits with an unarmed person."
 
J

John Fitzsimons

I would create a javascript array containing all of the titles.

Thanks, no idea how I would do that but that should help my searching
for an answer.

On my web site in the Amtrak Reference page I do a search for trains
that stop at a selected station. It might give you an idea of how to do
a search.

Okay, that might help if I don't find something "ready made". :)

Regards, John.
 
J

John Fitzsimons

Bung it all in to a database. Create your (somewhat large) index page
from that.

The database is simple. It's the searching, and display, that are
difficult.
Use PHP, ASP, PERL, or other CGI technology to search the
database.

A few problems with that. I don't think any of those are allowed on my
home page. Other than getting a non answer from my ISP I have no idea
how to find out which may/may not work. I also don't know how to code
in those languages.
If you go down the route of using JavaScript you may end up doubling the
amount of data you send to the client. Looping through the array to
write the data out to the screen may be slow, but could reduce the
amount of data the user needs to download.

Okay, but I don't think I have much choice.

Thanks for your input. :)

Regards, John.
 
H

Hywel

DELETEucwubqf02 said:
The database is simple. It's the searching, and display, that are
difficult.

Not really - you can search a database with a simple SQL statement:
SELECT * FROM tblBooks WHERE Title='%mockingbird%'

That will return a recordset that you loop through while creating your
tabular HTML.
 
K

Karl Groves

Hywel said:
DELETEucwubqf02 said:
Not really - you can search a database with a simple SQL statement:
SELECT * FROM tblBooks WHERE Title='%mockingbird%'

That will return a recordset that you loop through while creating your
tabular HTML.

I'd advise the OP to not try programming his own search.
There's a *lot* more to programming effective search than simply looking for
a record match.
What about misspellings? Homophone errors? missing words? (i.e. if they
forgot to enter the word "To" in "To Kill A Mockingbird")

In usability studies, we often ask "What would you do if you can't find what
you're looking for?"
Close to 100% of participants say "I'd go to 'search' for it"
On sites where there is a search function, we ask them to actually go and
search for what they're looking for.
If/ when the search is ineffective, we see that most people will express
frustration or confusion in some way or another.
We then ask "Now what would you do?" Most people then say one of four
things: a) "Leave" b) "Go to Google" c) "Look for site map" d) "Call them"

Don't get me wrong. I fully agree with the need for search. I think all
large sites need to have a search utility. But if the search isn't powerful
and intelligent, it is NOT worth having and is more of a roadblock for the
user than a benefit.

-Karl
 
M

Michael Wilcox

John said:
Wouldn't all "hits" give exactly the same result ? The page with the
booklist.

Ah, then I didn't read the post correctly. In that case, there's better
answers then mine, about databases and such.
 
J

Jeff Thies

The database is simple. It's the searching, and display, that are
I'd advise the OP to not try programming his own search.
There's a *lot* more to programming effective search than simply looking for
a record match.
What about misspellings? Homophone errors? missing words? (i.e. if they
forgot to enter the word "To" in "To Kill A Mockingbird")

I'm inclined to agree with the problems of searching and not getting
results.

You can still improve simple searches though. Splitting the words out of the
search string and then looking for them individually and collectively is a
fairly trivial task and would take care of most problems other than
mispellings.

Unsure of a word, leave it out.

Looks like 4 to 6 lines of your preferred language.

I suppose you could add spelling alternatives, it's not that hard. 40 some
lines and a dictionary list.

Jeff
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top