Please read Improving web site performance with Apache .htaccess for an updated version of this article.

.htaccess - gzip and cache your site for faster loading and bandwidth saving is one of the most popular posts on samaxes. It’s basically on how to compress and cache your site content with Apache and .htaccess file.

It works like a charm, but it’s not yet the perfect configuration for me. I wanted something that I can use out-of-the-box without having to rely on external extension modules or tools.

Read more »

With the new year starting, I decided to try some changes here at samaxes.com.

First, I’ve changed the blog theme to a slightly modified Derek Punsalan’s Grid Focus. Some of these modifications were mostly due to some complains about the size of the content column versus the sidebars columns on the previous theme. Since this is mainly a technical blog it makes it easily on the eye to have a wider content column.

Read more »

JBoss announced the GA release of JBoss AS 5.0. JBoss 5 is the next generation of the JBoss Application Server build on top of the new JBoss Microcontainer. The JBoss Microcontainer is a lightweight container for managing POJOs, their deployment, configuration and lifecycle. It is a standalone project that replaces the famous JBoss JMX Microkernel of the 3.x and 4.x JBoss series. The Microcontainer integrates nicely with the JBoss framework for Aspect Oriented Programming, JBoss AOP.…

Read more »

This example was greatly inspired by the Stripes and jQuery AJAX Forms article from Freddy Daoud, but with some nice improvements

Last week I was working on a new Stripes / AJAX example. It involves having a table listing entities, being the last row of the table a form for adding new ones. The form gets submitted via AJAX, using jQuery, and the response is validated in order to check if the HTTP session is still valid.

If everything is OK, the list is refreshed and a success message appears. On the other hand, if validation errors occur, the list is refreshed and an error message appears. Also, if the user’s session has expired on the server, an alert is shown to inform the user that his session is invalid, and the page is reloaded so the user can login once more.

Read more »

There is a lot of momentum around Semantic Web and RDFa. This may be caused by the big milestone reached for RDFa, a Candidate Recommendation of RDFa in XHTML: Syntax and Processing.

Recently, several discussion threads have been started on the WHATWG mailing list around the effort of integrating RDFa into the HTML5 specification as XHTML1.1 and XHTML2 that will have it integrated.

While I was pretty aware of the Microformats activity, I can’t say the same about RDFa. But Manu Sporny makes it a lot easier. In fact, this is by far the most comprehensive explanation of RDFa that I have ever seen.

Read more »

samaxesJS is a set of utilities and controls, written in JavaScript, for building rich interactive web applications. The first extension is a dynamic Table of Contents script. The TOC control dynamically builds a table of contents from the headings in a document and prepends legal-style section numbers to each of the headings: adds numeration in front of all headings, generates an HTML table of contents, degrades gracefully if JavaScript is not available/enabled.…

Read more »

Now that almost everyone has heard about HTML 5, maybe not all of you know what’s new for us developers. Lachlan Hunt and James Graham have presented on 2008-05-29 at @media 2008 in London Getting Your Hands Dirty with HTML5. I really find it a great presentation and a good start if you want to check what’s new with the new HTML/XHTML version. Lachlan Hunt is also the editor of The Web Developer’s Guide to HTML 5.…

Read more »

Please read Improving web site performance with Apache .htaccess for an updated version of this article.

Last week I changed my hosting provider from Site5 to NearlyFreeSpeech.NET. NFSN is a lot more cheaper (I only pay for what I really use).

So in order to speed up my site and save bandwidth (the more I use the more I pay) I use .htaccess file to gzip my text based files and optimize cache HTTP headers. Although this site is powered by Wordpress which has some really great plugins to optimize PHP output I wanted a more generic solution which can be applied to all PHP web applications.

I also try to follow as much as I can the rules for high performance web sites so don’t be surprised if some Expires header seems too long (far future Expires header rule requires at least 172801 seconds).

Read more »