Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Bug in Search "Alta Vista Style" <%next%> variable

Quote Reply
Bug in Search "Alta Vista Style" <%next%> variable
Hi:

The bug is in any serach page build with more than one page (NOT the Alta Vista style templetes... but ANY serach page built!)

Anyway, whn you get more than one page of results, and get this banner:

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 ... [>>]

Each page SHOULD link to:

http://my.domain.com/cgi-directory/search.cgi?query=the&nh=2 (or whatever nh...)

The actual link build SEEMS to be:

http://my.domain.com/search.cgi?query=the&nh=2

Note that the cgi-directory is NOT in there- it just links to the top domain name... Obviously, the problem is in <%next%> being built.

Sorry to spoil your Holiday Alex, but happy Boxing Day! (You do that in Canada, right?)

dave



Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
Are you sure your paths are set correctly?

I just checked this on the 3 sites I've got running beta 3, and it works fine.

I looked at the sub routine code, and can't see where this error would be happening, unless you are passing in the wrong path to begin with.

PUGDOGŪ
PUGDOGŪ Enterprises, Inc.
FAQ: http://pugdog.com/FAQ


Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
Pugdog:

I thought that, too... but it has nothing to do with how the paths are set (and they are set right, BTW...)

All the other cgi scripts work fine... I mean, even the SEARCH itself works fine, so the paths must be correct.

Please do this search:

http://www.bcdb.com/...mp;d=1&query=the

it is a search for "the", so there are a LOT of responses.

I looked at the code for setting the path, and it seems to be set from the incoming URL...

Oh- IDEA! Could a <BASE HREF="http://www.bcdb.com/"> be messing it up? I will check!

dave

Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
hey All:

Yep- that is it! Don't use: <BASE HREF="http://www.yourdomain.com/"> in your headers or the search paths will be messed up!

happy holidays!

by the way- can I gloat? My wife and I just had our first child- a girl named Victoria Margaux! What a Christmas!

dave

Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
Hey all:

Just to clarify: Do not use <BASE HREF="http://www.yourdomain.com/"> in search.html or search_results.html... maybe you only need to remove it from one, but I did both- works fine now!

dave

Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
Makes sense (it was a path thing!)

If you set a URL base, it screws up the ability of scripts to determine the actual calling URL. If you need to use a base URL, then you would need to make changes to the various functions and 'hard code' in the paths to the various scripts.

It could be done, but since there are tags for just about every path you'd need, why you'd need to use a 'base_url' (except for some legacy habits) is beyond me.

I've coded HTML for the past 8 (?) years without using it ;) After the first year, I found it limited portability, and it was easier to set up the website tree with a good design, then change all the freaking .html files. Then, I found the power of templates.... :)

PUGDOGŪ
PUGDOGŪ Enterprises, Inc.
FAQ: http://pugdog.com/FAQ


Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
gloat.. yes! Congratulations!

http://www.ASciFi.com/ - The Science Fiction Portal
Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
Pugdog:

I started noticing one of my sites (www.cartoon-factory.com) showing up on various search engines under WEIRD aliases... since it is hosted on aros.net, the logical one was www.aros.net/~dkoch, but there were a lot of other, weird ones. So I started with the BASE thing to try and get everyone to the right URL no matter how they got to me. It just held over to the other sites, and generally was not a problem. Except for this.

Oh well, live and learn!

dave

Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
padders:

Thanks! Could not be happier! She is a sweety!

OK, WAY off topic, but you can see her at:

http://www.torikoch.com

First thing I bought her was her own url!

dave

Quote Reply
Re: Bug in Search "Alta Vista Style" <%next%> variable In reply to
hehe last off topic post from me, lovely little site she certainly looks very sweet. Congrats again..

http://www.ASciFi.com/ - The Science Fiction Portal