Gossamer Forum
Home : Products : Links 2.0 : Discussions :

I think I found a bug in links 2.0

Quote Reply
I think I found a bug in links 2.0
Hello Everyone.

After the pages get built in Links the home page and all of the directory pages get built with links to www.mydomain.com/whatever.

When the top rated whats cool and whats new pages get built they have links that go to mydomain.com the www is gone. Is there a fix for this? Or did I actually find a bug?
Quote Reply
Re: [bytor] I think I found a bug in links 2.0 In reply to
This isn't a bug - it can be fixed my modifying the templates in /cgi-bin/admin/templates. Just add the 'www' to the beginning of the links that point to the Cool, New, and Top Rated pages.

-digitalsea
http://www.digital-sea.com/
Quote Reply
Re: [digitalsea] I think I found a bug in links 2.0 In reply to
You don't need to change the templates, the url is set in links.cfg, in this line:

# PATH and URL of Pages to be built. No Trailing Slash.
$build_root_path = "/alex/links/pages";
$build_root_url = "http://localhost/links/pages";


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] I think I found a bug in links 2.0 In reply to
The funny thing is that is how it is set up in the links.cfg. That was the first place I looked! I thought I made a mistake and did not add the www. but I did.

Weird
Quote Reply
Re: [bytor] I think I found a bug in links 2.0 In reply to
That is weird...Crazy

Links takes the url (from the above post) and adds the new, etc to the end, like so:

# PATH and URL of What's New page. No Trailing slash.
$build_new_path = "$build_root_path/New";
$build_new_url = "$build_root_url/New";

Then in the template, this is used to call the url:

<a class="menulink" href="<%build_root_url%>/New">What's New</a>

Hmm, you could change the templates to be like so:

<a class="menulink" href="<%build_new_url%>">What's New</a>

I have mine set so that the site nav is in a template by itself, called by using <%site_nav%>. That way, if I change something, I just change one template, not all of them.


Leonard
aka PerlFlunkie