Holding a pen correctly

An alarming number of literate people have no idea how to hold their favorite writing instrument. This is partly due to parents and teachers being more concerned with getting the script on paper vs. actually teaching proper holding technique. Sadly, a large number of teachers are also unaware of how to hold a pen.

How to hold your pen/pencil correctly

Your thumb, index finger and middle finger create a sort of open triangle. The index finger and thumb don’t need to be closed, however the middle finger does need to cross over toward the thumb a little bit to form a “shelf”. The pencil really rests on the tip of the middle finger while the index finger and thumb prevent the pen from sliding about on this “shelf”.

Note how little effort is needed to hold the pen.

Note how little effort is now needed to hold the pen.

The "open triangle". Note the index and middle finger really does the writing, while the middle finger just sort of rides along.

The “open triangle”. Note the index finger and thumb really do the writing, while the middle finger just sort of rides along below holding up the “shelf”.

While the middle finger creates the "shelf" to hold the pen, the ring finger, little finger and the base of the thumb create the "pad" the hand rests on.

While the middle finger creates the “shelf” to hold the pen, the ring finger, little finger and the base of the thumb create the “pad” the hand rests on.

It’s your thumb and index finger that actually do the writing by moving in unison while the middle finger sort of tags along under both of them holding the pen up towards them.

When the index finger has this slight curve, you’re not putting too much pressure on the pen. Remember you’ve got fingers; not a pair of vise-grips so don’t treat them as such.

Your ring finger, little finger and the lower part of your thumb create the pad that lets you glide about the paper.

What’s the big deal?

This arrangement gives the greatest amount of dexterity when it comes to writing while requiring the least amount of effort. Also, I’ve had juvenile arthritis since the age of 12 so you can bet I’ll look for the least awkward and least painful way to write as long as possible if I can help it.

The longer you write, the more tired and strained your fingers will feel if you don’t hold your pen correctly. If you’ve felt tired or your fingers hurt after writing what seems like a short period of time, chances are you’re holding your pen awkwardly.

No, but really, what’s the big deal?

Everyone types these days. It’s come to a point where handwriting, when it comes to communication, is at about the same level as walking when it comes to transport. People don’t do it because they need to; they do it unless other forms are not available, not applicable or inappropriate.

This is a shame, really.

Humans are not unique when it comes to complex speech. Plenty of other creatures in this world have far more complex speech patterns in a greater range of frequencies that humans can’t even perceive let alone articulate. We aren’t unique in our concept of culture either. Dolphins are routinely known to hunt with different characteristics depending on the area of their range, even though they may be the same species. Likewise, wolves also exhibit uniqueness from pack to pack. Same species, different behavior depending on community and location. We call that “culture”.

The only real difference between us and most other animals is a writing system that lets us pass knowledge from generation to generation. Whereas other creatures are pretty much reduced to chemical secretions when they want to leave a message. In fact, it’s our writing that has allowed us to advance this far and, of course, opposable thumbs helped. Our civilization really owes its existence to writing, not just speech.

Now that you have these wonderful tools at your disposal, wouldn’t you want to know how to use them correctly?

A little background

I’m left-handed, though I usually write with my right hand (unless I’m holding a cup of coffee with my right, or in this case, my phone to take the above pictures).

It became really obvious that I’m left-handed when a few years ago I suffered almost complete numbness in my left hand due to the side-effects of a heart medication I was taking at the time. A lot of things suddenly became far more awkward than I expected because… oh right, I used to use my left hand for that.

I also recently started learning the guitar and I fear my lack of progress with the right-handed instrument may also be due to me being left-handed in addition to the shortage of free time.

When I was in kindergarten, I had an awesome teacher; probably the best I’ve ever had. In many ways she’s the reason I am who I am today and was really responsible for cultivating my curiosity and a tenacity when it comes to satiating it. That aspect has stayed with me to this day, but unfortunately, she had a not so awesome assistant.

Despite me being left-handed, the assistant, in a not so delicate way, made sure I used the right hand when writing, although my repeated switch to the left should have been a hint. The mere concept of a left-handed writer seemed to have been alien to her and, since I was 2-3 at the time, I couldn’t really mount an effective protest. As a result, I now write mostly with my right hand. This is far more common than a lot of people realise.

But she did at least show me how to hold my pencil correctly so I guess I’m grateful for that.

Advertisements

Nginx + PHP + MySQL on Windows in 6 minutes

The last time I posted a tutorial on Nginx, there wasn’t a native port of the server available. Riez Opuz posted a link to his Xenstack project on that post that prompted me to write the rest of what I’ve been putting off. It’s a good way to tweak the stack to your own needs.

I tried to leave this as “in 5 minutes”, but then I remembered how long it would take to download MySQL… Even on broadband.

Kevin Worthington had very kindly provided a Cygwin build that ran on Windows, however Nginx now has a Windows build that we can use and this time, we can add MySQL to the list as well. To keep everything compatible, we’ll be using the 32 bit versions for all downloads.

Once you’ve also downloaded Nginx (0.8.53 at the time of this post), head on to the PHP libraries and remember to download the Windows Libraries only (5.3.3 as of today) and select the thread safe version. The first steps are the same with the exception of the download link to MySQL and we need the no-install download.

Make sure to follow this directory structure!

Extract the Nginx files to C:\nginx
Extract PHP to C:\nginx\php
Extract MySQL to C:\nginx\mysql

First, let’s configure MySQL

MySQL no-install is a freakin’ huge download so feel free to delete mysql-test, Embedded, sql-bench and folders named debug once unzipped. If you want to minimize the folder even more, you can optionally delete any .pdb files. This would come in handy if you want to deploy the whole ensamble on a thumb drive or package it for a demo application and are really penny-pinching the available storage space.

Once the cleanup is complete, copy my-medium.ini in C:\nginx\mysql\ into my.ini. I think the medium configuration takes care of most uses and, for a moderately busy site, it fares pretty well.

Always try to copy exising files before making changes instead of outright renaming them. This way, if something goes wrong with the new configuration, we still have the original handy to start over..

Open up the newly copied my.ini file and change the [client] block to match the following.


[client]
#password	= your_password
port		= 3306
socket		= c:/nginx/mysql/tmp/mysql.sock

Note the Unix style forward-slashes.

Now in the [mysqld] block in the same file, change to match the following :


[mysqld]
port		= 3306
socket		= c:/nginx/mysql/tmp/mysql.sock
basedir		= c:/nginx/mysql
datadir		= c:/nginx/mysql/data
bind-address	= localhost
enable-named-pipe
skip-external-locking
key_buffer_size = 16M
max_allowed_packet = 1M
table_open_cache = 64
sort_buffer_size = 512K
net_buffer_length = 8K
read_buffer_size = 256K
read_rnd_buffer_size = 512K
myisam_sort_buffer_size = 8M

Now let’s try and run our MySQL server

Start a new command line window…
Note: If you’re running Windows Vista or above with UAC enabled, you need to right click on the command line link and select “Run as administrator”.. If you get a message saying “Install/Remove of the Service Denied!” when trying to start MySQL later on, then you probably have UAC running, so this step is very important.

Navigate to C:\nginx\mysql\bin\ and run :

mysqld --install-manual

There should be a slight delay followed by a “Service successfully installed”. We then must run :

net start mysql

…And if there are no errors noted, then Congratulations!

Before we proceed, we need to run some housekeeping operations. In the same command line window, run :

mysqladmin -u root password newpassword

Where newpassword is your new MySQL root password. This is an important step toward securing your installation.

Now that we’ve changed our root password enter the following :

mysql -u root -p

Which will give you a password prompt. Enter your newpassword created before. Once you’re logged in, you’re at the MySQL console.

If you need to change your root password at a future date, run mysql as above type the following :

update mysql.user set password=PASSWORD('new-newpassword') where user='root';

Note that passwords are encoded before storage in the database, so we need to run the PASSWORD function on our new-newpassword. Once that’s done, be sure to run :

flush privileges;

Now we need to remove all the junk that came with the server.

Delete the test databases and anonymous users (Always remember the semicolon at the end!) :

delete from mysql.user where user='root' and host!='localhost';
drop database test;
delete from mysql.db where db='test' or db='test\_%';

And finally flush privileges and quit :

flush privileges; quit;

Now if we need to, we can stop MySQL by running the following (in C:\nginx\mysql\bin\ as an Administrator of course):

net stop mysql

And if we need to remove it from our services entirely, run the following :

mysqld --remove

Onward to setting up PHP

Site of the Week: How to bake a potato

After being on hiatus for a month, it’s time to bring it back!

How to bake a potato, step by step with pictures

How to bake a potato, step by step with pictures

Why visit a site where everything is crammed into one database? All you do is spend your time searching and searching through the myriad of other gibberish you don’t want to sift through.

This site does one thing and it does it correctly. It’s only one page and, by God, it’s actually useful information!

nginx + PHP on Windows in 5 minutes

Update November 7, 2010

There’s now an updated version of this tutorial which also covers incorporating MySQL.


If you’ve ever needed a very fast, stable, no frills, web server to serve up some pages on a home system, then look no further than nginx. The server is rock solid and gets the job done. And the setup and configuration is unmatched in simplicity for other servers of similar capability.

Nginx is native to the UNIX platform, so you’ll need to get a precompiled version or install Cygwin. I opted for the former because there’s already a package available by Kevin Worthington that works very nicely.

Download the stable package and install it. Because of the Cygwin configuration, it will install to c:\nginx.

Then download the latest PHP Windows binaries (not the installer) and extract all files to c:\nginx\php. We will be using php-cgi.exe because of the nginx fast-cgi capability. Make sure the path is c:\nginx\php\php-cgi.exe during the installation.

Almost there…

Go into c:\nginx\conf and uncomment or modify the following lines in nginx.conf.

location ~ .php$ {
  root           html;
  fastcgi_pass   127.0.0.1:9000;
  fastcgi_index  index.php;
  fastcgi_param  SCRIPT_FILENAME c:/nginx/html/$fastcgi_script_name;
  include        fastcgi_params;
}

Then, in the same folder, edit start-nginx.bat to include the following line :

@ECHO OFF
c:\nginxnginx.exe
c:\nginx\php\php-cgi.exe -b 127.0.0.1:9000 -c c:\nginx\php\php.ini
ping 127.0.0.1 -n 1>NUL
echo Starting nginx
echo .
echo .
echo .
ping 127.0.0.1 >NUL
EXIT

Now edit stop-nginx.bat and add the following lines :


@ECHO OFF
taskkill /f /IM nginx.exe
taskkill /f /IM php-cgi.exe
EXIT

It’s not a perfect solution, but works for non-production applications.

That should be it!

If you need to hide that ugly command prompt during startup, just create two files in conf (alongside start-nginx.bat) and enter the following code :

In launch.js :


var objShell = WScript.CreateObject("WScript.Shell");
var result = objShell.Run("cmd.exe /c start-nginx.bat", 0);

// Give some startup time
WScript.Sleep(3000);

// Navigate to homepage
objShell.Run("http://localhost");

In shutdown.js :


var objShell = WScript.CreateObject("WScript.Shell")
var result = objShell.Run("cmd.exe /c stop-nginx.bat", 0)

Now to startup nginx with fast-cgi PHP, just double-click launch.js. To stop, double-click shutdown.js.

You can make yourself a HTML Application to run these JavaScripts and build a basic control panel at a future date.

Update 12/08

Changed the php.ini file location to an absolute path.

Changed the stop-nginx.bat commands to taskkill instead of multiple process -k lines (you can never tell how many instances there may be of php-cgi.exe, so it’s impractical to do it the old way).

Note: Copying entire blocks is recommended as parts of the code is hidden by my display theme. However all the text is there. Hightlighting the whole thing will ensure that no parts are left behind.