MainelyDesign.com Blog

Software Tagged Blog Posts

Speeding Up Windows 8 for Web Development (using WAMP)

Posted on 02/25/2013 at 01:33 pm | Viewed 48,189 times | 0 comments

Here is my list of optimizations and changes you can make (and I've had to make) in order to get WAMP (and CakePHP) to run faster on my Windows 8 computer.

Speed Up WAMP Web Development on Windows 8

The short list, in order of importance (stop once you are happy with your localhost web server response time and speed):

  • Get the latest version of WAMP.
    Start by downloading the latest wamp.  I used the 64 bit version.  Download WAMP here.

  • Edit your hosts file.
    Make sure it has the proper entries, and most importantly, remove the IPv6 localhost setting.  Your Windows 8 hosts file should look like this:

    127.0.0.1          localhost
    #    ::1             localhost

  • Disable IP v6
    A great tutorial can be found here.  My advice is to disable IPv6 BOTH ways- via the network adapter and via the regedit hack.

  • Edit Apahce httpd.conf
    These tweaks are supposed to speed up the lstat() system calls when reading files/scanning directories.  They are:

    EnableMMAP On
    EnableSendfile On

  • Edit PHP.ini
    Increase the real path cache size.  This helps when you have lots of files involved.

    ; Determines the size of the realpath cache to be used by PHP. This value should
    ; be increased on systems where PHP opens many files to reflect the quantity of
    ; the file operations performed.
    ; http://php.net/realpath-cache-size
    realpath_cache_size = 24M

  • CakePHP: make sure debug is off.

Must Have Tool for Screen Capture: Greenshot

Posted on 02/25/2013 at 12:31 pm | Viewed 13,133 times | 0 comments

I'm attempting to better document some of the tools and utitlites I use on a daily basis to make worklife just a little bit easier.  Something I find myself doing more and more (especially with my new focus on documentation) is taking screen shots.

First, for a primer on capturing your screen and saving it or emailing it to someone, please read this support post.

Free iPod to iTunes Music Transfer on Windows - iBackuper

Posted on 02/23/2013 at 11:47 am | Viewed 38,011 times | 0 comments

iBackuper is an iPod Access and Transfer Tool for Windows

My review of iBackuper: Excellent, Simple and easy to use.  You can't go wrong when there are only 3 buttons.

I can restore my iTunes Library onto a new Computer using my iPod. Sure thing.

My Windows music library computer finally crashed.  With its demise, all of my music files were safe.  Don't worry I said.  All my music is safely backed up to my iPod.  Common sense, right? Well, to actually import your iPod into iTunes and make your iPod be the actual starting point for the new music library (on the PC), you can't do it in iTunes!  You need software!  Well, most of us need software- if all of your music is in iCloud then you wouldn't be reading this article, anyway.  Right?

The Funniest Error Message Ever - Thank You Eclipse

Posted on 10/18/2010 at 06:34 pm | Viewed 14,328 times | 0 comments

In a depature from my [normally] on-topic (i.e. dry) posts I had to post this error message up here. It made me laugh! I was working on the fattest CakePHP controller known to man (over 4,000 lines, I know... not skinny) when Eclipse ran into issues.  Eclipse gave a very descriptive error message, stating that it couldn't, well see for yourself:

Using KDiff3 as Git GUI Merge Tool on Windows XP and Windows 7

Posted on 09/23/2010 at 01:39 pm | Viewed 50,838 times | 0 comments

I've been looking for the silver bullet solution to using KDiff3 as my git mergetool on Windows (using Git GUI).  I've finally got a solution that works in every Windows environment I've tried:

  1. Add the KDiff3 directory to your Windows System Path (e.g. C:\Program Files\KDiff3\)
  2. Add kdiff3 as your Git mergetool (From Git Bash, run git config --global merge.tool kdiff3)
  3. Add kdiff3 complete path to Git Config (From Git Bash, run git config --global meregtool.kdiff3.path "C:/Program Files/KDiff3/kdiff3.exe")
  4. Go into Git GUI settings and set the mergetool to kdiff3 (if Git GUI doesn't pick up this setting from git config, which it should)

Difference Between Truncate and Empty (Delete From) in Mysql

Posted on 06/23/2010 at 02:30 pm | Viewed 32,030 times | 1 comment

I use Navicat for administering all of my MySQL databases.  It has a command that I always use- empty table.  I noticed today that all along there has been a command right below it for truncate table.  Hmmm.  I figured this would result in the same outcome and wondered what the difference is between emptying a mysql table and truncating the same table.

Export to PDF from Microsoft Publisher

Posted on 03/05/2010 at 10:54 am | Viewed 11,886 times | 0 comments

I have a client that sends me newsletters in Microsoft Publisher format.  I wanted to output the newsletter as a PDF, but wanted to keep the text for SEO and so users can copy and paste the text if needed.  Microsoft Publisher doesn't have an export to PDF function, so usually I would just do a File > Print and select Adobe PDF as the printer.  However, this would just be an "image" of the document, not the actual document with selectable text.  This is how you can get a PDF with rendered text out of Microsoft Publisher...

Faking Symlinks on Windows 2003

Posted on 09/17/2009 at 04:25 pm | Viewed 17,015 times | 0 comments

My production server is a LAMP server.  I love it.  I have one cental location for my CakePHP application and symlink the folders I need to each individual hosting account.  It's pretty easy to do and very powerful.  I work on another server that is Windows 2003.  Everytime I sit down to do work, I bemoan not having the ability to create symlinks.  Turns out there is a way...

Manually Installing MySQL on Windows 2003 Server

Posted on 09/02/2009 at 12:02 pm | Viewed 11,638 times | 0 comments

I have been trying to install MySQL on a web server running Windows 2003 for quite a while now.  I was finally successful! Here's how I did it...

Does your server have a hard-coded IP address?

If so, you need to make localhost refer to the manually assigned IP address in your hosts file.  This file is located in C:\Windows\System32\drivers\etc.

Cheatsheet for Creating .MOV Files from .VOB files (DVDs)

Posted on 07/30/2009 at 11:38 am | Viewed 11,377 times | 0 comments

Every now and again I need to take a video from a promotional DVD and put it on a client's web site.  I use a handy utility that will convert almost any video file into a flash video (.swf/.flv).  The hard part usually comes from having to rip the video from the DVD. 

Avoiding Flash (.flv) 404 Errors on IIS 6 (Windows 2003)

Posted on 07/15/2009 at 11:11 am | Viewed 13,511 times | 1 comment

An interesting thing happens on Windows 2003 Server (IIS 6) when you try and play a .flv file through an embedded shockwave player...nothing.  Well, actually you get a 404 error. 

Fixing the .flv 404 error is simple

All you need to do is tell the IIS server that the MIME type for .flv exists.  Then, the web server can send the appropriate MIME-TYPE header when needed.

Fixing the Default HP OfficeJet Scanner Settings (which suck)

Posted on 05/28/2009 at 11:11 pm | Viewed 12,822 times | 0 comments

The default settings for my OfficeJet L7500 All-In-One Scanner suck!  I thought the scanner was junk.  Every photo I scanned, espcially glossy finished photos, were coming out looking like they were from a 1960s era camera: over-exposed and super high contrast.  Not good!  I thought I had good Photoshop skills, but even they were no match for the over-exposed mess that HP was sending into Photoshop.

Best Eclipse Feature: Link With Editor

Posted on 05/21/2009 at 09:43 am | Viewed 16,147 times | 0 comments

I use Eclipse for all of my CakePHP development work.  I love that you can get code completion, class inheritance, and more by following these steps.  I also loved that I could have 20 something files opened, and when I changed the active document in the editor, my PHP Explorer hierarchy would change in response. 

Dealing with MySQL Old-Style Passwords

Posted on 05/20/2009 at 04:37 pm | Viewed 12,273 times | 0 comments

I ran into a problem I've seen before- Client does not support authentication protocol requested by server; consider upgrading MySQL client. Last time I came across this MySQL error, it was a simple query to fix the issue (from dev.mysql.com):

UPDATE mysql.user SET Password = OLD_PASSWORD('newpwd') WHERE Host = 'some_host' AND User = 'some_user';
FLUSH PRIVILEGES;

Naming a Text File .htaccess on Windows

Posted on 05/13/2009 at 12:15 pm | Viewed 10,852 times | 0 comments

A big pain- you can't just name a file .htaccess through Windows Explorer.  It complains that you need to supply a name!  No problem.

Here's how you can name a file .htaccess (only tested on Notepad, though hopefully it will work on more):

  1. Load up your file in Notepad or create a new file in Notepad
  2. Add your .htaccess declarations
  3. File > Save As
  4. In the filename text box put ".htaccess" - with the double quotes (".htaccess" exactly)
  5. In the filetype select box choose 'All Files'
  6. Save it!

Keep Old Settings When Upgrading Eclipse

Posted on 05/12/2009 at 01:02 pm | Viewed 11,870 times | 0 comments

I decided to upgrade my version of Eclipse to 3.4 (Ganymede) mainly so I could use the Git plugin.  I wanted to migrate my settings from one install to the other.  I know I had done this before, when I upgraded from 3.2 to 3.3, but forgot how.  So I don't have to scratch my head so much next time, here is how you can move your settings after you upgrade your version of Eclipse.

Avoiding New Line Errors using Git on Windows

Posted on 05/12/2009 at 12:27 pm | Viewed 12,179 times | 0 comments

I'm finally working on moving my code over to a version control system.  I've tried several times over the past few years to start using Subversion, but I never quite got into it.  After hearing so much about Git, I decided I needed to start using it.  Luckily, most people tell you to forget everything about Subversion when using Git- no problem there!

Getting Full Resolution Pictures out of MS Word (almost)

Posted on 04/29/2009 at 11:14 am | Viewed 13,945 times | 1 comment

People use what they know.  Most of the time I get photos embedded in an MS Word document for use on a web site.  My workaround to date has been to enlarge the picture (in Word) until it is as big as it gets (keeping quality) or the size I need.  I would then do a print screen and paste into Photoshop. 

I knew that there had to be a better way, but at least I was getting as much resolution as possible from the photo/picture.  Well I came across an interesting scenario today- I couldn't enlarge the photo.  I don't know if formatting was locked on it, but I didn't have time to fiddle with it.  Instead I searched for a way to export embedded photos at full resolution and found this thread.

Full Tag List

Meet Site Avenger - Hosted Content Management System

Powered By: Site Avenger | Site Production: Saco Design