Troubles with adding YouTube Videos, Forms, iFrames, etc. to Prestashop 1.6 Pages

Troubles with adding YouTube Videos, Forms, iFrames, etc. to Prestashop 1.6 Pages

Prestashop has an issue with adding YouTube videos to various places where you need it.

We first encountered this issue on our own projects, but it’s also mentioned on the Prestashop forum – so here’s the solution to this trouble:

Comment the following lines in the class Validate (classes/Validate.php) of the method isCleanHtml:

So the method should look as follows:

The admin panel will display it as question, but this is because the editor does not load the object, but it will be ok on the frontend.



6 comments

  1. Oh, you need only to enable iframes in Preferences -> General, there is no need to do this modification.

  2. Oh, you need only to enable iframes in Preferences -> General, there is no need to do this modification.

    Thanks ;)

  3. @Krystian : Thank you !

    @ Denis Urevich : Please update your post with Krystian’s solution. Core files modifications usually disappear while updating…

  4. Hi,
    I’m trying to insert a YouTube video using a built-in code on a CMS page, but when I try to save the code the save button does not work. I’ve already enabled iframe and I’ve already tested everything I’ve been told in other forums.
    I needed help.
    Version prestashop 1.7.
    Thank you.

Post a new comment

top