iPhone web applications, templates, frameworks? [closed] - iphone

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
Does anyone have any good starting points for me when looking at making web pages/sites/applications specifically for viewing on the iPhone?
I've looked at templates like the one Joe Hewitt has made, and also seen some templates I can purchase, which I haven't done yet.
I figured someone else had already started on this track and decided that I could probably leech on their newfound knowledge :)
So, does anyone have any pointers? I'm well aware of the problem that the more such a template/framework makes a web app look like a native iPhone app, the more likely I'm going to get into trouble because it just isn't, but for now I want a framework I can start building on, and then in the process figure out how to make it distinctive enough to be perceived as a web app as well as looking like a native iPhone application.
Specifically I'm looking for features like:
stylesheets set up, or pointers to how to do them for iPhone
page flipping animation, ie. pick an item in a list, list scrolls out of view to the left and information for item scrolls in from the right
the animation part would have to work with dynamic pages, ie. not just one big page that has divs set up for each sub-item, which at least one such framework had as a sort of quick fix, I would need to have list item picking load the page for that item, and then when loaded, scroll to it
Edit: To avoid people reading only the question and answering, before reading my other reply, I'll add my clarification for GPL licensing and similar issues here.
The framework I need to use can not be distributed under a license which would require me to license my own project out under a similar license. The GPL family of licenses allows for exceptions regarding library usage, but this won't apply to this since by necessity, the kind of framework I would need to use would be all source code.
The project can easily accomodate commercial libraries.
Also, I don't need a library or a framework as such, example files that look good and aren't overly obfuscated would be welcome as well.

I found iphone-universal on Google Code the other day. Haven't had a chance to try it out but it looks promising.

jQtouch looks outstanding.

The iUI library, originally from Joe Hewitt, would be a good place to start. The library is BSD licensed and has no commercial restrictions.
You're right in assuming iphone-universal is not an option for you -- its actually licensed under Affero GPL which triggers the distribution clause simply by accessing the software over a network which is quite different to standard GPL.

I'm currently looking into http://webapp.net.free.fr/. Check out the demo here. Compared to the other frameworks mentioned, it has the following advantages:
Under active development
Active user community
Has an open license, free to distribute as long as you include the copyright/disclaimer
The last point was really the winner for me. I'm looking at building something that will be included in a commercial product, so the other frameworks like iphone-universal and iwebkit (both GPL) weren't options.

QuickConnectiPhone is LGPL so you can use it the way you want. It has a custom Dashcode project that includes the needed files. It is highly modular. It will even let you compile your JavaScript, HTML, and CSS into an installable application if you want.
http://sourceforge.net/projects/quickconnect/
For more information you could look at http://tetontech.wordpress.com

Try iwebkit
http://iwebkit.net
Here is a demo:
http://m.iwebkit.net

This looks good, but unfortunately it's being licensed under GPLv3, so I'm actually a bit afraid to start looking at that code. The framework I either need to find, or develop if needs be, must be able to be used as part of a commercial program, without having to license the entire program different. Commercial libraries are fine, I just haven't found any I can demo yet, presumably because I could just then steal all the code if I wanted to.
Guess I'll look further, thanks for the link though.
Edit: Clarification. I'd be fine with the requirement to share the source to the web framework part for the iPhone, if someone wanted it, but since this framework is all source, I'm afraid that incorporating bits of it into an existing web application (to make a skin for iPhone), I'd be making the whole web application liable for GPL license, which is totally out of the question. Even sharing all the files related to the iPhone pages is out of the question, since they will contain proprietary code.

I've been mucking around with iUI, and find it quite good, but to be honest I haven't looked at the licencing model, so I've no idea what it is. It is very simple and straight forward though, and works well with ASP.NET MVC.

Check out iWebkit 6. It works only on iOS 5, though :(.
UPDATE
You can also use saurik's. It doesn't have all of the features you said you wanted, but I'll try to see how to implement them. Also, you said you wanted to build on it. For a demo (saurik took down the actual good part of cydia.saurik.com) you can use mine on my other site.
To avoid transferring all those images, just add this in the header:
<link rel="stylesheet" type="text/css" href="http://cache.saurik.com/menes/style.css" />
also, add this to your CSS:
body > panel > fieldset > div > a: hover {
background-image: url('menutouched.png')
}
menutouched.png is here:
This function in js slides the page. It is from Joe Hewitt’s iUI project:
function swipePage(fromPage, toPage, backwards)
{
toPage.style.left = “100%”;
toPage.setAttribute(“selected”, “true”);
scrollTo(0, 1);
var percent = 100;
var timer = setInterval(function()
{
percent += animateX;
if (percent <= 0)
{
percent = 0;
fromPage.removeAttribute("selected");
clearInterval(timer);
}
fromPage.style.left = (backwards ? (100-percent) : (percent-100)) + "%";
toPage.style.left = (backwards ? -percent : percent) + "%";
}, animateInterval);
}
For loading the next page, you could try something like executing a window.location with a delay. The timing is up to you though.
You also need to add this to your CSS:
body {
-webkit-tap-highlight-color: rgba(0,0,0,0);
-webkit-user-select: none;
-webkit-text-size-adjust: none;
-webkit-touch-callout: none;
}

Related

How do I build a wiki into an iPhone app?

I want to build an iPhone app that is really a wrapper around a wiki. Specifically, I have some static reference content that can be represented by a hyperlinked set of pages and want to build an app that will provide a nice interface over this content, including search, bookmarking, and annotating. I'm wondering what the best approach is for building something like this.
(I'm spent a fair bit of time googling for answers but pretty much every combination of search terms I can think of returns links to wikis, not links about putting a wiki into an app).
Are there libraries out there for handling wiki content (rendering, navigating links etc.)? I imagine I could just represent my content as a set of local HTML pages and point the web browser control at these but that doesn't seem right. Any ideas on how best to approach this in the iOS world?
Thanks in advance!
Try looking at TWedit, it is a wrapper for the excellent TiddlyWiki which is a single file WIKI built around JavaScript and HTML. TW is very powerful and well supported with many plugins available.

What widget kit / framework is Woopra using?

If you use Woopra, you probably know that several months ago they released a web based analysis tool. I was surprised by how smooth and well designed it was. Taking a look at the source code, it seemed to be coded using GWT. However, its Mac look and feel reminds me of Sproutcore. I'm not aware of a look and feel like it for GWT.
I'm really interested on their widget kit, so I started to look for newcomers in this area, without success.
It's hard for me to believe that they custom coded it completely, as it uses many different widgets, charts and effects and it could be, by itself, a huge undertaking.
Do you know if they are using a custom widget kit / framework and, if so, its name?
Thanks in advance,
Juan
Hey guys, I'm not using any library beside jQuery. The Woopra web application has been built from scratch from the ground up.
I hope this answers your question.
Elie.
woopra.com
If you view the page source through your browser and find a reference to one of the follow files:
a long md5sum for the name and ends in .cache.js or .cache.html
some name that ends with nocache.js or nocache.html
If it has either, you know the site is written using GWT. For example, when looking at the Wave source it references:
<script type="text/javascript" src="/wave/static/1880D9859FBFB1895A16B35680031427.cache.js">
While the web version of Evernote pulls in:
<script type="text/javascript" src='/com.evernote.ENWeb/com.evernote.ENWeb.nocache.js?97654'></script>
Of course, it's possible to rename these files so just because they're missing, doesn't mean it's not written in GWT. Nevertheless, without these files it's a pretty good bet that they're not using GWT.

CMS for plain HTML website [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
Hello I got a website with around 5-6 pages (plain html). There are areas in these pages where I need to update occassionally. Is there any free / opensource CMS to maintain these editable areas of HTML page.
Thanks
Perch is excellent for small sites.
At its very simplest, Perch allows you to replace static content in an HTML file with placeholders. A simple GUI then allows you to edit those placeholder values for individual pages. So, for example, if you have a file containing this chunk of markup:
<h1>My site</h1>
you can change that to:
<h1><?php perch_content('Main heading'); ?></h1>
and you'll then be able to edit 'Main heading' through the GUI. Most CMS apps work in a similar way, but Perch is the first I've come across that does very little else, which is a huge plus for small projects.
I haven't used Perch for a while, and I'm sure they've added some features since I last did, but I'd still recommend you give it a try. It's cheap, too.
I think couchcms is a pretty good open source alternative to the likes of cushycms and perch
I recommend cushy
http://www.cushycms.com/
http://drupal.org/ is very popular. Many people also use Wordpress - http://wordpress.org. Also try googling "simple cms".
The answer will obviously be dependent on the requirements of the software and the capabilities of your server.
You should also check out opensourcecms.com. You can try out various cms's there until you find one you like.
For a five-page website, Drupal is probably overkill; I'd say Wordpress is good enough (just define a page for each page of the website, copy and paste your content, choose a theme, and you're done). (You would want to either use the blogging features of WP to take full advantage of it, though.)
If for some reason you really want to try out Drupal but don't want to invest a lot of time into figuring it out (it does take some ... well, a lot ... of time to figure out right out of the box), and you're not in a big hurry, you can wait a bit until it's possible to try out the new Drupal Gardens hosted CMS system (currently in beta). (You need a beta key to try it. Sign up for the beta on the site and then wait for your key.)
Since your most likely a programmer I would recommend github's very own Jekyll:
Here are some sites powered by it:
https://github.com/mojombo/jekyll/wiki/sites
As a bonus you can use Github to provide you free hosting (your site will be a public repository that only you can edit).
Have you tried using mut8? They have pretty alright features.
http://mut8.me

GWT Lazy Loading

I want to develop a GWT application. The application contains 8 modules and all the modules run in a single page.
I have links for all the 7 options on the top.
When the page loads I want only the home content to be loaded and displayed.
Only when the user clicks the menu options, the menu content should load.
Can anyone suggest the best way to achieve this.
This has been addressed in GWT 2.0... First you'll remove the separate entry points you have for each module - since they're all on the same page, you only need one entry point per page.
Then you can use the GWT.runAsync() method at each point that you feel can be a split... it automatically cuts up the code into chunks that are downloaded as and when necessary.
Look here for the docs.
AFAIK, lazily loaded (or pluggable) modules can't be done in GWT. Partly this is due to the way the GWT compiler works - it likes to import all the code that it is ever going to see and then optimises and prunes it as viciously as possible (to make the resulting JS files as small and lead as possible). If it doesn't have access to all the source code up front, it might make optimisations that will break the pluggable modules (especially since nothing in the "core" application may reference the classes that the lazily-loaded modules need to work properly - the GWT compiler would prune those "unused" classes in the core module).
This stackoverflow question from May 09 asks the same thing and has the same answer - it can't be done.
I searched high and low about six months ago for an answer to this problem, because I really wanted to do what I believe you're asking for. Never found a solution.
(I haven't used GWT 2.0 - it might have addressed the issue)
Thank you for your answer. You are right that the whole Javascript code gets downloaded.
But there must be a way like say on of module is View Profile. Only when the user clicks the view Profile link, the widgets related to displaying my profile needs to be created. is this not possible.

Is there a good iphone sdk documentation site that provides good examples / common usage?

The problem? I look up stuff in the xcode documentation and find very useful lists of objects, methods, etc... But then I still have to go somewhere else to find useful example code of how to use that object. For example, I looked up NSNumber yesterday and found all of the neat stuff it can do, but I still had no clue how to use it. That's just an example. I'm sure I could read the objective c pdf front to back and learn something there (which I plan on doing) but what about later? When I'm looking up some UIKit object? Do I have to go find a tutorial each time (or lately, I just ask StackOverflow and you guys take care of me).
Is there a part of the apple website / xcode documentation that shows the example code I'm looking for?
Is there a wiki site out there or something that has what I'm looking for? (I just tried a simple google search "iphone sdk wiki". this site could be good. iphone sdk wiki . I'll check it out. Anyone else have one they like? )
This is also sort of a mild complaint to Apple. Why not a section on each code definition page that shows usage?
I've found the sample code section on Apple's iPhone Developer Connection be extremely useful not only for samples of complete applications but also a best practices source. Going through the code of The Elements, for example, will expose you to how to use particular classes as well as how to structure your code. It is a wonderful example of how to create a non-trivial iPhone app.
Look in developer.apple.com/iphone they have pretty good documentation (you can use the search bar there) on all the classes and have a lot of good sample code..
I really would emphasize the "Related sample code" section on many, if not most, of the documented classes.
But, IMHO, there isn't any easy way of acquiring the knowledge to develop in Cocoa/Cocoa Touch. The API's are so numerous that it simply takes a lot of time and experience. You just have to work on it, look at a lot of books and study the sample source code where available.
I've tried to take a purposeful approach by carving out some time every week to learning a new API/class irrespective of whether my current project needs it or not.
Alternatively, search Joe Hewitt. He's the developer for iPhone facebook. He has a project you can download that demonstrates all the features of facebook. It's an awesome open source project!
When you look something up in Xcode Developer Documentation, you sometimes get a Related Sample Code: text that tells you what Sample the method or property is used in. Too bad you can't click on it to see the code, but if you do click it takes you to the page to download the sample. – mahboudz 0 secs ago
Apple Developer site has all kinds of code examples. Try searching google for a UICatalog project, it will show you all the basic UI stuff you can do, like adding buttons and progressbars through using only code.