Not having any sort of ventilation will only cause the smell to grow and make it a safety hazard for you and the people living in the house due to the toxicity. If the carpet is situated in the house, open up your windows and allow fresh air to flow through. If it is the carpet in the car that smells like gasoline, than open your windows and let it air out.
Use the absorbent pads to soak up any of the remaining gasoline that may be visible in and around the carpet. Try hitting the spots that seem to be the wettest. Amazingly, this effective method is also used when there are car accidents to pick up any gasoline that might have leaked out.
Water and Vinegar
After creating a mixture with half water and vinegar, use it after all the gas has been absorbed. Like you may know, vinegar is great when it comes to neutralising any sort of smell because of its chemical content.
Let the vinegar and water mixture dry first before applying the baking soda on the area which has been affected by the gasoline. You should let it sit overnight so it can absorb all of the gasoline and then you can vacuum it up in the morning.
Sometimes, the smell will be so strong that it may not have been completely neutralised just yet. Rubbing some coffee grounds into the area for another day should do the trick. This is the last and final method you can test before you may just have to go out and get a new carpet. Remember, you should never just leave the smell of gasoline in the carpet, especially when there are younger children around the house.