PHP

  • user warning: Unknown column 'weight' in 'order clause' query: SELECT iid FROM image_attach WHERE nid = 2 ORDER BY weight in /var/www/vhosts/johnpeace.org/httpdocs/sites/all/modules/image/contrib/image_attach/image_attach.module on line 359.
  • user warning: Unknown column 'weight' in 'order clause' query: SELECT iid FROM image_attach WHERE nid = 1 ORDER BY weight in /var/www/vhosts/johnpeace.org/httpdocs/sites/all/modules/image/contrib/image_attach/image_attach.module on line 359.

similar_text()

I found a new function! PHP's similar_text().

It takes two strings as arguments and returns an integer representing the number of characters they have in common, very simple...but very useful.

I am using it for a project where I have Joomla articles in a database that need to be updated according to values that are found in XML files. Each article in Joomla's jos_content table has a corresponding XML file on a server somewhere, there is one master XML file that contains a collection of nodes for the collection of XML files that I'm working with, along with tags and attributes that allow me to identify them.

So, how do I match the article title in my jos_content table to the XML file I'm going to use to update it's article's contents?

Contract Web Programming

PHP/MySQL Development

With 10 years experience in web development, I'm a helpful addition to your web project development team.

My whole web career has been based on the simple assumption that 'I can do that'. I'm a natural learner, voracious reader and competent software developer. I love taking on new problems and using current technologies to find useful, high-value solutions.

Tools I have the most experience with include:

Web Development Services

Site Redesigns

It's 2009, virtually everyone has a website and has had one for years. Many of those sites are lacking in functionality, difficult to use or simply outdated.