Akismet (Anti-Spam)

Posted by Brian R Cline | Wordpress | Monday 5 September 2011 5:00 pm

Akismet has worked extremely well for me over the last two years, it’s only inaccurately identified two comments as spam out of almost 20,000 comments. Akismet is pretty much the only plugin used on every WordPress blog, and works for almost everyone although it is no longer free for business use.

There’s been reports over the last year or so of comments missing for some people, but I haven’t ever experienced this or heard from anyone I know of comments disappearing.

Although, extremely good Akismet won’t always solve all spam problems especially on sites with a lot of traffic. I usually recommend using a capatcha with Akismet.

What do you recommend or use?

Converting Access to MySQL

Posted by Brian R Cline | Programming | Monday 5 September 2011 4:51 pm

For a client, I took on some very old ASP code that desperately needed some TLC before the site relaunches.

While working on the project I had to convert an old Access 2000 file to a MySQL database. I found a free exe that met all of my needs for the conversion and safely moved all of the data: http://www.bullzip.com/products/a2m/info.php

Access to MySQL uses a wizard like interface to allow just about anyone to safely do the conversion. Only problem I had was that I didn’t have the ODBC driver it liked, otherwise it worked very well and was pretty quick.

Zen Coding

Posted by Brian R Cline | PHP | Friday 2 September 2011 12:09 am

When I first heard of Zen Coding on Sitepoint, I figured it was some other gimmick that might save me about 0.01% of my time each year after I spend five or six hours learning the syntax.

Zen Coding works by expanding some abbreviations into properly closed html. The syntax is very simple, and can be easily explained in just a few examples. The syntax is basically CSS selectors which most web designers / web developers should already know.

Overall, I found installing and using Zen Coding to be very worthwhile. I just made sure to change the shortcut key in Notepad++ because Ctrl + E wasn’t doing it for me. :)

Ports exist for a lot of different editors, and IDEs, so check it out. What other productivity tools do you use?

How I became A Developer

Posted by Brian R Cline | Experience | Thursday 1 September 2011 10:00 pm

It’s no surprise, I’m looking for a change of pace and different employment. I want to spend more time with my family, so I applied for a job at Art & Logic.

Describe how and why you became a developer.
Computers have interested me virtually my entire life. I don’t remember when I got my 1st computer, I remember my dad and mom taking about how my dad would play computer games or use a bbs and have me sitting in his lap. Around the time I was six my dad was given a computer by one of his friends that apparently wasn’t working, I remember it briefly it was a 286 and the case was a very rugged metal, but what I remember most was that my dad got the computer going again and eventually put it in my bedroom.

There were many days and nights I read out of an old beat up DOS manual. Eventually, my dad got a 486 and I inherited his old 386 that could run Windows 95 and HotDog! I made my first website with HotDog and eventually decided to move onto Homesite 1.0 which was extremely awesome and allowed me to learn HTML 3. I started doing chores and using birthday money to buy books, and better computer equipment.

I continued on and eventually went to Niagara College for Computer Engineering, but eventually switched to Computer Programming because that’s where my passion truly exists.

What first attracted you to this field?
The constantly changing and evolving web and computers has always piqued my interest. I’m lazy, I don’t like repetitive work, I couldn’t imagine working in a factory on an assembly line or working somewhere where I don’t get to learn every day.

What keeps you going
I love learning, experimenting and figuring out how to accomplish a goal as long as I’m still able to tinker I’m sure I’ll develop.

Resource interpreted as other but transferred with MIME type text/javascript.

Posted by Brian R Cline | Programming | Friday 26 August 2011 5:21 pm

When I was looking at a site with the Chrome Developer Tools, it had a little error icon that said “Resource interpreted as other but transferred with MIME type text/javascript” when I clicked it.

I couldn’t figure out my error at first, but eventually realized I had for some reason had a script tag with a src assigned of blank and then had javascript between the source tags.

<script type="text/javascript">doSomething();</script>

A blank url or src is of course a reference to the current page. I don’t know why it took me so long to figure that out, but once I changed the page I realized the error.

Hope this helps!

Clean Code – Are Comments Required?

Posted by Brian R Cline | Programming | Thursday 25 August 2011 5:00 pm

On LinkedIn, I noticed a question that didn’t really have any answers or additional comments. “If I write clean code, do I need comments?” was asked by the user on the discussion board.

In an ideal world, there would be no need for comments because the code would be expressive enough that any programmer could easily grasp the concept. Comments should only be used when we are unable to clean the code more, and have it more expressive as Uncle Bob would say.

Comments should only be used to signify code, functionality, libraries, etc that aren’t clear or perhaps ToDo if your IDE supports them. Often code evolves, gets deleted, added to or whatever, but the comments are left in neglect and often end up very wrong about what the code is doing. In Clean Code, Uncle Bob describes this problem in a few words: “The older a comment is, and the farther away it is from the code it describes,the more likely it is to be just plain wrong.”

In an ideal world, you wouldn’t need to write comments, but we don’t live in an ideal world.I think that you still do need some comments, but that the number and frequency of comments should significantly decrease. Comments are a necessary evil sometimes, especially around exception handling or something that isn’t very easy to make clear. Always remember, that we need to be disciplined in updating comments as we modify the code surrounding the comments.

Why I Recommend PayPal

Posted by Brian R Cline | Magento,Programming | Wednesday 17 August 2011 3:00 pm

I spend a significant amount of my timing deal with ecommerce and different shopping systems. One of my all time favourite solutions is using PayPal and Magento together because they have been designed from the ground up to interact well together.

International Acceptance
PayPal is accepted in many countries and is capable of doing automatic currency conversion.

PayPal is very easily integrated in all open source shopping carts, and is often freely available requiring very little work for developers.

No Monthly Fees
Many of the other merchant systems require monthly payments even when your business is closed. PayPal charges a per transaction fee which all of the merchants also charge! If you’re accepting debit the transaction fee could be fairly expensive, but usually it is much cheaper for credit card transactions.

Lots of Payment Options
PayPal does e-checks, American Express, Visa, MasterCard, and Discover. PayPal is expected to release applications for smartphones, and the iPad very soon which will allow you to use your device as a wireless terminal.

You won’t need to spend time worrying about PCI compliance, because the credit card transaction is actually stored and processed on PayPal’s end. Money is usually transferred immediately for credit card transactions.

There are some other shopping solutions available, but don’t expect them to work as well or be as affordable PayPal.

Hope this helps!

SQL Server – Get Only the Date

Posted by Brian R Cline | SQL Server | Wednesday 17 August 2011 2:08 pm

Very often, I need the date of some data and do not like to convert the date to a varchar and then proceed to format it or convert it back to a date.

One of the official Microsoft sanctioned ways is:

Hosts File Location On Windows

Posted by Brian R Cline | Uncategorized | Monday 8 August 2011 4:37 am

Windows 95/98/Me c:\windows\hosts
Windows NT/2000/XP Pro c:\winnt\system32\drivers\etc\hosts
Windows XP Home c:\windows\system32\drivers\etc\hosts
Windows Vista,7 c:\windows\system32\drivers\etc\hosts

It doesn’t have an extension.

Modifying requires admin access on NT/2000/XP and greater.

Notepad must be started with full admin privileges by Right Clicking and saying “Run as Admin.”

WAMP Server Not Accessible on Port 80

Posted by Brian R Cline | PHP,Windows | Tuesday 2 August 2011 5:16 pm

WAMP Server generally runs fine without any problems, although sometimes we have to make some configuration changes because of other software monitoring ports. Skype, for example, is commonly using port 80 to communicate and stopping apache from responding.

If you’re using WAMP and apache at the same time, you need to left click the WAMP Manager icon in the system tray and go to apache -> httpd.conf and look for a line that says: Listen 80 to instead use a different port like: Listen 8080.

Hope this helps!

Next Page »