Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls

404.tpl question

 
Reply
   X-Cart forums > X-Cart 5 > Dev Questions (X-Cart 5)
 
Thread Tools Search this Thread
  #1  
Old 07-06-2014, 07:27 AM
 
Andrew_J Andrew_J is offline
 

Advanced Member
  
Join Date: Jun 2014
Location: USA
Posts: 51
 

Default 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.
__________________
Newb X-Cart 5 user trying out X-cart ver 5.1.3 free, local system is running Linux, web host server is running Debian, mySQL 5.5.32, Perl 5.8.8, PHP 5.3, shared hosting.
Reply With Quote
  #2  
Old 07-07-2014, 02:49 AM
  tony_sologubov's Avatar 
tony_sologubov tony_sologubov is offline
 

X-Cart team
  
Join Date: Jan 2009
Posts: 2,431
 

Default 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.
__________________
Found a bug in X-Cart? Post it to our bug tracker!
Know how to make X-Cart better? Suggest an idea!
Reply With Quote

The following user thanks tony_sologubov for this useful post:
Andrew_J (07-07-2014)
  #3  
Old 07-07-2014, 05:41 AM
 
Andrew_J Andrew_J is offline
 

Advanced Member
  
Join Date: Jun 2014
Location: USA
Posts: 51
 

Default Re: 404.tpl question

Cool! Thank you.
__________________
Newb X-Cart 5 user trying out X-cart ver 5.1.3 free, local system is running Linux, web host server is running Debian, mySQL 5.5.32, Perl 5.8.8, PHP 5.3, shared hosting.
Reply With Quote
Reply
   X-Cart forums > X-Cart 5 > Dev Questions (X-Cart 5)


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 11:55 PM.

   

 
X-Cart forums © 2001-2020