Tim Dietrich

Custom Software Developer

Home Services Portfolio Blog About Contact Newsletter

Run Xojo Web Apps on Media Temple's Grid

I've been using Media Temple's "Grid" shared Web hosting service for nearly 4 years now. I've found it to be the most reliable hosting service that I've used in the 20+ years that I've been using shared hosting services. Media Temple is extremely affordable, flexible, and their technical support is both responsive and professional. When it comes to a shared hosting service provider, Media Temple is a fantastic choice.

These days, my development tool of choice is Xojo. I started using it to do iOS development, and then started using it for Web development as well. When deploying my Xojo-based Web apps, I've been building stand alone apps and hosting them on Amazon EC2 servers.

However, last week I got curious about deploying Xojo Web apps as CGIs. I knew the Media Temple provided CGI support through their Grid service, but I had never had a need for it - and I wasn't sure if Xojo's CGI builds would run on it. So I decided to give it a try...

Sure enough, they work like a charm. You can very easily deploy a Xojo-based Web app and host it using Media Temple's Grid service.

Here's what's involved...

First, build your Xojo Web app with the Deployment Type set to CGI, with the Linux target's architecture to "x86 32-bit."

You can upload the build's files to the CGI folder on your Grid server, and run it there without needing to make any additional changes. If you choose to run it there, the path to the app will look something like: http://yourdomain.com/cgi/yourapp.cgi

However, I prefer to upload the apps to individual folders within a domain's "html" folder. This makes it easy to host multiple CGI apps. To use this approach, a few additional steps are required.

When creating a CGI Web app, Xojo creates a ".htaccess" file as part of the build. In order to run the app outside of the CGI folder, you'll need to update the file so that it only includes these two lines:

AddHandler cgi-script .cgi
Options +ExecCGI

Next, create a folder for the app in your domain's "html" folder. Then upload the files that were generated as part of the build. Be sure to upload the ".htaccess" file. (Depending on how your FTP application is configured, that file might be hidden.)

That's all there is to it. The path to your Web app will look something like: http://yourdomain.com/somefolder/yourapp.cgi

Media Temple's Grid service starts at $20 per month for a Personal plan, and $30 per month for a Professional plan. To learn more, visit https://mediatemple.net/webhosting/shared/.

To learn more about Xojo, visit http://xojo.com

Xojo Web apps running on Media Temple's Grid: A great combination!