Windows x64 Access Database Connections

by Dan | 0 comments

I have spent many hours dealing with this on my own so I figured I would write down the solution so I wouldn’t have to research everything again.  If you are running a 64 bit system and need to use *.MDB drivers you need to make sure the following is set:

run: “regsvr32 odbcconf.dll” from c:\windows\Syswow64\

Edit ODBC using: C:\WINDOWS\SysWOW64\odbcad32.exe

That will save you many hours of frustration with x64 systems

Automated CPanel Full Backups

by Dan | Comments Off

cpanel_logoLooks like I finally figured out how to automate cpanel backups.  Since most of my sites are all hosted on the same account backup was a sinch with cpanel full backup.  Only issue was that I could not automate the task until now!

First I setup my own local FTP so I had a remote place to put the files.  Then using the script below edited it put in my cpanel variables and then created a cron job to run the file.  The issue wasn’t finding this script, I have had it for a while, the issue was getting the darn thing to work.  Looks like what I was missing was changing the $skin parameter to ‘lp’…thank you Lunar Pages Forum (yes should have looked there a long time ago but didn’t).  Lunar Pages would be my host and looks like they have their own skin for cpanel.  Once I got that in place everything worked perfectly and then I just scheduled the cron job below.

Here is the script cpanel_backup.php

Then schedule the script job via Cron
0 0 * * 1 /usr/bin/env php cpanel_backup.php

Regular Expressions Find and Replace

by Dan | Comments Off

2009-07-22_085637Dealing with databases and SQL I run across a lot of lists that are usually broken by either excel or line breaks.  Well when you need a quick way to convert that to a single line comma separated list the fastest way to do it is a find and replace on regular expressions.  This can be easily done with Notepad++ or just about any text editor

For example if you had a list like:

1
2
3
4

A find of \r\n and replace with , will give you the output of

1,2,3,4

This can save a whole bunch of time!

Font Tester – See the Difference

by Dan | Comments Off

font-testerThis is probably one of the biggest things that I struggle with when tweaking a CSS file.  What font-family to use and how it will work.  Well finally I ran across a website FontTester that will allow you to choose the font family and see the difference.  This should save a whole bunch of time when creating or editing new sites.

System Automation

by Dan | Comments Off

systemcleanupSo I have decided to resurrect an old laptop that I had sitting in my office for about 2 years.  Well after $40 to quadruple the memory and replacing the hard drive and then re-installing XP from scratch and then all the manufacturer drivers, we finally are in business.  I then plugged this into my network and our LCD TV and the stereo.  So it is our own little home entertainment system for our TV.  Well I decided that since this thing would be on 24/7 that I needed to do some automation to some tasks to keep it clean.  Because Playon and Hulu and other web based tools like to create awesomely large temp files that just hang around if you do not delete them.  Also because it is a WindowsXP machine I figured scheduling a daily reboot wasn’t a bad idea either.  Well turns out these are all very simple things to automate and then schedule.

For CCleaner you just need to run it in the silent mode by creating a schedule that kicks off ‘CCleaner /AUTO’

For JKDefrag you just need to schedule to run the JKDefragCMD file

For a scheduled reboot you just need to schedule a job that kicks off ‘Shutdown.exe -r -t 00′

Lifehacker has a great article on other processes you can automate but these were the first three I went after to keep my computer clean.  I scheduled CCleaner and JKDefrag on my work laptop and it really does keep things clean and moving along a whole lot better!

Firebug – Firefox CSS Analyzer

by Dan | Comments Off

2009-04-03_084118So last night I was bored and decided to redo my entire website (again). I just changed the theme about a week ago, but the more I dug into it the less I liked it and decided I would spend a little more time redoing my blog. After picking a theme I put it on a local copy of Wordpress and started banging away. I started changing header images and fixing CSS issues with AJAX overlaps and image overlaps and fixing up a few other issues I noticed.  This is usually pretty typical for themes I have found in the past.  You get what you paid for and because all these themes are free I guess that would make sense.

One of my co-workers turned me onto Firebug which is a Firefox plugin that reads the CSS and breaks it out into a tree structure so you can see what is really going on behind the scenes with formatting.  This application saved me probably about 2 days of frustration searching through the CSS and the PHP files trying to find the correct classes and div’s to edit to make it look how I want it to.  The program allows you to edit the CSS on the spot so you can see if what you thinking works…this is great for things like spacing or overflow or text size.  This application is a must have for any web developer or anyone who likes to tweak their Wordpress themes to get the most out of them.

CD Drive Gone – Windows XP Fix

by Dan | Comments Off

cd-drive-iconHave you ever had your CD drive disappear from the explorer window and no matter what you did you couldn’t get it back.  Then if you go into Device Manager you notice that it is saying your CD drive has an invalid drive?  Only to search and find there are no specific drivers for you to update?  Well if you have like I recently did download this little zip file and then run the registry file to clean out the issue.  It seems it comes down to a registry hack to fix this issue and it is pretty common in Windows XP.  I am not a fan of running registry files and adding them but this one did exactly what I needed it to do.

CD Gone Registry Fix

Email Linkage Quick Reference

by Dan | 2 Comments

1. Send an email to Barack Obama (single recipient)

<a href=“mailto:obama@whitehouse.gov”>

2. Send an email to Barack and Michelle Obama (separate multiple recipients with a comma)

<a href=“mailto:obama@whitehouse.gov,michelle@whitehouse.gov”>

3. Send an email to Barack but put Michelle in the CC: list and Joe Biden in the BCC: list

<a href=“mailto:obama@whitehouse.gov?cc=michelle@whitehouse.gov&bcc=joe@whitehouse.gov”>

4. Send an email to Barack Obama with the subject “Congrats Obama”

<a href=”mailto:obama@whitehouse.gov?subject=Congrats%20Obama”>

5. Send an email to Barack Obama with the subject “Congrats Obama” and some text in the body of the email message

<a href=”mailto:obama@whitehouse.gov?subject=Congrats%20Obama&body=Enjoy%20your%20stay%0ARegards%20″>

How to Tie a Tie

by Dan | Comments Off

How to Tie a Tie video

Click to continue reading “How to Tie a Tie”

Bad Wal-Mart

by Dan | Comments Off

An article on the slow loss of power that Wal-Mart is experiencing from the Wall Street Journal. It also has a video that shows Wal-Marts expansion like a virus across the US

Click to continue reading “Bad Wal-Mart”