JustJohn Posted January 17, 2023 Share Posted January 17, 2023 (edited) So I have this $product.description inside a template file that contains the text from Product Description field. What would be the right way to work on this variable and produce derivatives? For example, I may want to filter numbers from that field or cut it and produce a new variable like $product.description_filtered. Text operations are easily done in PHP, but how do I actually create this variable so that my .tpl file can see it and display it? Do I need to create a new module? Do I need to use any hooks? What is the easiest and the most correct way to extend a variable? Edited January 17, 2023 by JustJohn (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now