In England and Wales your door layout needs to comply with these regulations:
Part B Fire safety:
http://www.planningportal.gov.uk/uploads/br/AD_B_v1_wm.pdfhttp://www.planningportal.gov.uk/uploads/br/AD_B_v2_wm.pdf
The actual regulations are very simple; most of these documents are guidelines. Example, the regulation for alerting of fire and providing for escape is: "Means of warning and escape B1. The building shall be designed and constructed so that there are appropriate provisions for the early warning of fire, and appropriate means of escape in case of fire from the building to a place of safety outside the building capable of being safely and effectively used at all material times.
(a) 1952 C.52; Section 33 was amended by Section 100 of the Criminal Justice and Public Order Act 1994 (C.33) and by S.I. 1963/597."
You can do something different from the guidelines as long as you are willing to spend the money to get a fire engineering strategy which proves to the satisfaction of the Building Control department that your design will comply with these regulations.
In the US the regulations vary state by state and are generally more proscriptive. I remember when I was working on a building in New York the actual manufacturer of the drainage pipe required appeared to be specified by the regulations, which seemed a bit fishy to me. But, I'm not an expert in US building codes, so maybe I misunderstood.
You can do something different from the guidelines as long as you are willing to spend the money to get a fire engineering strategy which proves to the satisfaction of the Building Control department that your design will comply with these regulations.
However, in the case of toilets, the layout is much more likely to be constrained by disability access requirements. Part M Disabled access http://www.planningportal.gov.uk/uploads/br/BR_PDF_ADM_2004....
In the US the regulations vary state by state and are generally more proscriptive. I remember when I was working on a building in New York the actual manufacturer of the drainage pipe required appeared to be specified by the regulations, which seemed a bit fishy to me. But, I'm not an expert in US building codes, so maybe I misunderstood.