If you must use a fire extinguisher, remember PASS to use it correctly.
P - pull the pin at the top of the extinguisher. The pin releases a locking mechanism and will allow you to operate the extinguisher.
A - aim at the base of the fire, not the flames. This is important. To put out the fire, you must extinguish the fire at the source.
S - squeeze the lever slowly. This will release the extinguishing agent in the extinguisher.
S - sweep from side to side. Move the fire extinguisher back and forth across the base of the fire until it has been completely extinguished. Stand a safe distance away, and as the fire begins to recede, more forward.
After a fire has been extinguished, do not immediately leave the scene. Instead, monitor the area for a few minutes to ensure that the fire does not re-ignite.