| Subcribe via RSS

How to Restart Windows Explorer

January 13th, 2009 | No Comments | Posted in Articles, Computers, windows

Yesterday, I was uploading a large number of files with FileZilla. While it was uploading, I tried to visit a website with Firefox. There was a very bizarre problem–when I typed the letter “e”, the My Computer window opened. However, there is a simple fix for this:

  1. Press Ctrl+Alt+Delete.
  2. Go to the Processes tab, and find “explorer.exe”.
  3. Click End Process
  4. Now to restart it, click File>New Task, type “explorer”, and click OK.
Tags:

Get a Cool and Usable Desktop for Free

January 3rd, 2009 | No Comments | Posted in Articles, Computers
Tags:

Rescue Files from Dead Macs

September 26th, 2008 | 3 Comments | Posted in Articles, Computers

Last month, my 3 year old Mac finally kicked the bucket. The Starting Mac OS X screen would appear and the progress bar would reach the end, but the computer would not go any further. 2 months before I had first become aware of the hard drive problem, and backed up all the important stuff onto CD-RWs, but of course after it died I thought of some more stuff I needed. So here’s a quick way of getting your files off.

Stuff You Need:

  • Another computer (PC or Mac)
  • A network that both computers can be connected to

Now, let’s get started!

  1. First, make sure the computer is connected to your network.
  2. Start it up, while holding Cmd+S.
  3. You should reach a command line. Type the following (it will start an SSH server, which we will use to retrieve the files).
    /usr/sbin/sshd
  4. One more step to get it ready: The computer is not fully started up yet, so the ethernet interface is not yet available (if you type ifconfig, the only interface listed is loopback). Type
    sh /etc/rc
  5. It will now proceed with the startup process. Once you get an error line (mine was some disk read errors followed by “coreservicesd crashed”), you can now try to retrieve your files.
  6. The SFTP  (SSH FTP) program used in this tutorial is FileZilla, although any such program will work. Download and launch it.
  7. Choose Site Manager from the File menu.
  8. Click New Site.
  9. Settings:

    Host: your Mac’s IP address (check your router manual, for a Linksys router it is 192.168.1.1xx)

    Server type: SFTP

    Logon type: Normal

    User: your username

    Password: your password

  10. Click Connect.
  11. If all goes well, you can now access your files as on an FTP server.

Hope this helps!

Tags:

Improve Your Wordpress with Plugins

August 23rd, 2008 | 3 Comments | Posted in Articles, WWW

WordPress (WP) is great as is, but did you know that you could improve it? Plugins add more to the functionality to your blog. The official plugin directory has a lot, but I will focus on my favorites.

All In One SEO Pack

Blogs are useless unless they have some readers. If you write articles, you should try to optimize them for search engines. This extension has many options, such as changing the home page title and description and changing the format of the titles of various pages.

Google Syntax Highlighter

If you run a coding blog, you need a plugin like this. This one uses JavaScript to highlight code in many different languages. You can see it in use on this site.

NextGEN Gallery

This is a plugin for you artists/photographers. It displays a gallery of images on a page you specify, and contains many admin features such as uploading from a zip file, albums, and roles, so people other than the main admin can modify the gallery.

ShareThis

Social media sites are among the best ways to get a lot of traffic (assuming your server can handle it!). This plugin adds a button to the bottom of each post. Click it, and the users can submit the post to sites like Digg or StumbleUpon, email it, or post it on their own blogs.

WP-SpamFree

Spam is very annoying for blog owners. It adds lots of junk to the moderation queue, and spams your inbox if you have notifications enabled. This extension uses multiple tests to verify that the commenter is human, and does not require an account on another website.

And now you know 5 more methods of making your blog better. Happy blogging!

Tags:

16 Ways to Waste Time on the Internet

August 23rd, 2008 | 1 Comment | Posted in Articles, Computers, Linkification, WWW

After a long day of web programming, why not relax for a while? These sites will help with that.

Free Games

  • Sodaplay - Contains some different physics games. You can build moving creations out of springs and masses, make a minigame, or draw shapes in different colors and animate them.
  • Phun - You can build 2D things out of parts like boxes, circles, hinges, fixates and springs. When you’re done you can upload it to Phun Box to share it with other people a nd get ratings and comments.
  • iSketch - A game like Pictionary, but played online with people from all over the world. One person draws an object, and other people try to guess what it is. The winner is the person with the most points, which are obtained by drawing good pictures or guessin correctly.
  • Free Evo2 4×4 Evo 2 is a game that originally came out in 2001, but has recently been released as a free download. It has lots of offroad tracks, a career mode, and multiplayer online play. The only catch is that most of the trucks have been removed from the game and replaced with a few custom ones.
  • Falling Sand Game - A collection of online as well as downloadable games. This is sort of difficult to explain, but it’s more interesting than it sounds, especially if you download one of the games and install modifications (in the wxSand, Enigma Sand, and Burning Sand forums.)

Websites

  • StumbleUpon - This is a toolbar integrated with a website. After you sign up, you can tell the site what your interests are. Then you can click the Stumble! button to visit sites related to your interests. After you arrive at a site you can click the I like it or Not for me buttons to affect what sites it shows you in the future. You can also review websites, or add people that you are interested in as a fan to see the sites that they have rated.
  • PyWeek- A contest for games made with the Python language. You can enter your games in the contests, or download games other people have made (there are a lot).
  • Computer Stupidities - Stories about stupid people trying to use computers!

Blogs

Resources

  • HotScripts - Largest collection of scripts in all languages.
  • Dafont.com - Lots of free fonts, in many different categories.
  • Good-Tutorials - Tutorials for just about anything.
  • Zymic - Free hosting, tutorials, and templates.
  • YoungCoders - Help forum for young programmers.
Tags: , ,

Super-Simple Wordpress RSS Syndication For Your Site

August 21st, 2008 | 4 Comments | Posted in Articles, Code, Computers, Linkification, PHP, WWW

If you’re like me you probably have a blog as well as another site. I have found that an effective way to get vistiors to the blog is to link to it from the main site, assuming that that site is more popular. RSS (Really Simple Syndicate) is a way of syndicating your blog to other areas of the web. It is based on XML and generated automatically by Wordpress.

A PHP RSS parser is MagpieRSS. We will be using it in the following tutorial.

  1. Download the most recent version of MagpieRSS from the above website.
  2. Upload the “rss” folder to your web server.
  3. Next we need to make a PHP include file for displaying the posts. Use the following code
    <?php
    require_once('rss/rss_fetch.inc'); //Include the MagpieRSS include file
    $url = 'http://yoursite.com/blog/?feed=rss2'; //Set a variable containing the URL to your blogs RSS feed
    $rss = fetch_rss($url); //Retrieve the posts
    $items = array_slice($rss->items, 0, 5); //Only show the first 5 posts (the second number can be customized to suit your needs)
    $posts = '';
    foreach ($items as $item) { //Loop through the items
    	$href = $item['link'];
    	$cat = $item['category'];
    	$title = $item['title'];
    	$date = $item['pubdate'];
    	$text = $item['content']['encoded'];
    	$text = preg_replace('/<img [^>]+\/?>/', '[image]', $text); //Replace images with [image]
    	$text = preg_replace('/<\/?[^>]+>/', '', $text); //Get rid of HTML
    	$posts .= "<li><a href=$href>$title</a> <em>".substr($text, 0, 100)."</em></li>"; //Print the current post title linked to the page on your blog, and the first 100 chars of the post
    }
    echo $posts;
    ?>
  4. Now you can include that file into your site wherever you want the feed to appear. Enjoy the free traffic!
Tags: , ,

Keep Spambots Out with a Simple Math CAPTCHA

July 19th, 2008 | 5 Comments | Posted in Articles, Code, PHP

Spambots are undoubtably among the most annoying problems for web developers. They look for forms on your site, and submit links to their own websites, repeated many times and mixed with keywords. One way to deter them is a CAPTCHA (Completely Automated Public Turing Test to Tell Computers and Humans Apart). One common form of this is an image with distorted letters, and the user has to type in the letters. I find those really annoying, and unless you are very popular you probably don’t need something so difficult to crack. Our CAPTCHA will ask the user to answer an addition problem.
More »

Tags: ,

Pagination in PHP

July 18th, 2008 | 6 Comments | Posted in Articles, Code, PHP

If you are going to have a site where users can submit stuff, and the stuff is listed on one page, you definitely need pagination. Pagination scripts consist of two main parts: getting the correct records and displaying them, and displaying the page links at the bottom.
More »

Tags: ,

Easily Transfer Files Between Windows and Mac, Only 1 Download Required

July 10th, 2008 | No Comments | Posted in Articles, Computers

This is a quite easy method of transferring files between your networked Windows and Mac computers.

First, go to System Preferences, Sharing, and check the Enable Remote Login box. What this does is start an SSH server on the computer. We will use this server to connect from the PC later.

Now, you need a FTP over SSH (SFTP) client. FileZilla is an excellent open source program for this purpose. After installing it on your Windows PC, launch it. Select Site Manager from the File menu. Select New Site, and use the following settings:

  • Host - your Mac’s IP address (you can find this by typing ifconfig at the terminal, look for a line that says “inet xxx.xxx.xxx.xxx” in the en0 section)
  • Server type: “SFTP - SSH File Transfer Protocol”
  • Logon type: Normal
  • User: your username
  • Password: your password

Now, you should be able to click Connect and access the files on your Mac!

Tags: , , ,

Creating a Login Script in PHP

July 9th, 2008 | 4 Comments | Posted in Articles, Code, PHP

A user authentication system is required for most large webapps. The login script we will make in this tutorial will be flatfile based, and contain login, register, and logout features.

More »

Tags: