I am assuming that "ShoppingCart.CartIsEmpty" is a string that is reading from a Resources file. Where is such a file?
Thanks.
I'm guess you found that in a .cshtml file but you don't say where you found it or what version of nop you are in.
It's MVC for text I think and prints the contents of ShoppingCart.CartIsEmpty
ShoppingCart being the model and CartIsEmpty being the property on the model
HTH
Dave
Hi daveb,
I did not mention the file I found it because I thought it did not matter much. Either way, I found it in OrderSummary.cshtml
The version of NC I am currently working on is 2.50
You are right. It is MVC code, and it does print the contents of ShoppingCart.CartIsEmpty. However, my question was more related towards "what is @T()?", Why they make this call to return a string? and finally, how/where i can modify that string?
I am assuming the string is coming from a "resource" file? Is this modifiable via the admin section?
@T(..) is just an HTML helper to return a localized string. It returns not just a string but an IHtmlString (eg. an HTML encoded string). see _localizationService.GetResource()
@T(..) is just an HTML helper to return a localized string. It returns not just a string but an IHtmlString (eg. an HTML encoded string). see _localizationService.GetResource()
I have a few headers in my website, like featured products, 1 week offers, deadline till offer ends etc.
I have unfortunately hard coded them into the index page or _twocolumns.cshtml.
Now if I need these translated, can i just use this @T("1 week offers")? Sorry this sounds stupid but I cant seem to see how this can work. I tried adding 1 week offers into the resource string in admin>languages, but its not working obviously.
Would u give me some instructions on how to achieve this pls. Thanks in advance.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.