You are hereMonthly archive / October 2009

October 2009


My Joomla Essentials

With regards to Joomla essential, much of what you need to do content writing and suchlike is alread built in. Fantastic. And for delivering content to users, either registered or public, is great. However, I have to also use these components to make everything easier:

XMLWriter() for Google Base and Beyond...

I had a whale of a time trying to get some data posted onto Google Base, to enable the shop to sell items from Google Products. Although I am sure that popular e-commerce packages, and probably CMSs, all have uploader modules/components/plugins to do this for you, it is difficult trying to do a bulk export with xml so here is a quickie I wrote to help with getting the correct syntax for Google base using PHP's XMLWriter tool:

<?php
// THIS IS ABSOLUTELY ESSENTIAL - DO NOT FORGET TO SET THIS
@date_default_timezone_set("GMT");

$writer = new XMLWriter();
// Output directly to the user

Sitemaps: Let them know your there!

Sitemaps are a great way for getting search engines to crawl your sites and get every bit of data into their search engines. Obviously the main point behind search engine optimisation is to get your sites listed higher up, or more relevantly on search terms/keywords that you dictate, so letting search engines reach every last recess of your site is vital in achiving this. Currently the three big search engines are Google, Bing/MSN and Yahoo (although Yahoo may well be using search functions of other search engines very soon after its Microsoft takeover).

My Development and Experience sticky icon

I have been making websites for around 8 years now, of varying quality I might add. I have had experience with large custom coded php sites, php frameworks, CakePHP and Code Ignitor, and my current favorites OSCMS (open source content management systems), especially Drupal.

Falsifying Timestamp to give the illusion of historical data

I have been looking at a way of inputting content into drupal but falsifying the timestamp to show it as content created years ago. Currently I am in the process of migrating a number of static sites to drupal and as such have to manually copy and paste some of the content across. This then gives timestamps and revisions as new, despite the data being old (between 1-5 years).

I wrote this as a simple way of changing timestamps, obviously not for general use, but it does hack the nodes to pretend its old data:

<?php

Migration: The first phase.

Migrating from one structure/site to another can be a complex process. I have certainly found within my new role, where I have been migrating 30+ sites to one drupal multisite installation that the process of moving sites is a convuluted one. Not only can it require the migration of databases, but also the procesig of strings to sanitise them ready for implmentation into a new database system and structure, especially when having to split strings.

Joomla - Why are people using it?

Obviously, the question as to why people are using it is one that can be prompted with a number of answers, yet I will put my few points down:

  • The backend/administration is understandable

This can be a big problem, especially when using CMS for no IT professional, which I guess I would class myself as. Joomla has a relatively smooth and easy learning curve to being able to publish articles and create users/emails all fro its backend. Especially in contrast to Drupal which can require slightly more knowledge.

  • It is ready to go straght away

Migration and Validation of Strings

Just been hacking away at this to get the idea across of migrating and validating data from one database into the drupal core. Ite relys on the user having created a content type of news from CCK.


<?php
mysql_connect('localhost', 'user', 'password') or die('Cannot connect to MySql');
mysql_select_db('database') or die('Cannot connect to database');

// get the required data from the database
$sql = 'select * from tableName';
$query = mysql_query($sql);

// give it a timestamp
$unixTimestamp = 1230800640; //starting unix timestamp

@willhallonline

  • Ok, so didn't do anything towards my recording studio today but did put up some shelves 3 days 11 hours ago
  • My recording studio is becoming #ubuntustudio today. Hopefully I can get all of the hardware working. 3 days 19 hours ago
  • doesn't happen with Windows... fixing #ubuntu completed after 1 hour! 4 days 19 hours ago
  • doesn't happen very often... fixing #ubuntu this morning 4 days 21 hours ago
  • #drupal garland theme looks really nice on #firefox in #fedora. Almost shiny! 5 days 19 hours ago