Website Copying, Mirroring and Downloading for Offline Browsing

httrack

I recently had to copy a static website for a client that no longer had access to their back-end. I used a program called HTTrack Website Copier to download the entire site locally, so that I could then upload it to a new server location. It only comes up once a year or so that I need to “download” a site (without back-end access). For the simple static site I used HTTrack Website Copier on… the software worked nicely!

HTTrack’s home page says the following:

HTTrack is a free (GPL, libre/free software) and easy-to-use offline browser utility.
It allows you to download a World Wide Web site from the Internet to a local directory, building recursively all directories, getting HTML, images, and other files from the server to your computer.

Go check out their site here: http://www.httrack.com/

JAM icons has 420+ Premium Icons for Your Personal or Professional Projects

JAM icons

Ran across this freebie today and know how some of you can never get enough icons. Check out this nice collection put forth by Michael A. and download as CSS/FONT FILE or SVG. 420+ icons!

Excerpt from the JAM icons site:

Jam icons is a set of icons designed for web projects, illustrations, print projects, etc. Shipped in both font & svg versions. I aimed to provide a large choice of icons for all projects : filled & outlined icons.
The icons have been made in a 64×64 grid with a 4 pixels stroke basis, all in a consistent way and tested at 18×18, 24×24, 32×32.

Here’s a link to the whole collection you can download in a single zip file:
http://jam-icons.com/

Force HTTPS But Not For Add-On Domain

Setting up a new add-on domain* for a client today and found that I could not access the new add-on domain name directly. It was appending the new add-on domain name to the root or main site url. So instead of taking the visitor to www.newdomain.com it was taking them to www.maindomain.com/newdomain.com, and of course I didn’t want the visitor to see that horrible URL, but only to see the new add-on domain name.

What was happening is there was an HTTPS redirect for all pages on the main site in the .htaccess file. The .htaccess rule was saying, “ANY page visited on the site, redirect to a hard-coded URL of HTTPS, for that page.”

This is what the rule looked like initially:

I needed an .htaccess rule that forced HTTPS on the main site, but left the add-on domain alone to do it’s own thing. Here’s the rule that solved the issue:

For the new .htaccess code replace yourdomain.com on line 7 with your domain. On lines 5 and 6, replace yourdomain\.com while remembering to insert the backslash before the period in your domain name.

Important: If you have existing code in your “.htaccess,” add this above where there are already rules with a similar starting prefix.

 


* An addon domain is a fully functional domain that can be created from within your control panel. Think of it as having multiple hosting packages all sharing the same control panel. You can create email addresses, forwarders and more — the same way you do for your primary domain on the account.

Fix Dreamweaver Double-Spaced Code

Dreamweaver Find and Replace

Due to Unix/Linux/Windows server environments, when you are editing code locally in Dreamweaver you’ll sometimes find your code double-spaced for the whole file.

A quick fix is to run this find/replace command to remove the extra spaces.

  1. Hit CTRL-F or command F to bring up the Find/Replace dialog box.
  2. In the Find box enter “[\r\n]{2,}” (without the quotes).
  3. In the replace box enter “\n” (without the quotes).
  4. Make sure the box for “Use regular expression” is checked and click Replace All.

Read more…

InMotion Hosting: Fix Image Upload Error for WordPress

This may be pertinent for WordPress installs on InMotion web hosting only.

I ran into an image upload error for a new WordPress install where the only message displayed was “HTTP error”. After following the usual actions of checking folder permissions, php memory limits, etc. the solution that worked for me was found in this post from InMotion: How to Fix the HTTP Image Upload Error in WordPress.

Just edit your .htaccess file in the root of your WordPress install (mine was located at /public_html) and add this line to the top of your htaccess file:

I saved the changes and the media uploader jumped to life and began working as it should!