开发者

Can I create iphone app (IOS) using web's languages ( HTML - CSS - jQuery )?

Can I create i开发者_如何学JAVAphone app (IOS) using web's languages ( HTML - CSS - jQuery ) ? How can I star that ?


There are a number of different approaches you can take.

First, there's creating iPhone WebApps. This approach give you a number of different Mobile Safari APIs that expose internal capabilities through the Safari Browser.

Second, you can create a native application that contains a UIWebView. Other than this detail, the approach would be the same as the first, exclusively using the APIs for Mobile Safari.

Lastly, you can take an approach of using a third-party SDK, like Titanium or PhoneGap. This approach gives you a base set of APIs that you leverage for not only making iPhone webapps, but an app that works on other mobile platforms as well.

Good luck!


For create a Games you can use GameSalad or Stencyl, have own code very simple.

For Utility, use Titanium or PhoneGap using HTMLcode jQuery, jQTouch

Or you can use xcode:

1) create your webApp using you prefer software, during the process you can testing on the iPhoneSimulator simple to drang and drop index file inside the simulator.

2) open Xcode and create a single view application.

3) in the first view of your app by interface builder add a full screen UIWebView.

4) drag and drop the root folder of your webApp in your project and copy a folder:

Can I create iphone app (IOS) using web's languages ( HTML - CSS - jQuery )?

Make sure to creare a Folder and not a Group.

5) implement your ViewController.h:

@interface HTMViewController : UIViewController {

    UIWebView *homePage;
}

@property (nonatomic, strong) IBOutlet UIWebView *homepage;

6) and your ViewController.m

@synthesize homepage;

- (void)viewDidLoad
{
    [super viewDidLoad];
    NSString *htmlFile = [[NSBundle mainBundle] pathForResource:@"index" ofType:@"html" inDirectory:@"MyFolder"];

    NSData *htmlData = [NSData dataWithContentsOfFile:htmlFile];
    [homepage loadData:htmlData MIMEType:@"text/html" textEncodingName:@"UTF-8" baseURL:[NSURL URLWithString:@"index.html"]];
}

7) from interface builder link the web view to a reference, and setting the UI has you want.

Like remove bounce, detect address, phone numbers, link ext.

Now you have integrated your web app in a native project ;)

Hope this help.

pls vote if you think my contribute is good.


Your could use Phonegap. Ars Technica's own iPad app was made with it.


Yes, you can. You would do this by making a webpage, and attaching that webpage to a UIWebView. You will still need Xcode and other iOS developer tools to work the minimal code you need to write. Take a look at developer.apple.com for information on how to get these things and on how to write simple webview code.


Yes it is possible using phonegap and I was searching the internet for the same and found out this

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜