Webmastersite.net
Register Log In

Can {CURRENTURL} return SE friendly URL?

Comments on Can {CURRENTURL} return SE friendly URL?

mc19
Forum Regular

Usergroup: Customer
Joined: May 14, 2006

Total Topics: 41
Total Comments: 103
mc19
Can {CURRENTURL} return SE friendly URL?
Posted Sep 14, 2012 - 9:07 AM:

I see that now {CURRENTURL} variable on pages, such as on view-category pages, returns something like

......../index.php?rewritten=1&action=displaycat&catname=cat-name/

and I see the header always outputs something great like.

<link rel="canonical" href="....../nice-mod-rewrite-url.html" />

Can the global Variable, {CURRENTURL} return the actual mod_rewrite URL same as canonical tag?

I want to use the variable for FB likes, twitter and google plus.

Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Sep 14, 2012 - 6:21 PM:

If the likes are of listing details pages, use {LINKDETAILSURL}.
mc19
Forum Regular

Usergroup: Customer
Joined: May 14, 2006

Total Topics: 41
Total Comments: 103
mc19
Posted Sep 15, 2012 - 9:55 AM:

I include something like, [INSERTFILE=simple-social-buttons], into header with {CURRENTURL} as the data URL, it will be great if the output of {CURRENTURL} is mod_rewrite URL.

now i have to use several if else condition to get the nice mod_rewrite url for different pages, but still missing some other pages.

<IF {TID} contains main.tpl>
...
<ELSE>
<IF {TID} contains displaylinks.tpl>
....
<ELSE>
<IF {TID} contains details.tpl>
.....
<ELSE>
......
</IF>
</IF>
</IF>
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Sep 16, 2012 - 6:50 PM:

My research suggests that <?php echo $_SERVER['REQUEST_URI']; ?> may or may not get you the rewritten URL, depending on the server configuration.
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



Sorry, you don't have permission to post posts. Log in, or register if you haven't yet.