The heavy rains this week inundated the region, leaving parts of Philadelphia underwater. Storm after storm, from Manayunk to South Philly, the problems of water-logged basements and flooded cars persist.

The torrential rain left 3 to 4 feet of water in the G.J. Littlewood & Sons building, a raw stock dyeing facility of Main Street.

"We got about three to four feet of water inside the building. we were able to save most of machinery after the water comes through," said owner Robert Littlewood. "The biggest issue is getting it all cleaned up afterwards."

Once he clears all the mud and debris out of the building, Littlewood said he'll start analyzing the damage.

Dylan Rose of Manayunk Brewing Co. said it will take another three weeks until the flood-prone restaurant can reopen. He said he was caught off guard by how quickly the water rushed in and rose to 5 feet.

"Tables, chairs, food, all kitchen supplies, all front-of-the-house supplies, anything you can see is damaged," Rose said. "You walk in -- carpet, walls, our bar fell over, it's just everything is damaged, everything."

Not all flooding is equal, at least in the eyes of the law.

Paula Brumbelow, a Philadelphia city planner, pointed out there are actually two different kinds of flooding, and each is regulated in a different way.

First is the sort of flooding that happens when rivers and streams get too much water and rise. That sort of flooding is covered by FEMA flood maps and includes areas in and close to the river, called floodways. Larger areas are known as a flood plain.

"It's like if you have an ice chest, and you have some water in the ice chest, and you put in more buildings  ... then the water goes up when it rains," she said. "That's a flood plain."

Brumbelow said in those flood-prone areas, federal regulations allow docks, trails, roadways and bridges to be built. But she said new homes located in the flood plain must be at least 18 inches above the maximum height FEMA anticipates the flood waters could reach.

"The city follows the FEMA regulations for building within a flood plain so we limit construction in floodway zones to ensure that they don't create an increase in base flood elevation in the special flood hazard area, which most people would consider the 100-year flood plain."

In flood plains, Brumbelow said, nonresidential structures such as parking garages can be built lower than homes as long as they have precautions including drains and the careful placement of wall outlets.

The other kind of flooding is caused by stormwater, and falls outside FEMA regulations. Brumbelow said the ice chest metaphor can be applied to stormwater flooding too.

"If you do the same thing, but the drain is closed and you pour water over it, that's stormwater flooding."

Brumbelow said there are no restrictions on building in areas that are vulnerable to stormwater flooding. But, she said, Philadelphia is taking a big step to reduce stormwater flooding in the city.

New stormwater regulations require builders to control runoff by managing stormwater on the construction site. The city also encourages installing a green roof or other system or surface that will help keep the water from backing up and flooding.