givanz / VvvebJs

Drag and drop page builder library written in vanilla javascript without dependencies or build tools.
https://www.vvveb.com/vvvebjs/editor.html
Apache License 2.0
7.28k stars 1.66k forks source link

Looks amazing, but..... #159

Open Marcelo-D opened 4 years ago

Marcelo-D commented 4 years ago

hello!

Works wonderfully at your demo online, but if i use it locally, clicking over editor.html the interface opens, but i cant drag anything around. I mean, it works great at your site, but it doesnt work from a local folder. What i have to do to fix it? Thank you!

givanz commented 4 years ago

Hi

If editor.html is opened directly from filesystem it doesn't work because of recent changes to chrome and firefox iframe security.

The best alternative is to use a web server like xampp/wampp or use apache/nginx directly and open editor.html from the server like http://localhost/vvvebjs/editor.html

For Chrome you can disable it by starting chrome from cmd with

-allow-file-access-from-files — disable-web-security — user-data-dir — disable-features=CrossSiteDocumentBlockingIfIsolating

more info https://medium.com/@siddhartha.ng/disable-cross-origin-on-chrome-for-localhost-c644b131db19

Marcelo-D commented 4 years ago

OIC...i opened editor.html in brackets, started up xampp before, and did a live preview and it works! Thank you! Good luck with this revolutionary project!