Creating a project like:
I should have the ability to view the project within Wappler in a browser like:
Creating a project like:
I should have the ability to view the project within Wappler in a browser like:
Hey Ben,
How and when would that be helpful? Previewing the HTML files directly from the file system is never recommended. Some components and data won’t be loaded this way. Also it won’t be possible to preview PHP / ASP pages.
Also - you already have a real browser (chromium) preview directly in Design View
Good (early) morning @Teodor,
I am in the process of creating a tutorial for absolute newbies, where a site has been created and saved on the desktop. This person has no knowledge of web servers, let alone PHP / ASP. Yet, this person does want to see what they have created. The browser within Wappler does not allow linking to other pages without a web server.
I will show all in the video when done.
I still don’t think that’s a great idea. I can see many users confused by opening files like that, scripts not working etc. and all of this because the site is simply supposed to run on a server. That’s why we force the users to create a target with a server when using the preview in browser option.
If anyone really really needs to run an HTML file from the file system, they can just browse to the project folder (open in file explorer option) and double click the HTML file.
Just an example:
We’ve already had that user (here in the community) who didn’t have much experience and he was trying to run his website from the file system from an USB stick and was trying to use the json data source component.
Chrome security policy wasn’t loading the json data because of the way the page was loaded in the browser and (of course) immediately that was considered Wappler fault
I wasn’t really able to explain him that’s not Wappler fault.
I’ll take that on board, Teodor. I’ll change the script in the tutorial to explain that. Good point.
(Perhaps you could delete this post, or hide it from view.)
By the way in the next update of Wappler we will always run a local server for serving the Wappler project.
So then just going to http://localhost:12345
will give you your current project in Wappler, even if you are on local.
That is most useful for mobile projects as they don’t have a server, but also indeed for static html only projects that run solely app connect for their dynamic data and fetching data through json files or api calls.
I built a one-page site for someone (completely static, no code whatsoever) so viewing this as Ben suggested would have been helpful. I actually just opened it directly by entering the path manually but having a button in Wappler to do this would have been helpful. Not vital, just helpful.
Well the preview options are getting better and better
Making a current tutorial is getting harder and harder
Two votes and two days later, my wish has been granted. The Gods are with me.
Sorry, this is an expression, the term is not supposed to reflect on the Wappler team. Although I must admit seeing miracles coming out of Enschede.
@George Does this built-in server work for static html stuff? Or can it be used with a server model too?
It is solely an HTTP server.
Hi Ben, now i need you to wish about socket.io implementation
Yes indeed the Wappler built-in server is just a http server that also acts as a transparant proxy to your local/remote web server if you have any defined.