* AH-SID * alizainal.aljufri
{% set id = data.post.url|split('/__xtblog_entry/')|last|split('-')|first %}
{% set url = 'http://your.xtgem.com/p/__xtblog_entry/'~data.post.url|split('?')|first|split('/__xtblog_entry/')|last|replace({(id~'-'):(id~'/')})~'.html?__xtblog_block_id=1' %}

Copy code


The code above is for view == 'entry'

For view == 'entries_list':

Just use the same code, than change data.post.url into entry.url

Than use it in html anchor link: <a href="{{url}}">{{entry.title}}</a>

note:
you can edit your xtblog's url like that but you have to know that url xtblog in rss feed and link canonical can not be changed

That all.
2016-07-18 17:35 · (0)

Online: Guests: 1