Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Questions on Links

Quote Reply
Questions on Links
Hi, new to the progam and have some questions.

1. Could anyone let me know please if it is possible to change the separator in the url that Links 3+ uses?

Ie: instead of _ (underscore) change this to a dash? (-)

2. Does anyone have a rewrite to remove the .html extension from all the pages in Links 3?

Thank you!
Quote Reply
Re: [webones] Questions on Links In reply to
Hi,

Quote:
1. Could anyone let me know please if it is possible to change the separator in the url that Links 3+ uses?

AFAIK, you can't. To be honest, I wouldn't recommend it anyway, as Google penalize you for using - instead of _.

Quote:
2. Does anyone have a rewrite to remove the .html extension from all the pages in Links 3?

You would just do it via a global (call it: stripindeexhtml).

Code:
sub {
my $tmp = $_[0];
$tmp =~ s|\Qindex.html||sg;
return $tmp;
}

If doing it in subcategory.html, you would need to call it like:

<%stripindeexhtml($URL)%>

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] Questions on Links In reply to
Hi Andy

Quote:
AFAIK, you can't. To be honest, I wouldn't recommend it anyway, as Google penalize you for using - instead of _.

That's interesting, I was always of the belief that '-' was given a higher rating than an underscore. That's according to some SEO 'experts' I have seen, though I must admit, that was a few years ago now.

Regards,


Clint.
--------------------------
http://AffiliatesDirectory.com
The Affiliate Programs Directory
Quote Reply
Re: [Clint] Questions on Links In reply to
Hi,

I guess its one of those gambles you have to take <G>

Also, its *VERY* hard to convert the _ to - , because its done in the build routines- so would require editing in quite a few places I would imagine. This would give you real headaches when upgrading to newer version of GLinks in the future too =) (I've done it before on one of my own sites - on a LSQL 2.2 version, and that was bad enough :P)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] Questions on Links In reply to
Hi Andy,

Thanks for the code to remove the html from the pages. Still wish there was a way to change the separator though, the _ makes it difficult for end users to get the url's correct, and when you copy and paste in some situations where the _ is blended into a line that has ___________ in it, the url itself of course, will now get "lost", something that doesn't happen with the -. In terms of the Big G, I have heard that it is preferable when building a new site to use the - instead of the _ , but if one has an existing site then it is better to leave the _ in place. I was just hoping there was a way to change for useability purposes. If you know where this is set just so I can take a look to see what would be involved, I'd appreciate the help.

CheersSmile
Quote Reply
Re: [webones] Questions on Links In reply to
Hi,

No problem about the global.

Regarding the build routines, I believe what you would need to edit is in /admin/Links/Build.cgi and /admin/nph-build.cgi - its pretty complex in there though, so again - I wouldn't recommend it Tongue)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!