Jump to content

All Variables getting HTML escaped in my module in prestashop 1.7 causing module not work


Recommended Posts

Dear Guys,

All Variables getting HTML escaped in my module in prestashop 1.7 causing module not work.Does anyone know how to fix this issue?

 

Even variables that are not supposed to be HTML escaped are getting escaped and getting printed as text.How do I make prestashop aware about this issue?Please advice

Link to comment
Share on other sites

This is by design. In PrestaShop v1.7, all Smarty variables are automatically escaped, so you no longer need to manually escape them. You can tell Smarty not to escape your variable by adding nofilter like this:

 

{$variable nofilter}

  • Like 5
  • Thanks 2
Link to comment
Share on other sites

  • 8 months later...

This is by design. In PrestaShop v1.7, all Smarty variables are automatically escaped, so you no longer need to manually escape them. You can tell Smarty not to escape your variable by adding nofilter like this:

 

{$variable nofilter}

 

Thank you so much, We were debugging PS 1.7 to the core trying to figure out where it was encoding the XML string that we send to Smarty Fetch.

Odd thing was that it just was happening with DEV MODE ON, LIVE MODE wasn't encoding anything..

 

Anyways, thanks!

Edited by Web VIZO (see edit history)
  • Thanks 1
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...