How load a website offline as a iOS app - html

This emulator has a nice feature, when you click in the "share in home screen" option, it works as a app, offline and out of a browser.
https://gameplaycolor.com/app/
I intend make something like it, but I have no idea how can I do. Which technique it website use?
Thanks in advance!

Placing websites on the homescreen is native iOS. As a website, you can extend this, by enabling your website as a 'web app', like you described. For this, you use a number of meta tags in your code. Please see this support document by Apple on how to configure your website so users can save it to their homescreen as a web app.
Moreover, you can specify a startup screen, the color of the statusbar, and some other things.

Related

Desktop site link from mobile site

I am working on a site that has a mobile site: http://www.exchequersolutions.co.uk/m/ I am trying to create a link to the desktop site with out much luck.
When the user clicks on a link I want them to be taken to the desktop site.
The link in the anchor tag is:
<p><a href="http://www.exchequersolutions.co.uk/contractors/cis-self-employed/cis-form/" target="_blank" class="cis_register" >Register Online</a></p>
Does anybody know how or even if this is possible?
Is not possible.
Every browser implement a function to save a link on OS FileSystem (drag&drop or file > save as ...).
You're stuck in a loop caused by user-agent detection.
It looks like there is device detection on the desktop site that uses the user-agent to identify mobile devices. If you follow a link to the desktop site using a mobile phone, you'll just be sent back to the mobile site.
There are a few different ways you can fix this, but it depends on your site architecture. One way would be to disable the redirect on the desktop site if you include a specific parameter in the query string. Another option would be to set a cookie and use that to disable the redirect.

Open Chrome app within Chrome's main window

I'm fairly new to Chrome app development and was wondering if it's possible to run an app within Chrome's main window, like the TweetDeck app.
Thanks!
No. Chrome Apps' current goal is to provide a native-like app experience outside the Chrome browser. Today, with the exception of certain privileged APIs, putting an app in Chrome would be... well, it would be a website.
If you want an app in one of Chrome's tabs, why not just build a website? What does the open web lack for your project?
Note that we have been thinking about what it would mean for an app to be a component inside a webpage. You could imagine a Facebook Like button or a Google+ +1 button implemented as an app in a webpage in the same way that those buttons today are usually implemented as iframes. There are some interesting security properties that this approach would bring over iframes. But again, this doesn't seem to be what you had in mind. What you had in mind appears to be a regular website.

open pdf in iphone webapp

I am trying to open a pdf from my JQM webapp. I have tried iframes/embed/object, and none of those work on an iphone like they do on a desktop browser (scrolling, zooming, etc). I have settled with simply opening the pdf via a link Link. This works fine in the standard browser because the user can simply use the browser back button to navigate back to my app.
The issue that I am having, is that when a user saves the page to thier home screen and opens it using the chromeless safari browser, they no longer have the browser back button. I have tried adding target="_blank" to the link, but apparently JQM hijacks the link and prevents opening in a new page, and I have been unable to get the hacks to work.
I have also tried pdf.js, but I can't seem to even get that to work as my javascript knowledge is fairly limited, and the examples are pretty advanced. The only tutorial that I found used an old version which I couldn't get to work.
Are there any ways to bypass the JQM in openning a link in a new window (which would in turn open in the mobile safari rather than my chromeless web app), or are there any other suggestions for how to open a pdf from a webapp?
Just disable the default jQuery Mobile behaviour, by specifying data-ajax=false.
For example:
Link
See http://jquerymobile.com/demos/1.2.0/docs/pages/page-links.html
For my webApps I used https://docs.google.com/viewer to embed the pdf into my interface.
So, when I navigate the webApp by home screen icon, the app doesn't close when I open the pdf.
I met the same question: open pdf in webapp with html5.
I've tried several solutions: iframe、embed、pdf.js, but none of them is the best solution.
tips: iOS 9.x upper, open pdf with iframe only show the first page of the pdf file, and there will be a <img /> tag in the iframe body when you debug.
util now I still have this troublesome problem, anyone has solution please write your experience here.
Thank you.

Input type Color on Chrome Packaged App

I would like to know how to use input[type=color] on Chrome Packaged App. When I open the HTML file on the browser, the input[type=color] works well, it pop ups the color picker, but when I used it on an app, it doesn't do anything. Please help me how to enable this HTML5 feature.
Are you looking at the app from a mobile device? The web browser for the device might not support input[type=color]. It looks like iOS doesn't at this time. See the compatibility tables.

How do you add a link that will add an event to your iPhone calendar from safari?

This seems like it should be simple but after a couple hours of googling I have not figured it out. I know I can add iCal links using ICS files, but this does not work on the iPhone.
BTW, when I say iPhone I would like it to work on the touch also. Anyone have any luck with this?
You can get iPhone to download the .ics file (using Safari on a mobile web page) by using the webcal protocol:
webcal://website.mobi/mymeeting.ics
As of iOS 5, if you create a simple http link to an .ics file, Mobile Safari will offer to open it up in Calendar.
According to the iPhone documentation there is no URL scheme for the Calendar application. (There are URL schemes for Mail, Phone, Map, YouTube and iTunes.)
Of course there could be something undocumented, but I'm not sure that using it would be a good idea even if you can find it.
Of course it is possible but only if your JavaScript application is installed on the device. Look at http://tetontech.wordpress.com to see how to make calls from JavaScript to Objective-C. You can then use this and the Calendar Store Programming Guide from the documentation in Xcode to do what you want.
It is not possible. Apple does not want you to do this.
Now, what you could do is bookmark a javascript bookmarklet that checks the user-agent of the browser invoking it, and if the user is on Safari on their laptop or desktop Mac, then invoke the iCal using standard method (ICS file).
The user on iPhone could bookmark your page into a home screen bookmark with a useful (and perhaps custom) icon that said "Event" and title of "Meet Mary at 8:15". They could then, when they have synced their bookmarks, be reminded of the event and invoke it on their desktop browser.
Significant barriers here to educating users how to use this system, but it would work if you could convince people to do it, I think.