Joomla! 1.5 Beginner’s Guide

Filed under: Books, Joomla, Programming — Eike @ April 28, 2010 9:41 pm

I do have a love-hate-relationship with Joomla. I hate it because of its glacial pace of development, because I think it falls short as a framework and because of the quite simplistic ways it organizes content. I love it because slow development means you have a stable platform and because the easy-to-use admin interface allows even not too technical minded people to set up and maintain their own website without getting a computer science degree first. And I will always have a soft spot for Joomla! because this is the CMS that got my little business started.

Joomla! 1.5 Beginner’s Guide by Eric Tiggeler [1] is the book that will get you started with Joomla.

To make the best use of the book you should have some prior knowledge – namely, you should be aware that on the internet there are server- and client side processes, that there are such a things as “databases” to store your content in and languages like HTML and CSS to structure and display your text. You will not actually need to know all this stuff to make your website work (the book sees to that) but it will sure help you appreciate what the CMS does for you.

A Content Management System, Tiggeler writes, is like a coffee machine – you press a button and “the machine invisibly fetches all the ingredients […] to serve a cup of fresh coffee, latte, frapuccino or decaf”. Unfortunately, the analogy doesn’t end here. Every coffee machine is made of different parts and control elements which, while they more or less do the same thing, are labeled differently with every brand of machine. In fact I found that learning brand specific idiosyncrasies is the biggest hurdle you have to clear when learning a new CMS.

This is where the Joomla! Beginner’s guide comes in handy: It introduces new terminology step by step and in the order in which you will need it – no back and forth between different chapters necessary. And while each section introduces new terms and concepts on a need-to-know basis for the task at hand, by the end of the book you will have a pretty complete picture of what you can do with Joomla.

Each of the twelve chapters (covering topics from installation via content editing, template customization etc to search engine optimization) is divided into small, tutorial-like sections. Every section defines a discrete task (e.g. “add an article”, “edit the css file” ), provides (under the headline “Time for action”) a set of instructions on how to accomplish the task and explains afterwards “what just happened”, i.e., why things work the way they do. To round everything off, there is a summary at the end of each chapter and a quiz to test your newly acquired knowledge.

The book also exemplifies the proper perspective towards web site building: This is not about the technology, fancy as it may be. This is also not about you, the developer. This is about the people who visit your site, so you have to make the site usable (Chapters 5 to 8, content and menu organization), engaging (Chapter 9, “Enabling User to contribute and interact”) , attractive (Chapter 11, “Working with templates”) and, of course, easy to find (Chapter 12, “Attracting search engine traffic”).

The Joomla! Beginners Guide succeeds, not only because it is well-structured and comprehensive, but also because of its clear and simple language – Eric Tiggeler largely avoids metaphors and analogies which might be helpful to the English and Americans, but tend to confuse matters for non-native speakers (in fact, my own style is much more convoluted than Eric Tiggeler’s, so if you’ve made it this far in the review you will have no problems understanding the book). There is also some humor – the example site you are working on throughout the book is for the fictitious SRUP, the “Society for the Re-appreciation of Ugly Pictures” and I couldn’t help but smile when a screenshot announced an upcoming Bob Ross exhibition.

Of course, I have to do some nitpicking: I don’t know if it makes sense to introduce Content Management Systems as the next big thing when powerful Open Source CMS have been around for the better part of the last decade; I certainly do not agree that Joomla has “powerful multi-level site organization capabilities” (two does not qualify as “multi” , or powerful) and as a somewhat seasoned developer I’m silently gnashing my teeth when somebody suggest that CSS is actually quite easy. But then the book is a little like the IPCC Climate Report in that you really don’t want to dismiss lots of valuable information just because there’s something wrong with one or two inconsequential paragraphs.

You will not need the book if have already done a few sites with Joomla! and felt comfortable with the CMS. It does not contain any super-secret stuff , you will find all of the information on the Joomla! documentation pages or by asking in the Joomla! community forum.

But the Joomla! Beginners Guide is an excellent book if you have never worked with Joomla, or tried to build a site and got frustrated with the intricacies of the backend, or else, if you looking for a resource to train your in-house staff. And while most of your questions will be answered in the forum, this is the book that will give you an idea what to ask for.

I can’t directly compare it to similar books (having outgrown the need for Joomla Beginners books for some time) but I can still say that, specific software aside, the Joomla! Beginners Guide could very well serve as a benchmark for other writers; this is how introductory material should be written.

  1. Joomla! 1.5 Beginner’s Guide
    Paperback : 380 pages [ 235mm x 191mm ]
    Release Date : March 2010
    ISBN : 1847199909
    ISBN 13 : 978-1-847199-90-4

I still ain’t dead, swineflu edition

Filed under: Joomla, Miscellaneous, Programming — Eike @ October 18, 2009 9:09 pm

Being ill [1] means that while you have time do do some bits of housekeeping (like updating your blog) you are not actually capable of doing so. After I had finished both the website for a local cinema and the Centrum Judaicum I spent most part of the last week caring for the girlfriend, contracting the girlfriend’s flu and being cared for by the girlfriend. There are much worse ways to spend a week.

I sometimes wonder if there is a switch in every MS Windows version to make it obsolete as soon as a new version is out. After the last update I cannot send e-mails anymore. Apparently the error code means that some firewall is blocking outgoing mails, although I have no idea why now or why at all or how to fix this. Since I have already checked that Outlook is  allowed to communicate through the firewall (it is) I will now check if it is still illegal to hit Microsoft employees with a mallet (probably yes, I’m afraid) because their stuff is seriously getting on my nerves (and I used to like Windows quite a lot in pre-Vista (and pre-Ribbon as far as Office is concerned) times). I will eventually buy Windows 7, but it feels a lot like throwing good money after bad.

What else have I done  these days? For one thing I’ve started playing with the symfony framework. This is a much different thing than Joomla or Drupal, both of which claim to be “frameworks” as well and provide APIs to write extensions or are extensible by backend configuration. Symfony introduced me to a mode of PHP developement that is new to me – generating applications on the command line [2]. I’m not yet sure what to think of it – it has a steep learning curve [3] and requires much more control over the server than I usually have (many of my clients are on cheap shared hosting accounts) and a rather recent version of PHP (which, again, is not always available on shared hosting accounts). On the other hand it looks like it could be a timesaver if you actually get fluent in symfony developement.

And finally for today let’s have a bit of advertising. Yesterday some friends of mine launched Trabayo, a new job exchange platform. The main difference to other such platforms is, of course, that I actually know and like some of the people behind this. If you want to learn something a bit more substantiall about Trabayo you can read their ‘philosophy‘ or visit the main site (all german).

Enough for today. A number of people have sent enhancements and fixes for the mod_placehere module ( I assume you are here for the module), and I hope that I will finally have a chance to integrate this into the ‘official’ distribution. No promises  this time, but I’ll do my best.

  1. Okay, so it's common cold, not swine flu. But still.
  2. Which keeps crashing. If anybody know how I get rid of the "CLI does not respond" messages please tell me.
  3. Which is actually a flat learning curve. If the x-axis measures time and y-axis measures progress, that is.

Jusos.de – new and improved

Filed under: Programming, Projects — Eike @ April 24, 2009 1:13 am

The “Jusos” (while Jusos stands for “Junge Sozialistinnen” -  “Young Socialists” most Jusos are actually not-quite-so-young Social Democrats) are the youth organization of Germanys Social Democratic Party. Freelancing for Panorama 3000 I did the frontend development for the new version of their website.

Working on a pretty tight schedule we decided to publish the nearly feature-complete version of the page and to straighten out the remaining kinks (mostly accessibilty issues and some invalid HTML) in the background, but I’m already quite pleased with the result (but I would be, wouldn’t I).

We switched the backend from Typo [1] to Drupal , which is less clunky and does not require anybody  to learn an otherwise useless scripting language [2]. Clientside scripting was used rather parsimoniously – a flickr badge, pulling a JSON feed from the associated blog, some accordion type of thing – but even so I was glad for Jquerys helpful selector engine.

But the best thing about it (since money can provide only that much motivation) is that, despite all the pressure and everything, it was fun – that was such a brilliant team working on this project (you would be amazed how much ingenuity it takes to make a website look as simple as  this) and lots of wit and laughter and too much, too often asian food at lunchtime.

Oh well then. Tomorrow I’ll take a day off and go motorbiking – I feel I deserve it.

  1. as far as I can work out Typos only advantage is that it satisfies the german penchant for overengineered solutions
  2. though naturally Drupal comes with its' own set of issues

Timezone bugfix, new template

Filed under: Joomla, Programming — Eike @ February 20, 2009 1:26 pm

Version 1.2.1 of the placehere module did not work for some people – it would not show new articles. That’s because I had introduced a stupid error in the sql query that messed with the timezone settings. This is fixed in the latest version.

Also I added a template called “beez with article parameters”. That’s a tableless template that ignores the paramaters from the module settings pane (pdf+mail icons etc) and uses those from the article manager or from the article itself. Please note  that the included templates are more or less suggestions, with basic HTML you can build you own (leave the stuff inside the php tags alone and change the surrounding HTML). If youve done something clever with a template I’ll be happy to include it in the ‘official’ release of the module.

I also changed the default values for some module parameters to more sensible values.

If you have a previous version of the module installed it will be enough to overwrite the files to update (better yet delete the old files and upload the new ones).

Click here to go to the download page

    Sony Music is online

    Filed under: Programming, Projects — Eike @ February 5, 2009 1:56 pm

    In 2008 I did two large frontend jobs: as a freelancer for Neue Digitale/Razorfish GmbH I worked on the website for the german branch of the McDonalds-Franchise.  And working for Panorama 3000 I did the  frontend programming  for the new website for Sony Music (Germany), which was launched today.

    I have to say I’ much more proud of the Sony site; while it’s in many respects less sophisticated than the McDonalds site my own responsibilites were far greater – I was actually the man in charge as far as frontend developement was concerned, and I was allowed to make decisions about the markup  at my own discretion and leave it to the people at Sony to integrate my stuff with their CMS.

    Even so, and even with a somewhat generous budget, there were compromises, things that didn’t work as planned, or that I could have done better, or stuff that was added somewhat as an afterthought (and as of now there are some minor glitches  resulting from the transition from staging server to live server). And there were delays – while we were working Sony Music was heavily reorganised (when we started it was still Sony-BMG), so we launched a couple of months later than planned.

    But the nice thing is that in the end everybody was happy. The project manager at Sony Music is happy, my employers at Panorama 3000 are happy, and that much happiness makes me a happy show-off man myself.

      Forcing a link target on module links

      Filed under: Javascript, Programming — Eike @ November 10, 2008 10:49 pm

      In the comments Mark asked for a way to open link from the module in a new window. Since others might be interested I make this a blog post, but since I’m lazy I’ll make the post about the most simple way to do this.

      Well, the easiest way is to set a target for the links, and the easist way to achieve that would be, as far as the place here module is concerned, to go to the modules/mod_placehere/tmpl directory, open the template(s) in an editor and hardcode the target into the code. For the readmore link this would look like this:

      <a target=”_blank” href=”<?php echo $article->readmore_link; ?>” class=”readon<?php echo $params->get( ‘pageclass_sfx’ ); ?>”>

      The bit right after the anchor – target=”_blank” – forces a new window or a new tab, depending on browser and browser configuration.

      This method has some drawbacks, two of which I will adress here: One, it does not work with the module for Joomla 1.0.x (which does not use templates) and b) it means you code will not validate, since target is not a valid attribute in XHTML. We will cheat a bit and hide the target attribute from the validator by setting the target with Javascript.

      This could be done with a script that looks like this:

      <script type=”text/javascript”>

      links = document.getElementById(’leftcolumn’).getElementsByTagName(’a');
      for(i=0;i<links.length;i++) {
      links[i].target = “_blank”;
      }

      </script>

      which you would have to place at the bottom of your page. But what does this actually do?

      To understand these few lines it helps to understand concepts like “DOM”, “chaining” and “iteration”.

      DOM is the “Document Object Model”. In the olden days a HTML document used to be a long list of characters, a.k.a a string. If you wanted to find a specified segment in the document the browser had to search through the whole string (which was a mix of the HTML formatting and the content), a cumbersome and not particularly efficient process. Modern Browsers have a different way – they represent a document as a collection of parent- and child elements (where every child can be in turn a parent to other childs). This allows for more efficient methods, like getElementById() which targets an element with a unique CSS Id, or getElementsByTagName, which collects all Elements of a given type. Methods like this can be chained.

      Functions (which in some contexts might be called “methods”) have usually a return value that can be assigned to a variable. If you do something like

      <script type=”text/javascript”>
      function test() {
      return “this is a test”;
      }

      toast = test();
      </script>

      the variable toast will hold the return value of the function test (i.e. “this is a test”). This is only useful when you plan to use the return value somewhere in your function script; on the other hand assining a value to a variable takes work both from you and the browser, and you don’t want to waste the work if you do not need the variable later on. In comes the concept of chaining, which allows you to skip one (or multiple) assignments, because, instead of writing

      <script type=”text/javascript”>

      temp = document.getElementById(’leftcolumn’);

      links = temp.getElementsByTagName(’a');

      </script>

      you can chain these method together with the dot notation like this:

      <script type=”text/javascript”>

      links = document.getElementById(’leftcolumn’).getElementsByTagName(’a');

      </script>

      This will pick the element with the CSS Id of “leftcolumn” from your HTML document and search it for all links elements with the type of “a(nchor)”. The result will be stored in the variable “links”.

      “links” will now hold a list with all links in leftcolumn (also called an array). It will be a list even when there is only one link, since getElementsByTagName always returns a list. To assign a new property (like a target) to every element in this list you need to move from entry to entry, a process that’s called iteration. The easiest way to iterate through a list is a for-loop.

      <script type=”text/javascript”>

      for(i=0;i<links.length;i++) {
      links[i].target = “_blank”;
      }

      </script>

      First you will notice a bit with the dot notation. However this is not method chaining; “length” is a “property” of the variable links that refers to the number of entries in the list (you can tell easily tell the difference between a method call and a property, since a method call has brackets, or parenthesis or whatever the correct word is “()” ).

      The list has an internal counter that start with “0″ (this is a convention, it doesn’t have to make sense, even if it seems more intuitive to most people to start a list with 1). So the first entry of the list is links[0], the second is links[1] etc.

      We do not know in advance how long our list is, but we can easily find out by accessing its length property. So we have our loop:

      <script type=”text/javascript”>

      for(i=0;i<links.length;i++) { }

      </script>

      which means to the browser: starting with zero; as long as the counter is smaller as the length of the list; increment (add one to) the counter; do whatever you are told to do inside the curly brackets (the counter needs to be smaller than the list length since the list starts with 0; if the length is ten the the last list element ist links[9]).

      So there we are again with our complete script:

      <script type=”text/javascript”>

      links = document.getElementById(’leftcolumn’).getElementsByTagName(’a');
      for(i=0;i<links.length;i++) {
      links[i].target = “_blank”;
      }

      </script>

      This sets the target property for every item of the list (i.e. it creates a target attribute on every link).

      I said you would have to place the script at the bottom of your template. This is because the script cannot successfully execute before the element with the ID of ‘leftcolumn’ exists in the page. If you want to use in in another place, or in an external script file (best way) you can use the onload event handler.

      Events are mostly responses to user interaction (click, mouseover, mouseenter etc). An event handler allows you to assign a response to an event.

      A page load is also an event. It is executed when the page and the related assets (images, script files etc) are fully loaded, making sure that every element you script needs already exists. So you could place the following in the head of your template file:

      <script type=”text/javascript”>

      window.onload = function() {
      var links = document.getElementById(’leftcolumn’).getElementsByTagName(’a');
      for(i=0;i<links.length;i++) {
      links[i].target = “_blank”;
      }
      }
      </script>

      Onload is is a method of the window object (Document Object Model, you remember?). There are some other elements with a onload event (images for example), but mostly this is used on the window itself. For the load event we define a so called “anonymus function” (which is called anonymus because it does not have a name. Duh).

      So the above script works on every Joomla template where there is an element with the ID of leftcolumn that contains one or more links. Naturally this works with other ids to.

      Of course most joomla templates now include the mootools javascript library which means that you could rewrite the above as

      <script type=”text/javascript”>

      window.addEvent(’load’, function() {
      $$(’#leftcolumn a’).setProperty(’target’,'_blank’);
      })
      </script>

      which is an altogether more reliable and elegant way of doing things, but you wouldn’t have learned anything that way.

        Are inline elements supposed to have a line height and other miscellania

        Filed under: Javascript, Miscellaneous, Programming — Eike @ August 25, 2008 12:01 am

        I’m currently swamped with work and don’t have much time for blogging. But for those of my visitors who do their own HTML and Javascript I thought I share some programming problems I had in the last two days and their solution where I found one.  It might be that these are things should be clear from reading the relevant standards, but I have to admit that I find the standards for HTML and Javascript hard to read and even harder to understand; my usual tactic is to look how others are doing it and follow the majority.

        (more…)

          Class suffix, ordering, version number

          Filed under: Joomla, Programming — Tags: — Eike @ August 14, 2008 11:33 pm

          The module came with a bug in its template files, so the Module Class Suffix parameter was applied to the individual content items and not to the module. This is fixed now. So the module will have the class of mod_placehere, plus whatever you enter as a suffix; ‘leading’ items – the articles that span the full width even when the content is sent in columns – will have the class mod_placehere_leading; all others items will have the class of mod_placehere_following.

          I added a new ordering parameter “exact”, which will display articles in the exact order you enter the ids. This can be set only in the primary ordering (since the ordering can not possibly get more exact than the exact order. Or something).

          And finally I added a readme-file that will hold a changelog and a version number. Since this is the first time I use a version number I simply put version 1.0 in there, despite the fact that the module has been around for quite a while. I will stick to the usual scheme of x.x.x – major.minor.bugfix.

            New Joomla Project

            Filed under: Joomla, Programming, Projects — Eike @ June 28, 2008 8:29 pm

            In my last post I mentioned that I used the place here module for a new project – this is now online under www.freicon.de.

            Freicon (short for Freiburg Consulting) is one of the leading european suppliers for dealership management systems. We already did the last incarnation of the website running a patched version of Mambo. The new version is built with Joomla 1.5.3. I looted the Beez-Template for the parts responsible for HTML Output, but decided to use some much simpler CSS. The menus are done with ImgTTFMenu. The place here module (actually multiple instances of the modue) is in the grey box on the right and links to the respective categorys instead to individual articles.

            I did the programming work as a subcontractor for the Berlin-based agency dynamique (actually a company I co-founded a couple of years ago before I left; by now their main business is with hosted solutions for the Zimbra groupware), design was provided by smile-werbung.de in Freiburg.

              New Parameters for mod_placehere

              Filed under: Joomla, Programming, Uncategorized — Tags: , — Eike @ June 26, 2008 9:11 pm

              I finally had a chance to use the place here module in one of my projects – I think this is actually the first time I used this (or it’s predecessor mod_contentitem) on one if my sites (I wrote this originally as a reply to a request in the Joomla Forum). My customer required a bit of extra functionality for the module which might be of use to somebody else, so it becomes part of the ‘official’ distribution. I will briefly introduce the new parameters, but since the module is by now quite complicated I will start asap with a bit of documentation.

              Trim text

              Like the name says this will trim down the text to the specified number of characters (so this expects a number as input, alphanumeric input will cause errors). This is a simple substring operation, so it might cut the last word in ha

              Not found title, Not found text

              If the id you entered in the id field at the top of the parameters does not return an article this title and text will be displayed instead.

              Use Meta Description

              If this is set to “yes” the module will use the text from the articles’ meta description instead of the intro text (if there is no meta description the intro text will be used as a fallback). The meta description is the short text you enter in the article manager (last entry in the parameter tab) that is supposed to be used by search engines.

              Link to Category

              If this is set to “yes” the readmore-Links in the module will not point to the single article, but to the blog layout page for the category to which the article belongs. This will only work properly if there is a link to the blog layout page somewhere in a menu (set up a hidden menu if necessary).

              Run plugins

              This is not new, but has caused a bit of confusion so I mention it here: Usually all plugins that run on the main content would run on the module content as well. This regularly wreaked havoc on page layouts when comment areas where appended to module contents etc, so I disabled plugins by default for the module. If you need to run plugins you need to set “run plugins” to “run plugins” (could I possibly be any clearer? I think not).

              Like it? Get it from the download page for the place here module for Joomla 1.5.x

                Older Posts »