Wal-Mart (NYSE:WMT) has got some problems. I'm not talking about competition from Costco (NASDAQ:COST) or fleet-footed Target (NYSE:TGT), although that is something for shareholders to watch.

No, Wal-Mart's biggest problem these days is bad PR: alleged immigrations violations with its cleaning crews, the perception of low wages, and, of course, the old "putting Mom and Pop out of business" bugaboo. All of this has added up to one big, bad reputation. So bad that the firm organized a recent feel-good campaign, but unfortunately, a few bad deeds carry a lot more water than Wal-Mart's current cures.

I still shudder at the firm's ham-fisted handling of recent controversies. How about that Arizona newspaper advertisement that compared a proposed Wal-Mart-unfriendly ballot initiative to a Nazi book-burning? Or the Mexican subsidiary that was allegedly encroaching on an important archeological zone. Or how about Wal-Mart's attempt to carve out its own corporate fiefdom out there in California?

The problem is, there can be real financial fallout for this kind of corporate egotism. What happens when you're perceived as one of the world's biggest bullies? Just ask Microsoft (NASDAQ:MSFT). Or wait for the shoe to drop, as with recent, hare-brained health-care legislation in Maryland pushed by a competitor, Dutch firm Ahold's (NYSE:AHO) Giant food chain (which subsequently showed its gratitude by buttoning up several facilities in the state, dropping many employees).

This is all a long-winded introduction to what might be a glimmer of hope. This week, Wal-Mart announced that it was dropping its spiteful plans to skirt zoning regulations in Dunkirk, Maryland, by opening two entirely separate stores. The side-by-side operation it had proposed was the first of its kind, and was simply a way to get around the county's 75,000-square-foot limit for a single retail store.

According to remarks published in TheWashington Post, Wal-Mart said its reconsideration was a direct response to "community outcry." That's a start.

But how's this for a better idea? Treat values as something more than a theme for a schmaltzy TV campaign. Don't wait for a deafening community outcry to respond to a community's principles.

For related Foolishness:

Seth Jayson finds it pretty tough to feel sorry for Wal-Mart sometimes. At the time of publication, he had positions in no firm mentioned. View his stock holdings and Fool profile here. Fool rules are here.