Hello.
Help me pls, how I can get CGBlog urls without root_url? Cuz output of the {$entry->detail_url} is http://192.168.0.101/2019/09/test.html, but I need only the second part of the url, without a website address or ip, I mean only "/2019/09/test".
CGBlog URL without root_url
Re: CGBlog URL without root_url
Dirty fix, but it will do the trick...
Code: Select all
{$entry->detail_url|replace:'http://192.168.0.101':''}
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Re: CGBlog URL without root_url
Thank yo so much for your try to help me Rolf, but unfortunately I realized that the problem seems to be not the case. No matter if I even clean up the link from root_url and place it to template everytime root url would be added to final link. Damn, I don't underdtand why... 

Re: CGBlog URL without root_url
First question would be: why do you need it?
Second question: is the 'root_url' part really not removed from the link? (check the page's html source, NOT using user browser dev tools)
Further, you may check for the meta tag <base ...> in the head section of your template. Note that it comes by default using the {metadata} tag (https://docs.cmsmadesimple.org/tags/cms ... tadata-tag).
You can use a parameter to prevent the tag from being added automatically though you're then probably working around another problem.
I don't expect you actually will be hosting a blog using an internal ip address as the main 'domain'. So it may be better to configure your test environment to be more representative to production. For example adding a domain - ip address relation in your local hosts file.
Second question: is the 'root_url' part really not removed from the link? (check the page's html source, NOT using user browser dev tools)
Further, you may check for the meta tag <base ...> in the head section of your template. Note that it comes by default using the {metadata} tag (https://docs.cmsmadesimple.org/tags/cms ... tadata-tag).
You can use a parameter to prevent the tag from being added automatically though you're then probably working around another problem.
I don't expect you actually will be hosting a blog using an internal ip address as the main 'domain'. So it may be better to configure your test environment to be more representative to production. For example adding a domain - ip address relation in your local hosts file.