Joomla

Once I decided to move on to Joomla CMS, things started to be bleak. I couldn't find documentation, there were a few annoying bugs, etc.

In the end, though, I got the hang of it. I like it still much better than Typo3, CPGNuke, and all the other CMS systems I have used in the past. Mambo is fast, configurable, and extensible - and once you know how to use it, you start appreciating it real fast!

I love Joomla like I love my favorite sweater: it's old, it's ratty, but it's comfortable and does its job marvelously. Unlike the sweater, it's not easy to replace. Also unlike the sweater, I know how to teach it new things.

When publishing articles, Joomla insists on displaying the date in the format, "day Month year." Nothing wrong with that, but I'd generally want the day of the week, too. And maybe the time in certain categories, like surfing.

It turns out it's relatively easy to change the behavior, as it's something the good people of joomla.org thought about (unlike the behavior of the Prev/Next button, that is hard-coded to follow category with no option to go through all articles chronologically).

Theory: the display of the date chunk is controlled in layout files stored under layouts/joomla/content/info_block. The info block we are interested in, in this case, is created_date.php. If you look at that file (it's very short), you'll notice that the relevant line is:

<?php echo JText::sprintf('COM_CONTENT_CREATED_DATE_ON', JHtml::_('date', $displayData['item']->created, JText::_('DATE_FORMAT_LC3'))); ?>

Read more: Publishing with Dates and Times in Joomla 3.x (and Time Zones, Too)

In the process of writing an article about something that happened to me in the distant past (just over 25 years ago), I needed to put equations into an article. Not very complicated stuff, mind you, just some quantum mechanics. I promise QM is much easier to look at than some other, more elementary stuff that is much more complicated to typeset.

I wondered what the best approach would be. The original equations were typeset in TeX and fairly easy to reproduce in that language. I could do that, generate an image, and use it in the article. But you know me, the enemy of the good enough and focus on things at hand. I started looking at all the different options there were for inline equation typesetting in HTML. And man, there were tons of options!

Long story short, I settled on AsciiMath. It's a really wonderful package, as it not only allows you typeset the equations you want, but also allows you to do so in a very intuitive way, without all the weird syntax you need to use in the other systems.

For instance, the equation I needed to typeset looks like this:

`Psi (vec x, t=0) = cos alpha u_1(vec x) + sin alpha u_2(vec x), 0<alpha<pi/2`

The code for it is simply:

Psi (vec x, t=0) = cos alpha u_1(vec x) + sin alpha u_2(vec x), 0<alpha<pi/2

Read more: Adding Math/Equations to Your Joomla Article

It's been a while now that I've been eyeing the SQLite implementation of Joomla. There have been lots of teasers, so far, but never could I ever click on the "Select Database Type" field and enter, sqlite. Finally, I got sick of waiting on a release and decided to go solo. I would find out who was working on SQLite for Joomla, track them down, offer them encouragement and help, if needed cajole or threaten, and finally get a SQLite implementation that "just works."

Why Joomla and SQLite?

At first, I was hesitant to want that combination. After all, installing Postgres or MySQL is not really a big deal, especially considering that installation of Apache is still orders of magnitude worse. But then I found that I can start a Joomla instance just by invoking the php server process in the Joomla main directory - suddenly life on development servers was much easier.

If you don't know what I mean, here the skinny: you can just unzip the Joomla download into any directory, change into it, and type: php -S localhost:XXXX. XXXX has to be a number above 1024, something like 8000. Then you can simply go to your browser, type in localhost:XXXX (again, same number as before) and you can start installing Joomla. Once you are done installing, you can simply go there again and test and test.

That means that if you had a way to store your database locally, with your Joomla files, you could simply copy the whole tree and have a different instance running. You would go to the copy, change the paths in the configuration file, type in php -S localhost:YYYY and off you go with your new instance.

Can't run MySQL on your web host? Problem solved. Don't want to install a database server just for the occasional glimpse at your files? No problem. Want to see how a change to your site is reflected on your underlying files? There you go!

Read more: SQLite Support in Joomla

Have you ever done that? Created a content item that is of sufficient length that your session expired? You hit "Save," Joomla tells you that you are not authorized to view the resource, and you are left there with a giant blog entry that is gone for good. You think.

 I had that problem several times. Joomla could react a lot better to a session timeout than by making you lose hours of work, wouldn't you think? It's easy enough to fix, too. But we are not going to change the Joomla code right now just to find a fix from this impasse.

What can we do right here and now to save our content? Here is a short howto with a method that might work for you, just as it saved me from a bind several times.

Read more: How Do I Get My Content Back?

I just tried out my old component (written some time in 2005, amazingly): com_weight. It's a weight table written as a component for Joomla, as the PHP version of my programming test in different languages.

It all started with me trying to lose weight in preparation of going to the military, where I knew I was going to be subjected to a strict regime of workout. So I wrote something that kept track of how I was doing, since I really don't care about my weight otherwise.

The first incarnation was in Tcl/Tk. It was a standalone application/script, and it did its job pretty well. To this day, of all the versions it's the one that has the best UI. Later on I wanted a web-ready version and rewrote the script in Perl. At that point, I started realizing that the weight table had great potential as a test of a language and my skills in it, so I rewrote it in Java (ugly as sin) and then as Joomla component. 

Read more: Updated com_weight
Page 1 of 4