Well, this is the first time I tried to photograph the fireworks. The most important thing of all is to have a tripod, of course. The second thing I did is to figure out how long it took before each of the fireworks die out, so that I had an idea how long I should set my shutter speed. Then I just need to set a corresponding aperture to get a reasonably good exposure.
And I don't forget one last thing, find a good spot to photograph the fireworks before it starts!