Hello Harald,
Thanks for share that information here. Can be very interesting for PWA (Progressive Web Apps). I have a question for you... why you use the "AppOptions/HTML/CustomMetaData"? Is not better to use the app's files management? If we add an script... that script is linked properly in the app's index.html file...
Hello Peter,
If the server is controlled by us, then we can submit the data in the format that we wanted, and, then format it again in the server if required (for example, to store in a database). You can use timestamps (maybe better for comparisson purposes?) or any date format. However, with the DateFormat action, we can certanly prepare a date string exactly in the format that we wanted, so, for example, the below code format a string just like you use in the server side:
Note that I use a different format string than what you shown: "yyyy-MM-dd hh:mm:ss": this is because the format string that I use follow the DateFormat action documentation, and this is what we must to do, of course.
In other words, if we try with your suggested format string "yyyy-MM-dd hh:mm:ss", we don't get the desired result. For your desired date format, the format string that we must use is "YYYY-MM-DD HH:mm:ss", just like you can see in the above piece of code.
Hello Harald,
I have no experience with service workers, however, I think we no need to do anything related with Angular, but with the Service Worker API. Are you try with that? Note that this is a more or less "draft" API and may don't work in all the browsers...
Hello Ade,
Many thanks for share this with us!
Please, allow to place here a couple of notes that may can also help:
-
I see you run the AB generated BAT files as an admin, but, in fact, this is not required at all: Cordova and other stuff can work properly even if the user is not an admin. Well. It's not a problem to run the BAT as admin, however, it's not really required.
-
I see you use the Signer tools included by App Builder. Well. In fact, it's completely possible to use these tools to sign the APK files, however, we can use the App options -> Cordova -> Android -> Sign options, in order to do it automatically when we build the APK. *
* We can use the Key Store tool to generate our app's key store file. Once we do that, we can simply use the referred options and then, we no need to use the APK Signer tool nor the APK Zip align tool.
Thanks very much again, Ade! :-)
We can always follow the official documentation of Apache Cordova in order to prepare our system to be ready with Apache Cordova and therefore to can compile APK files from Windows, for example.
Here is the official documentation to be ready with the Android platform in Windows, for example. Once we properly install Apache Cordova, then we can use the integration which DecSoft App Builder provides, in order to compile debug APKs, releases APKs, etc., etc.
Hello Asley,
There is various things to take in consideration here, in my opinion. We can take three different approaches, with their own pros and cons.
1º We can just use a Timer, and do the job when our app is in foreground, that is, when the user is really use our app. You can use app's events like Pause and Resume, in order to stop / start the timer, respectively. Doing this you are very user friendly, since your app works just when the user wanted.
2º You can use a Cordova plugin in order to keep awake the device screen. Doing this your app continue working in foreground, but, force the screen to be on. This approach is less user friendly than before, since the device's battery is drained with the screen.
3º You can use user a Cordova plugin in order to be your app working also in background. This is probably the worst way, since: A) the plugin's author already advise that the stores (Google Store, for example) can reject an app that uses this kind of plugin. If you no need to distribute the app trough the store, maybe you can try with this plugin.
So you need to take care and choose the best approach as possible. Think on it. And, of course, follow the linked plugins, in order to read their documentation, try with their samples, etc. Then post here if you have any specific question. :-)
Hello Asley,
Apparently something changes in the used plugin. The below code, taken from the plugin's documentation, open Whatsapp:
Hello Asley,
Please, take a look at the Launcher sample app.
Hello to all,
Here is a new DecSoft App Builder release, with the below changes, fixes and enhancements:
Read the entire product's history
Hello Harald,
So you try with the below...
And you see it working properly? Also in other iOS versions? If so... there is not a problem to automatically add such piece of code in the app's HTML.
Hello Harald,
I think it's possible to add that into the app's HTML file, however, what about the answer to the StackOverflow question?
FYI, when testing my PWA on localhost with a dummy SSL certificate, Safari won't use the icon when adding to homescreen. Instead it takes a screenshot of the page as the icon. Once the PWA was uploaded to the live server, with full HTTPS, the icon worked fine. Testing on iOS11.3, iPad 6th gen
Maybe the above fix the issue? Or maybe the this other answer too:
TerPro's answer is correct but as a fallback you can put a file named "/apple-touch-icon.png" in the root directory.
OMG... thanks very much to post it here, Harald... may can help to someone in the future!
Hello Harald,
You refer to your sample or to my sample? Take my sample also as a possible workaround... because as I told you before (via E-Mail?) probably it's the CSS that you are using in your sample who can cause the issue. In other words, if you see my sample working, maybe it's because it's quite more simple, but, since it works (at least we don't receive any complain), maybe you can adapt your content to it... that is... using my sample approach... in order to do what you want to do, instead to try to use the other way.
Anyway I want to take a look when possible to your sample in an iOS emulator (it's all what I can do... since I don't have an iOS device right now) and maybe see it with my own eyes give me another idea or something...
Hello Harald,
I want to take a look at the sample when possible. I already send to you another sample, and, want to place it here too, so other interested user can try it in AB if he wanted.
Copy the above XML into a file and save it as "MyApp.ab". Open this file with AB and just run it.
Everybody can read the DecSoft support forum for learning purposes, however only DecSoft customers can post new threads. Purchase one or more licenses of some DecSoft products in order to give this and other benefits.