X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (X-Cart 5) (https://forum.x-cart.com/forumdisplay.php?f=56)
-   -   404.tpl question (https://forum.x-cart.com/showthread.php?t=69502)

Andrew_J 07-06-2014 07:27 AM

404.tpl question
 
I finally successfully created a new skin. I am playing with the 404 template file.

I see that X-cart has some code "{ t ( # Page not found # ) }" that renders as Page not found. However, you you just place the text Page not found without the brackets, t and hashes, it works too.

You can also put text in between p tags without anything fancy too. So what is the purpose of all the extra stuff?

Thank you for answering my endless questions. :)

tony_sologubov 07-07-2014 02:49 AM

Re: 404.tpl question
 
Hi Andrew!

Thank you for your question!

The structure of {t(#Page not found#)} means that we are passing string "Page not found" to method t() as an argument. t() method is responsible for translation.

So, if you want to allow merchant to translate the 'Page not found' phrase you should use this construction. If you want 'Page not found' phrase to be displayed this way in every language, then you should put it simply like Page not found.

Andrew_J 07-07-2014 05:41 AM

Re: 404.tpl question
 
Cool! Thank you.


All times are GMT -8. The time now is 11:02 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.