July 27, 2009

How to Untar a File Without SSH Access

Filed under: Productivity,Web Development — Jack @ 9:05 pm

You have a tar.gz package that contains a lot of files for your website. Your web host doesn’t provide an easy option for you to untar it once it’s on the server. Uploading all of the files one by one is a very time consuming process and should be avoided if possible.

You could request SSH (secure shell) access from your hosting provider, which can be dangerous for those who do not understand exactly what they are doing.  Also, some hosts will not give you this access. As a workaround, you can use this trick:

  1. Open your favorite text editor and create a new file with the following code:
    <?php system("tar -zxvf my_tar_package.tar.gz") ?>
  2. When entering the above code, replace “my_tar_package.tar.gz” with the name of your tar.gz file and name the file my_tar_gz.php.
  3. Upload both the tar.gz archive and the newly created my_tar_gz.php to the directory in which you want to unpack the files.
  4. Navigate to my_tar_gz.php in a web browser. The script will run and the tar.gz files will be unpacked with the quickness.

I used this solution on a site today and if I had to upload all of the files one at a time, it could have easily taken an hour or more. Instead, it was done in less than 5 minutes.

Hope it helps!

July 8, 2009

Splash Pages Are So 2000-Late

Filed under: Flash,Usability,Website Design — Jack @ 1:03 pm

A splash page is a frequent request from clients.  It’s basically a page that loads before the home page.  Splash pages often contain obnoxiously overbearing flash movies that really serve no purpose other than to make the site owner feel cool.

IMHO, splash pages are a big no-no.  Here’s why:

  1. Splash pages usually take a loooooooong time to load.  Do you like having to wait when you do your web surfing?
  2. Your site’s most important page is the home page.  Why would you want to make it harder for visitors to get there?
  3. They get old real quick.  Would you watch your own flash movie 100 times without losing interest?
  4. Every portion of your site should have a reason for being there.  What purpose does your splash page serve?
  5. They are usually expensive.  Flash development isn’t cheap and depending on the depth of your splash page, it could potentially cost more to create than the rest of your site.

I’m sure there are plenty of other good reasons NOT to use splash pages and it’s hard to think of a good reason for creating one.  So, don’t waste your time or budget!