This application is a demo of Cup, the ultimate upload framework for Cappuccino. It provides a fairly complete overview of Cup's features. Currently everything is configured in the xib, so if you are not running on Mac OS X it won't be much help in terms of learning how to configure Cup through code.
There are a few things you will need to do before running the demo:
- Install Cup by following the installation instructions.
- Configure your web server (it must be able to server php) to the cup-demo directory.
- Copy or symlink the Cup framework into the application's Frameworks directory. One easy way to do this:
cd /path/to/cup-demo
capp gen -lf -F Cup .
If you need to change the URL for the upload server, you can do it in Xcode in or AppController.j.
- Open the demo in XcodeCapp (
xcc /path/to/cup-demo
) and open the Xcode project if necessary. - Edit MainMenu.xib.
- Select the Cup object in the object list.
- Select the Identity Inspector.
- Change the value of the "URL" item in User Defined Runtime Attributes to the address of your upload server.
In applicationDidFinishLaunching:
, add this line of code:
[uploader setURL:@"http://host/path/to/upload/handler"];