extracting title from current URL
-
darkhoros
-
Topic Author
-
Offline
-
Senior Member
-
Less
More
-
Posts: 77
-
Thank you received: 0
-
-
10 years 11 months ago #1918
by darkhoros
Hi,
I have this setting
the ULR is: /keyword-[^/]
the place holder is
p={path}
s={preg_subject 1,${p}}/keyword-(.*)/i{/preg_subject}
a={urlencode}${s}{/urlencode}
and my title is
${a}
what I am trying to do is extracting the part after keyword- from the URL and use it as my page title, i am using the rule settings from my redj as I think both redj and tagmeta work in the same way, and trying to use same rule to do what I need, but the title of my pages is not changing and keep the default title.
Am I doing some thing wrong, or do I miss the whole point of tagmeta?
Thank you for your help and support.
Regards.
Please Log in or Create an account to join the conversation.
Less
More
-
Posts: 3194
-
Thank you received: 441
-
-
10 years 11 months ago #1920
by admin
No,
you are assuming something wrong. They work the same way, but they do not have the same macros. As example, {urlencode} is just released for you, so is neither available in ReDJ nor Tag Meta. This could be the problem...
Kind regards,
Luigi
Please Log in or Create an account to join the conversation.
-
darkhoros
-
Topic Author
-
Offline
-
Senior Member
-
Less
More
-
Posts: 77
-
Thank you received: 0
-
-
10 years 11 months ago #1921
by darkhoros
Thank you for your kind reply.
Ok, I have removed the {urlencode}
so the setting is
the ULR is: /keyword-[^/]
the place holder is
p={path}
s={preg_subject 1,${p}}/keyword-(.*)/i{/preg_subject}
and my title is
${s}
But no luck, I am unable to extract this part of url to use as page title.
Thank you.
Please Log in or Create an account to join the conversation.
Less
More
-
Posts: 3194
-
Thank you received: 441
-
-
10 years 11 months ago - 10 years 11 months ago #1922
by admin
Mine was an example. Macro {preg_subject} is not supported yet by Tag Meta.It will be in the next release.
Please, check available macros in the rule edit page.
Kind regards,
Luigi
Last edit: 10 years 11 months ago by admin.
Please Log in or Create an account to join the conversation.
-
darkhoros
-
Topic Author
-
Offline
-
Senior Member
-
Less
More
-
Posts: 77
-
Thank you received: 0
-
-
Less
More
-
Posts: 3194
-
Thank you received: 441
-
-
10 years 11 months ago #1925
by admin
You can use just /keyword- and check if the hits counter for the rule raises for each URL request. If not, there's something wrong in the rule.
If hits counter raises, and the page title does not change, I should check the rule in the backend.
Kind regards,
Luigi
Please Log in or Create an account to join the conversation.
Time to create page: 0.165 seconds