If it is the "pull out" type there should be a button on the switch accessible under the dash that will release the knob (Lights will turn on). Pull knob off and you will be able to remove the bezel which will allow switch to be removed. It is suggested that connector be replaced at the same time. Heat generated be switch destroys contacts.
The question you ask is too involved for a proper answer. You may want to go to a car parts store, or book store, and get a repair manual for your car. They cost about $16.00 Or, go to a Public Library.
Headlight Switch Removal and Installation
Ford Crown Victoria / Mercury Grand Marquis 1989-1998
from Autozone DIY
http://www.autozone.com/az/cds/en_us/0900823d/80/17/3b/a8/0900823d80173ba8/repairInfoPages.htm
it's your headlight switch
Bad door switch or bad headlight switch
on a 1997 Mercury Grand Marquis kill switch be activated by a rear end collision
only the headlights are suppose to flash on a headlight flasher
The 1986 Mercury Marquis does not have a fuel cutoff switch. The fuel pump does have a fuse, of which could render it as nonworking.
check your fuses
The headlight switch is not repairable in a Cavalier. The switch will need to be removed and replaced. The procedure is different, depending on the Cavaliers year.
connected to the turn signal
where you turn on the headlights ... push the button
Why ? Just replace it.
its in the trunk
If the back of the rear seat can be removed, then you can crawl into the trunk and release it. If that is not an option, and the electric switch cant be fixed, then the lock will either have to be picked or drilled out.