Gossamer Forum
Home : Products : Links 2.0 : Discussions :

Problem with New, Cool, Ratings

Quote Reply
Problem with New, Cool, Ratings
I've been searching around here trying to find a solution, but no luck. I think the problem is a set-up problem because I have two domains on one account, i.e, 2nd domain using script is in a subdirectory of 1st domain, using cgi-bin in 1st domain. Everything seems to be working fine except New, Cool, and Ratings links. For example, even though the link shows in the status bar to be going to domain2/New, when clicked, it actually goes to domain1/New. If I physically add the trailing slash in the URL, it works fine, going to domain2 as expected. But for some reason, I can't get the script to add the trailing slash correctly to domain2 URL. I've tried both including and not including the trailing slash (as instructed) in links.cfg file and both give the same (wrong) results. Any ideas? here's how it's setup:

# Paths and URL's to Important Stuff
# --------------------------------------------------------
# PATH and URL of Admin CGI directory. No Trailing Slash.
$db_script_path = "/dom1/cgi-bin/links/admin";
$db_dir_url = "http://dom1.com/cgi-bin/links/admin";

# URL of User CGI directory. No Trailing Slash.
$db_cgi_url = "http://dom1.com/cgi-bin/links";

# PATH and URL of Pages to be built. No Trailing Slash.
$build_root_path = "/dom1/dom2";
$build_root_url = "http://dom2.com";

# PATH and URL of What's New page. No Trailing slash.
$build_new_path = "/dom1/dom2/New";
$build_new_url = "http://dom2.com/New";

# PATH and URL of What's Cool page. No Trailing slash.
$build_cool_path = "/dom1/dom2/Cool";
$build_cool_url = "http://dom2.com/Cool";

# PATH and URL of What's Rating page. No Trailing slash.
$build_ratings_path = "/dom1/dom2/Ratings";
$build_ratings_url = "http://dom2.com/Ratings";
Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Include the COMPLETE absolute path in the PATH variables, not just partial absolute path.

Hope this helps.

Regards,



------------------
Eliot Lee
Anthro TECH,L.L.C
http://www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------





Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Thanks Eliot,

OK, I have the complete absolute path, and everything seems to work fine except these 3 pages, New, Cool, and Ratings .

To be more specific, when I go to the "New" link, here's what shows in the status bar:
http://freecomputerwallpaper.com/New
which is I believe what it should be. (This domain resides in a subdirectory of the primary domain 12c4.com)

However, when I click on it, the link sends me to:
http://www.12c4.com/New/ which doesn't exist.
For some reason, it is reverting to the primary domain (which also contains cgi-bin).

Adding to the confusion (for me anyway), if I physically copy the link: http://freecomputerwallpaper.com/New and type in the trailing slash -- so that it looks like this: http://freecomputerwallpaper.com/New/ then it works fine and stays in the freecomputerwallpaper.com (or secondary) domain. I thought the browser (IE5) would just add that slash and go on, but there's something I can't find that takes it back to the primary (12c4.com) domain.
Quote Reply
Re: Problem with New, Cool, Ratings In reply to
The problem is in your TEMPLATE files. How are you linking these pages in them (like home.html or category.html)?????????????

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
http://www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------





Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Thanks for your speedy assistance Eliot.

If I understand your question correctly, they are linked like this:

<a class="menulink" href="<%build_root_url%>">Home</a> | (This works fine, but with the added subdirectories, below, does not)

<a class="menulink" href="<%build_root_url%>/New">What's New</a> |
<a class="menulink" href="<%build_root_url%>/Cool">What's Cool</a> |
<a class="menulink" href="<%build_root_url%>/Ratings">Top Rated</a> |
Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Try this for the heck of it...

Define the following tags in your global variables:

Code:
build_cool_url => $build_cool_url,
build_new_url => $build_new_url,
build_ratings_url => $build_ratings_url,

in your site_html_templates.pl file.

Then replace the following codes:

Code:
<a class="menulink" href="<%build_root_url%>/New">What's New</a> |
<a class="menulink" href="<%build_root_url%>/Cool">What's Cool</a> |
<a class="menulink" href="<%build_root_url%>/Ratings">Top Rated</a> |

with the following:

Code:
<a class="menulink" href="<%build_new_url%>">What's New</a> |
<a class="menulink" href="<%build_cool_url%>">What's Cool</a> |
<a class="menulink" href="<%build_ratings_url%>">Top Rated</a> |

I don't know if this will do anything or not.

It may also be a problem with your sub-domain configurations. Check with your hosting company or ISP.

BTW: You wouldn't happen to be hosting your pages with Web2010, would you?? They have screwed up my sub-domains so many times, I am about to switch companies.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------







[This message has been edited by Eliot (edited January 20, 2000).]
Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Eliot,
Good idea; I thought that would take care of it. However, I couldn't get it to work on 1st pass. I'll study the idea some more when I get a few minutes. Otherwise, I'll check with my host about setting up subdomains for Links. Thanks again for all your help. Ken

Oh, almost forgot, no I'm not with Web2010.
Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Well...that is a good thing...I have about had it with that company. They have screwed up my sub-domain settings twice in the past two weeks. Since they do not allow wildcards, I cannot use my own cgi scripts to set-up my own re-directions to other sub-domains.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
http://www.anthrotech.com
Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
----------------------





Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Nope. I have given all the solutions I have.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
* Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
* Search Forums!
* Say NO to Duplicate Threads. :)
----------------------








Quote Reply
Re: Problem with New, Cool, Ratings In reply to
OK, I've finally gotten to the root of this problem. Here it is from my host:

"If your domain is an IRM (Internal Redirection/Mapping), i.e. MainDomain.com/ExtraDomain/ it will not work without the trailing slash. You will have to contact the author of your cgi script to find out why the script doesn't work with a trailing slash (which is, BTW, the proper way to link to a directory)."

Now, what can I do with the script to get this to work properly? I've tried physically including the trailing slash in links.cfg file, but that doesn't work and the slash is not included in the build. Any other ideas/fixes would be greatly appreciated.

Thanks, Ken
Quote Reply
Re: Problem with New, Cool, Ratings In reply to
Thanks Eliot.

Anyone else have any ideas? I've searched through lots and lots of threads, not finding anything on this problem. I can't believe this is the first time this has ever come up. Anyone else running Links in a subdirectory domain?

Ken
Quote Reply
Re: Problem with New, Cool, Ratings In reply to
As I said before I am running LINKS in a sub-directory and as I mentioned before check to make sure that you are using the correct COMPLETE ABSOLUTE PATHS and VIRTUAL PATHS in your configuration variables.

Again, like I mentioned before, try contacting your hosting company...it may be a problem on their end.

Regards,

------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
* Be sure to visit the Resource Center for FAQ's, Modifications and Extra Goodies!!
* Search Forums!
* Say NO to Duplicate Threads. :)
----------------------