Gossamer Forum
Quote Reply
Modification to the d=
Hello,

I'm trying to do something weird with GLinks but I really need this.
So here what is my situation. I have city review directory, a while ago I enhanced it to handle more than one city by using 'd' parameter (if user choses city1 d is set d=city1, if choses city2 d=city2...). So far so good, till this moment everything was fine until i have spotted some loose in search engines rank and this is because some links are viewable from different urls and marked as duplicate content.

If I have wrote 3 reviews in businesses in 3 different cities when user want to see all my reviews and goes on review search all urls of links looks like:
www.domain.com/cgi-bin/page.cgi?g=Detailed/1234.html;d=city1
www.domain.com/cgi-bin/page.cgi?g=Detailed/1235.html;d=city1
www.domain.com/cgi-bin/page.cgi?g=Detailed/1236.html;d=city1

And the wished one is:

www.domain.com/cgi-bin/page.cgi?g=Detailed/1234.html;d=city1
www.domain.com/cgi-bin/page.cgi?g=Detailed/1235.html;d=city2
www.domain.com/cgi-bin/page.cgi?g=Detailed/1236.html;d=city3

And this comes a problem because all links are in different cities, I have looked in the code but cannot figure which of two functions - clean_output and transform url does the actual transformation of urls from static to dynamic.

Which one of those two I must use and how to rewrite 'd' parameter to be set for each link city?

p.s. Sorry for my bad English.

Cheers,
Boris

Facebook, Twitter and Google+ Auth for GLinks and GCommunity | reCAPTCHA for GLinks | Free GLinks Plugins
Quote Reply
Re: [eupos] Modification to the d= In reply to
Hi,

Can you not use something other than d=xx ?

Remember, d=1 in page.cgi makes the scripts run dynamically (and thus change all the URL's to dynamic ones).

Wouldn't something like this work?

www.domain.com/cgi-bin/page.cgi?g=Detailed/1234.html;d=1;c=city1
www.domain.com/cgi-bin/page.cgi?g=Detailed/1235.html;d=1;c=city2
www.domain.com/cgi-bin/page.cgi?g=Detailed/1236.html;d=1;c=city3

Hope that helps.

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] Modification to the d= In reply to
In first it was like this, but because the script runs always in dynamic was easier to use 'd', so it will never be undef. And even if I use let's say c= for city paramter it will be dynamically preserved so the problem will persist :(

Cheers,
Boris

Facebook, Twitter and Google+ Auth for GLinks and GCommunity | reCAPTCHA for GLinks | Free GLinks Plugins
Quote Reply
Re: [eupos] Modification to the d= In reply to
Hi,

Have you maybe tried editing dynamic_preserve in Setup > Build Options ?

Our one looks like this:

Code:
t,d,s

..but you could do:

Code:
t,d,s,c

.. and that should work for what you need, right?

Hope that helps

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] Modification to the d= In reply to
Nope :(
it was setup like this with proper dynamic preserved which leads again to my situation :(
c is dynamically preserved and i do not have control over it how to apear in rendered page :\

And even if link 1235 is in city 2 in page url to this link is presented:
www.domain.com/cgi-bin/page.cgi?g=Detailed/1235.html;d=city1

Cheers,
Boris

Facebook, Twitter and Google+ Auth for GLinks and GCommunity | reCAPTCHA for GLinks | Free GLinks Plugins
Quote Reply
Re: [eupos] Modification to the d= In reply to
Hm, just cleared in my mind how this works all is happens in trnasform_url so i have to hook on it ans somehow to rewrite c or d or b or whatever to value of <%City%>, but this is the tricky part as far i can see transform_url has no access to template vars it uses, just page_id, url, query string and separator as values :\

Cheers,
Boris

Facebook, Twitter and Google+ Auth for GLinks and GCommunity | reCAPTCHA for GLinks | Free GLinks Plugins
Quote Reply
Re: [eupos] Modification to the d= In reply to
Hi,

Sorry, afraid I'm stumped now :(

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] Modification to the d= In reply to
Yeah me too Crazy

Cheers,
Boris

Facebook, Twitter and Google+ Auth for GLinks and GCommunity | reCAPTCHA for GLinks | Free GLinks Plugins
Quote Reply
Re: [eupos] Modification to the d= In reply to
Ooops Blush

I've got this sorted Cool

Thanks anyway

Cheers,
Boris

Facebook, Twitter and Google+ Auth for GLinks and GCommunity | reCAPTCHA for GLinks | Free GLinks Plugins