This is presented as a rule in Skip Williams' Rules of the Game (though it's not supported by the actual rulebooks):
You get a flanking bonus from any ally your foe can see (and who is in the correct position to flank). If your foe can't see you, you don't provide a flanking bonus to any ally. You literally cannot flank a blind creature; however, a blind creature loses its Dexterity bonus to Armor Class against your attacks (so you can sneak attack it), and you get a +2 to attack it to boot. Creatures with the blindsight ability effectively "see" within blindsight range and can be flanked.
If you adopt this rule, then you can effectively ignore a flanker by using the Gaze Attack rules to turn your back on them, making them a creature you cannot see.
This is not presented as an official rule, but it's a designer's suggestion (again from Skip Williams):
A Totally Unofficial Rule for Dealing with Foes Trying to Flank You
Jonathan Tweet (co-designer of the D&D 3rd edition game) and I have had many opportunities to ponder the tactical aspects of flanking and what you might be able to do about it if you find yourself flanked. After one extended discussion not long ago, Jonathan proposed the basics of the following rule, and I present it here, with some tweaks:
You can disregard attacks from an opponent flanking you. When you do, that opponent doesn't get the +2 flanking bonus when attacking you and that opponent does not provide a flanking bonus to any of its allies. Ignoring a flanker, however, provokes an attack of opportunity from that flanker, and you lose your Dexterity bonus to Armor Class against that flanker. You do, however, continue to threaten that flanker.
If the flanker is out of attacks of opportunity, you can ignore the flanker (and deny the flanking bonus) with impunity.
If you can't see (or locate) the flanker, you disregard the flanker by default, and you provoke the attack of opportunity.
You must make the decision to disregard a flanker as soon as the foe moves into a flanking position. You can change your decision as a free action on your turn. (You still must disregard a flanker you can't see.)
Designer's Notes: This rule gives certain creatures the option to ignore flankers when they don't pose any real danger to them. Lycanthropes facing foes that aren't armed with silver weapons, as well as characters with very high Armor Classes facing much weaker foes, can soften the effects of being surrounded. Many other creatures can use the rule to limit sneak attacks against them, but at the risk of extra attacks of opportunity from other foes. This rule also means that you often cannot provide a flanking bonus to your allies if you're out of attacks of opportunity (though foes may have a hard time determining exactly when that situation occurs).
So as people have noted, there's no official way to do it, but there are published ways to do it (either as unofficial house rules, or unofficial house rules masquerading as official rules).
-Hyp.