StudioKW - StudioKW.com PDF Print E-mail
Tuesday, 07 February 2012 23:41

Simple is beautiful and that is exactly what we have done with this design. Built on the powerful wordpress platform this website is not only beautiful but is very easy to maintain for our photographer friend. Leaving them more time to focus on the important things; creating incredible works of art.

Last Updated on Wednesday, 08 February 2012 00:25
 
Deleting Multiple Database Tables – The Easy Way PDF Print E-mail
Saturday, 24 September 2011 14:47

sql

In this short article I will describe how I went about deleting multiple database tables quickly without using the DROP DATABASE dbName statement. Feel free to skip right to the solution if you like.

Background Story

As part of changing one of our sites over to a new server I had to delete the existing Joomla database and import the sites actual database, which was exported as a mysql dump. Easy right? All you need to do is drop the database and create a new database. But I did not have permission to do this. In fact, I had very little knowledge of the environment and how it was initially set up, I was called to help get the site back online again.

At this point it was obvious that I would need to use DROP TABLE tableName statements, but since joomla has quite a few tables and its extensions also have their own table. There were about 102 tables in total. Doing this manually seemed insane (we programmers do not like hard work :) ). So the first thought that jumped to mind was, I know, I will write a program to do this. But wait, what about input for that program? Well, there is a command to list all the tables in mysql SHOW TABLES which will list all the tables in the currently selected database. Great, so now all I have to do is to parse the data, maybe add it to a list, python's comma seperated list syntax should do. Finally, as I was manually going over the output I got from the show tables command, changing it to be an list in python, it hit me. Why do I need to do all this work to begin with? There is a much better way.

 

Last Updated on Sunday, 25 September 2011 15:32
 
Getting Reliable z-index Cross-Browser PDF Print E-mail
Saturday, 20 August 2011 16:07
JavaScript

Turns out it is not as easy as one might think to get the correct z-index of an element using a javascript call like $(element).css(‘z-index’). The problem is how browser vendors apply the z-index to an element. But, no worries I have created a jsfiddle page to demonstrate the problem and more details on how it works will follow below.

Last Updated on Monday, 14 May 2012 10:38
 
Automatic Downloader in Python PDF Print E-mail
Tuesday, 17 May 2011 22:36

This article will walk you through creating a python script to download all files on a web-page as fast as possible. The same script can then be used to download all sorts of content on the web, especially when combining the code with a web crawler.

Fig 1. Automatic Downloader output on Windows 7

Last Updated on Tuesday, 16 August 2011 22:49
 
Asian Cabana - asiancabana.com PDF Print E-mail
Saturday, 05 March 2011 14:15

Asian Cabana Website Screen ShotA friend of mine owns and runs a store in Winnipeg under the name: "Asian Cabana". He asked me if I could build a website for his store to help him attract more customers. After meeting with him to discuss it further, I accepted and immediately started working on it. It went live yesterday with still some polishing left to do, but is very stable and useful already.

Last Updated on Sunday, 20 March 2011 12:31
 
«StartPrev123NextEnd»

Page 1 of 3
 

Random Art Work