Register now for Mobile Web Development for Summer 2010. Class meets at 5:30pm - 9:30pm on Wednesday evenings July 14 - August 18, 2010 in Portland, Oregon.
See the Mobile Web Development curriculum or contact me for details.
My Mobile Web Development course returns to Portland Community College. this summer. Students learn how to build web sites for browsers on all kinds of mobile phones. We focus on standards-based mobile web development, exploring mobile standards and industry best practices. This practical course includes in-class coding and experimentation. Register now at PCC.
Mobile Web Development class details:
See you there!
My two Fall 2009 classes at Portland Community College in Portland, OR are available for registration.
Mobile Web Development is an introductory class for web developers and designers that teaches the basics of creating content for the mobile web. We study design principles, device adaptation, usability, standards and best practices for mobile web development. Students build a device adapted mobile web site as the class project.
Mobile Web Development class details:
Advanced Mobile Web Development is a new class that teaches advanced techniques for creating rich and interactive mobile web sites for smart mobile browsers that support full HTML and Javascript interactivity.
The class targets iPhone, Android, Blackberry, Windows Mobile, Palm Pre and other smartphone models. Topics include interoperability, optimizing markup for advanced micobrowsers, embracing WebKit extensions, JavaScript and AJAX on mobile devices and effective use of device databases. Students build an interactive, device-adapted mobile web site targeting smartphones.
See the advanced lessons of the Mobile Web Development curriculum for details.
Advanced Mobile Web Development class details:
Remember that PCC’s Mobile Web Development class is cancelled for next Wednesday, June 3, 2009. I will be away speaking at JavaOne and attending a family wedding.
The two make-up class dates are confirmed:
The make-up classes will be held in Room 118, Mt Tabor Hall, PCC SE Center from 5:30pm – 9:30pm. This is the usual time and place of our class meetings.
If you can’t make either or both make-up classes, I will provide written lessons as heavily annotated slides and/or blog posts. Check back on this page or the For PCC Students section of the website for the location of these resources.
This post is a quick tutorial about adding support for mobile MIME types in the Apache web server using .htaccess configuration. See this related page for comprehensive list of mobile MIME types for XHTML-MP, WML and binary files.
The Apache web server uses .htaccess files to provide a lightweight method of updating and overriding web server configuration inside a directory. A .htaccess file is an ASCII file containing plaintext configuration directives read by Apache when serving files in the directory. On UNIX servers, .htaccess is a hidden file by default, so be sure to use the shell command ‘ls -la” to view hidden and visible files to check whether a directory contains the file.
Apache extension modules specify configuration directives (or statements) found in .htaccess files. The mod_mime extension defines the AddType directive that manages associating MIME types (or content types) with file extensions.
The AddType directive uses this text format to specify the MIME type and a space-delimited list of associated file extensions:
AddType <MIME type> <file extension> [<file extension>] …
When a HTTP request is made for a file with the configured file extension, Apache serves the content and sends the MIME type as the value of the Content-Type HTTP response header.
Here is an example of using AddType directives .htaccess files to introduce new content types for mobile markup mapped to file extensions. One directive is allowed per line of the configuration file:
# Add Mobile MIME types for xhtml, wml, wbmp and wmls file extensions
AddType application/vnd.wap.xhtml+xml .xhtml
AddType text/vnd.wap.wml .wml
AddType image/vnd.wap.wbmp .wbmp
AddType text/vnd.wap.wmlscript .wmls
A single AddType directive can associate multiple file extensions with the same MIME type. Here is an example that associates xhtml and xhtm file extensions with the application/vnd.wap.xhtml+xml content type:
AddType application/vnd.wap.xhtml+xml .xhtml .xhtm
The configuration in .htaccess files affects the directory in which the file is placed and all subdirectories. But, there is no inheritance for directives in .htaccess configuration. The .htaccess file nearest to the target web document is the configuration file used to serve the document. Make sure to upload your .htaccess file into the appropriate web server location.
There are performance implications when using multiple .htaccess files across a website, especially if a single Apache instance hosts multiple domains. Because configuration is distributed across the file system, Apache must inspect the directory hierachy to determine which .htaccess file applies for a HTTP request. Think carefully when creating multiple .htaccess configuration files and centralize wherever possible.
Also, the .htaccess file must be readable by the UNIX user running the Apache httpd process.