0

I'm developing a webapp that is going to be downloaded and has to work offline (opening locally on a browser).

But most users that are going to use it aren't tech savvy, so I can't have a folder with a index.html or a .exe pointing to open the index.html.

I was thinking if it's possible to have an file.exe that contains all the files inside it and creates a temporary folder from which to access the file?

Thanks, sorry if it's not a very tech question moderators.

dult.np
  • 67
  • 10

1 Answers1

1

General answer:

Yeah java basicially has a pretty sweet solution but you end up with a .jar that again no one knows what to do with if it does not start by double clicking it. However in your scenario i would try to produce a jar that you can localy double click and does everything you want it to do.

This faar youre still plattform independent.

Then check out Software like InstallAnywhere to produce a suitable Installer. People know they just have to click next a couple of times and say yes to any disclaimer.

Your final Installer will then be plattform dependent so you have Installers for Windows, MacOS and so on.

Update 2: Thanks again for your even more detailed reply. In case there is no serverside logic and no database required but only static html pages with a bit of JavaScript in it youre fine by wrapping those files with InstalAnywhere or any other software that creates installers. It will basicialy just tell the user "is it ok to store my files there?" and then create a nice icon to open your index.html in the systems standard browser ;)

Update: Update 2: This is not what you want ;)

Thanks for your reply. In this case i dont see any other possibility but:

1.) Build your webapplication in the appropriate package format of the language youre using (In Java this would be a .war file).

2.) You probably will have to write small helper programms to built into the InstallAnywhere (or any other software to create installers) those could be things like:

- A small helper (could just be a .sql file) to create your database with all the tables and stuff. 

- A small helper running a maven, ant or any other tool that can deploy your packed webapp to a local webserver 

- A small helper setting required environment variables (like JAVA_HOME in case of Java or stuff). 

=> Basicially anything that you configure in your local development environment.

3.) Create a Installer that installs the database and runns your sql to create the tables, priviledges, roles and stuff, maybe already initialize certain tables with data. Then install/ configure the Webserver to finally tell the Installer to run your small helper that deploys your packed webapp to the local webserver.

Once all those things are done a final step is to create a Icon that on double clicks opens the systems default browser and starts your localhost hosted webapplication.

I know this is not more specific than it was before but it gives you an idear on what you need on a target host to run a webapplication localy there.

Update Installer:

Unfortunately i built my last installer like 5 years ago with InstallAnywhere. As faar as i can remember InstallAnywhere is not freeware but provides probably the best functionality. However since you dont need much stuff this is what id do next:

  • Search for "Free InstallAnywhere alternative" , "best installanywhere..." and so on. Maybe your lucky and get something good from that.

This is because even if you dont need that much logic (its literaly unpacking your pages, js scripts, css and so on) the above mentioned programms will handle some operating system specific stuff and provide your end user with a acceptable (mostly customizable) look and feel.

Since functionally you dont need much more than this:

  • a zip, rar or any other package to pack your pages, scripts and stuff (you create that for your own)

  • someone to unzip/ unrar etc. Above mentioned package to a user choosem destination

  • A exe, link, shortcut that triggers the underlying OS to open the standardbrowser and open your indey.html

you could as well write your own installer. But that would be my last pick.

JBA
  • 2,769
  • 5
  • 24
  • 40
  • It's a special request from the client. It won't use php, just html, css and js. It will be mostly to present information, video and audio on a web page, with the possibility to download the file. We could also use power point, but the client want some 'razzle dazzle'. Probably the best solution would be to actually apply that 'install anywhere' to the index.html and its files. – dult.np Oct 28 '13 at 16:29
  • Oh yeah in case of static or js triggered dynamic content youre all good by wrapping your files with a software that creates a installer and tell it to make a good looking icon which basicially just starts the systems prefered browser and call your index.html ;) – JBA Oct 28 '13 at 16:44
  • Any suggestion on the app to make that installer? – dult.np Oct 28 '13 at 17:40
  • I appended some inputs to the installer. When im home in about 2, 3h i quickly check out if i can provide you with more product specifivlc input – JBA Oct 28 '13 at 18:21
  • Sorry writing on my smartphone... "smart" in this case means a 1x4cm textfield. So please excuse my beven worse grammar – JBA Oct 28 '13 at 18:23
  • No problem, Thanks for the replies. I can now solve this problem. Generally I search alternatives for apps on http://alternativeto.net/ though it doesn't have installAnywhere. Thank you again. – dult.np Oct 29 '13 at 12:25
  • Hi sorry i had no time to check this out yesterday evening, you may consider this as useful too: http://stackoverflow.com/questions/759855/what-are-good-installanywhere-replacements-for-installing-a-java-ee-application its about installers for java-ee applications but the requirements listed in that post should fit your needs as well. Good luck! :) – JBA Oct 29 '13 at 13:01