
12 Cal.4th 804 (1996)
910 P.2d 1366
50 Cal. Rptr.2d 74
THE PEOPLE, Plaintiff and Respondent,
v.
JESSIE GONZALEZ, Defendant and Appellant.
Docket No. S045546.
Supreme Court of California.
February 29, 1996.
*807 COUNSEL
Michael P. Judge, Public Defender, Albert J. Menaster, Cynthia Solomon, John Hamilton Scott and Alex Ricciardulli, Deputy Public Defenders, for Defendant and Appellant.
James K. Hahn, City Attorney, Debbie Lew and Candice I. Horikawa, Deputy City Attorneys, for Plaintiff and Respondent.
Arlo Smith, District Attorney (San Francisco) and Celia E. Rowland, Assistant District Attorney, as Amici Curiae on behalf of Plaintiff and Respondent.
*808 OPINION
LUCAS, C.J.
In this case we determine the authority of the municipal court and the appellate department of the superior court to consider a challenge to the validity of a preliminary injunction issued by a superior court.
Defendant violated a preliminary injunction issued by the Los Angeles County Superior Court restricting the activities of gang members in a certain geographical area of Los Angeles. The People sought a misdemeanor conviction against defendant in the municipal court for criminal contempt.
In municipal court, defendant demurred to the complaint, seeking, among other things, to assert, on constitutional grounds, the facial invalidity of the injunction he was accused of violating. The municipal court refused to entertain the challenge and overruled the demurrer, stating it had no jurisdiction to review the constitutional validity of an order of a higher court. Defendant was convicted of four counts of contempt. The appellate department of the superior court affirmed, a majority of the court refusing to consider the validity of the injunction on the ground of lack of jurisdiction.
The Court of Appeal determined the municipal court lacked authority to adjudicate an attack on an injunction issued by a court of superior jurisdiction. In addition, it held the appellate department of the superior court, unless it happened to be the department that issued the injunction, lacked authority to review the constitutionality of the injunction on appeal from a contempt judgment entered in the municipal court.
We conclude the judgment of the Court of Appeal should be reversed. Settled California law establishes that there can be no contempt of a void injunctive order, and that assertedly unconstitutional injunctive orders are subject to challenge when contempt is charged, and on review of any contempt judgment. The Court of Appeal failed to recognize that although defendant was not entitled to bring a direct attack seeking to dissolve the injunction in the municipal court, he was entitled to defend against the contempt charges on the ground the injunction he was accused of violating was unconstitutional. That is, he was entitled to challenge the injunction on constitutional grounds when he was charged with contempt and to seek appellate review of the contempt judgment on the same grounds.

I. FACTS
The City of Los Angeles brought a civil public nuisance action in the superior court, and, on April 27, 1993, secured a preliminary injunction limiting the activities of members of the Blythe Street Gang within a certain *809 geographical area of Los Angeles. Among other things, the injunction prohibited gang members from using or possessing deadly weapons, including such items as glass bottles, large metal belt buckles and ball bearings. It prohibited gang members from using or possessing numerous other items, including pagers and cellular phones, whistles and car parts. No gang member was to "annoy, harass, or intimidate any person," or contact any person who "will complain about the defendants' activities," or be present on private property in the absence of the owner without the written consent of the owner. In addition, gang members were enjoined from climbing any tree, wall or fence, and from being on the roof of any building except in an emergency, from obstructing traffic, or if underage, from violating a specified curfew. Adults, too, were enjoined from being present in a specified area between 8 p.m. and 6 a.m., without proper identification and proof of legal residence in the area.
Defendant was not a party to this action, although, as a member of the gang, he was served with a copy of the injunctive order on May 11, 1993.
On May 28, 1993, defendant was arrested after he fled from officers conducting a narcotics investigation in the area designated by the preliminary injunction. In the course of his flight, defendant threw beer bottles at the officers' car and hid in an apartment he had entered without the consent of the owners. On June 22, 1993, an amended criminal complaint was filed in the municipal court, charging defendant with, inter alia, five counts of misdemeanor contempt in violation of Penal Code section 166 (all statutory references are to this code unless otherwise indicated), that is, "willfully and unlawfully commit[ting] contempt of court by willful disobedience of a process and order lawfully issued by a court, to wit: LOS ANGELES SUPERIOR COURT, CASE No. LC 20525 [i.e., the preliminary injunction]...." As to each count, the complaint specified which section of the superior court's preliminary injunction defendant allegedly had violated. Thus, in the first count, the complaint alleged defendant violated the order, section "a) 5, in that the above-named defendant did use and possess a deadly weapon, to wit: glass bottles, in a designated public place." The other contempt counts alleged defendant violated the injunction because he possessed a pager, was present on private property without prior written consent of the owner, entered private property by threat and force, and obstructed pedestrian and vehicular traffic. In addition to the contempt charges, the complaint charged defendant threw a substance at a vehicle and its occupant on the highway, in violation of Vehicle Code section 23110, and entered private property without permission, in violation of the Los Angeles Municipal Code.
Defendant demurred to the five contempt counts of the amended complaint on two grounds. First, he claimed the complaint alleged a violation of *810 an order of the superior court, but did not allege that he was subject to the order. Second, defendant argued the injunction was unlawful on its face because "it improperly seeks to enjoin criminal acts, and it is unconstitutionally vague and overbroad." The demurrer challenged the constitutionality of the sections of the injunction defendant was accused of violating, as well as the constitutionality of the injunction as a whole.
The municipal court overruled the demurrer. It refused to rule on the claim that the injunction was invalid, stating that any constitutional challenge to the injunction would have to be heard in a different court. The municipal court also rejected defendant's motion to dismiss under section 991, again declining to rule on the constitutionality of the preliminary injunction.
Defendant filed a petition for writ of habeas corpus in the superior court, requesting that court to direct the municipal court to vacate the above orders overruling the demurrer and denying the motion to dismiss. The superior court summarily denied relief, its order reciting that defendant had an adequate remedy by way of appeal.
The parties waived jury trial and stipulated to the facts underlying the charges. Defendant refused to stipulate to the constitutionality of the preliminary injunction, and renewed the claims stated in his demurrer. The municipal court again declined to consider the question of the constitutionality of the injunction, declaring that defendant should have appealed the original superior court order granting the injunction. The court found defendant guilty of four counts of misdemeanor contempt for violating the injunction, namely, counts one (possession of glass bottles), two (possession of pager), three (entering private property without permission) and five (obstructing traffic). The remaining three counts were dismissed in the interest of justice. (§ 1385.) Defendant was sentenced to three years' probation on various terms and conditions, including that he serve ninety days in the county jail.
Defendant appealed to the appellate department of the superior court, arguing, inter alia, that the convictions should be reversed because of the unconstitutionality of the injunction.
In a divided opinion, the appellate department affirmed the judgment of conviction. One judge determined the appellate department had the authority to review the constitutionality of those portions of the injunction defendant was accused of violating and, finding them constitutional, rejected defendant's contention the convictions should be overturned. The remaining two judges concurred in the result but expressed the opinion the appellate department had no jurisdiction to review the validity of the injunction. One of these judges believed defendant's sole remedy was to seek appellate review of the injunction when it issued, while the other concurring judge *811 declared defendant's only avenue for review of the validity of the injunction was "by way of a petition for extraordinary relief filed with the Court of Appeal."
On October 1, 1994, the Court of Appeal transferred the case to itself pursuant to rule 62(a) of the California Rules of Court, for the limited purpose of deciding the jurisdictional issue,[1] and reversed.
The Court of Appeal, pointing to state constitutional provisions limiting appellate jurisdiction, concluded neither the municipal court nor the appellate department of the superior court had authority to review the validity of an injunction issued by the superior court. The court determined that defendant's statutory right to appeal (see § 1466) would be meaningless unless the appellate department could review the validity of the order the defendant was charged with violating. In order to avoid what it saw as an equal protection violation for those charged with misdemeanor contempt, as compared with those charged with any other misdemeanor, who retain the statutory right of appeal, the Court of Appeal reached the following conclusion. When a misdemeanor contempt of a superior court injunctive order is charged, the superior court shall have exclusive original jurisdiction to try the charge. If the trial department of the superior court is not the one that issued the order defendant is charged with violating, that court, too, must treat the injunctive order as valid. On appeal to the Court of Appeal, however, the defendant may contest the constitutionality of the order the violation of which resulted in the contempt conviction.
Both parties petitioned for review. Both ask us to reject the holding of the Court of Appeal that the superior court has original, exclusive jurisdiction over misdemeanor contempt charges involving violation of superior court orders. Defendant asks that we hold that both the municipal court and the appellate department of the superior court have authority to entertain a challenge to the validity of a superior court injunctive order in a contempt proceeding. He argues a contrary holding would require us to strike down the misdemeanor contempt statute as unconstitutional or, in any event, to order courts to hold preliminary hearings on misdemeanor contempt complaints filed in the superior court. The People agree that the Court of Appeal erred in purporting to vest the superior court with subject matter jurisdiction over misdemeanor contempt charges. They ask, however, that we limit any challenge to the validity of a superior court injunction in the context of a *812 misdemeanor contempt prosecution to a writ proceeding in the Court of Appeal or this court. Although they did not raise the matter in their petition for review, in their brief on the merits the People also ask that we determine the constitutionality of the underlying injunction.

II. DISCUSSION

A. The Court of Appeal Opinion.

The Court of Appeal determined that the state Constitution limits the jurisdiction of the municipal court and the appellate department of the superior court to adjudicate the validity of the superior court's injunctive order. With respect to the jurisdiction of the municipal court, it asserted that under article VI, section 11 of the Constitution, appellate jurisdiction over superior court judgments is vested exclusively in the Court of Appeal and the Supreme Court. The section provides in pertinent part: "The Supreme Court has appellate jurisdiction when judgment of death has been pronounced. With that exception courts of appeal have appellate jurisdiction when superior courts have original jurisdiction and in other causes prescribed by statute." (Ibid.) Notably, and not surprisingly, the Constitution does not provide that the municipal court may exercise appellate jurisdiction to review an order of a superior court. Accordingly, the Court of Appeal concluded the municipal court had no authority to review the validity of an injunction issued by the superior court.
The Court of Appeal also concluded the appellate department of the superior court lacked authority to pass on the constitutionality of the injunction in the context of defendant's appeal from the judgment convicting him of contempt. The court pointed out that under article VI, section 11 of the state Constitution, a superior court has no appellate jurisdiction over orders of another superior court. That section limits the superior court's appellate jurisdiction to review of judgments entered in an inferior court, stating: "Superior courts have appellate jurisdiction in causes prescribed by statute that arise in municipal courts in their counties." (Cal. Const., art. VI, § 11.)[2]
In addition, the Court of Appeal pointed out that under article VI, section 4 of the state Constitution, a superior court is a single entity. That provision states: "In each county there is a superior court of one or more judges." (Ibid.) The Court of Appeal cited cases interpreting this provision to mean that one department of a superior court normally has no authority to interfere with another department's adjudication of a cause. (See, e.g., Williams v. *813 Superior Court (1939) 14 Cal.2d 656, 662 [96 P.2d 334].) From cases concluding that one department of a superior court cannot overrule the order of another department of the same superior court, the Court of Appeal inferred that one department of the superior court cannot entertain an attack on the validity of an injunction issued by another department of a superior court in the context of an appeal from a contempt conviction.
In support, the Court of Appeal relied on our decision in Williams v. Superior Court, supra, 14 Cal.2d 656. In Williams, a cause was assigned to a department of the superior court for record preparation, and, during the proceedings, the court ordered the court reporter to file a transcript by a specific date. The court reporter failed to comply, and the superior court heard and denied an application to have the order vacated, then issued an order to show cause why the reporter should not be held in contempt. Before the contempt matter could be heard, a second department of the same superior court purported to declare void the first court's order setting a transcript filing date.
We annulled the second court's order, stating "[t]he state Constitution ... provides for but one superior court in each county.... [J]urisdiction is vested by the Constitution in the court and not in any particular judge or department thereof.... It follows, therefore, that where a proceeding has been duly assigned for hearing and determination to one department of the superior court ... and the proceeding so assigned has not been finally disposed of therein or legally removed therefrom, it is beyond the jurisdictional authority of another department of the same court to interfere with the exercise of the power of the department to which the proceeding has been so assigned. [Citation.] In other words, while one department is exercising the jurisdiction vested by the Constitution in the superior court of that county, the other departments thereof are as distinct therefrom as other superior courts." (Williams v. Superior Court, supra, 14 Cal.2d at p. 662.) We explained that if the law were otherwise, conflicting adjudications of the same subject matter would issue from the superior court, causing great confusion. (Ibid.)
The Court of Appeal also relied heavily on Ford v. Superior Court (1986) 188 Cal. App.3d 737 [233 Cal. Rptr. 607]. There the superior court entered judgment in a cause, consisting in part of an order regarding the disposition of documents made part of the record at trial. The court declared that some documents could not be returned to the litigants in the action, and ordered that some of these remain sealed, while others were available for public inspection and comment. Plaintiffs, who were not parties to the original action but who alleged they were persons named in these documents, sought *814 an injunction in another department of the superior court to restrain execution of that part of the judgment relating to the disposition of the documents. The reviewing court affirmed the order of the second superior court dismissing plaintiffs' action, citing Williams v. Superior Court, supra, 14 Cal.2d 656, and the state constitutional provisions discussed therein. The court reasoned that because the superior court is but one court, one department of a superior court cannot review and restrain the judgment entered by another department. Accordingly, it concluded that "judgment rendered in one department of the superior court is binding on that matter upon all other departments until such time as the judgment is overturned." (Ford v. Superior Court, supra, 188 Cal. App.3d at p. 742; see also Elsea v. Saberi (1992) 4 Cal. App.4th 625 [5 Cal. Rptr.2d 742] [when one department of superior court has entered judgment and order denying motion to vacate judgment is on appeal, another department cannot permit intervention of third party and order judgment set aside as to that party]; Slone v. Inyo County Juvenile Court (1991) 230 Cal. App.3d 263, 268 [282 Cal. Rptr. 126] [superior court cannot invalidate order of juvenile court in pending dependency matter because "California law prohibits one department of a superior court from invalidating a ruling made by another department of the same court"].) Plaintiffs' remedy, the Ford court stated, was to intervene in the original action and appeal any adverse judgment. (Ford v. Superior Court, supra, 188 Cal. App.3d at p. 742.)
Concluding from its analysis of these authorities that neither the municipal court nor the appellate department of the superior court had authority to entertain defendant's attack on the constitutionality of the injunction he was accused of violating, the Court of Appeal turned to a perceived violation of defendant's right to equal protection. It pointed out that all misdemeanants have a statutory right of appeal under section 1466, but that defendant's right to appeal the contempt judgment would be made nugatory if his appeal could not raise the primary issue in contention, that is, the constitutionality of the injunction. In order to avoid violating defendant's right to equal protection with respect to his statutory right of appeal, the Court of Appeal purported to vest the superior court with original jurisdiction over misdemeanor contempt charges stemming from the violation of a superior court injunctive order. The court directed that, at trial of such charges, the superior court must accept the validity of the injunction unless it was the department issuing the injunction. The Court of Appeal concluded, however, that on appeal to the Court of Appeal, the defendant may, for the first time, raise the claim that the injunction was invalid.
Both parties assail the holding purporting to vest the superior court with exclusive original jurisdiction over misdemeanor charges. They urge that the *815 power to establish the jurisdiction of the courts rests solely with the Legislature. We need not address this claim, however, because we disagree with the Court of Appeal's holding that neither the municipal court nor the appellate department of the superior court had authority to entertain defendant's constitutional challenge to the validity of the order he was accused of violating.
(1a) With respect to the authority of the municipal court, it is true that the state Constitution does not vest jurisdiction in the municipal court to overturn a judgment of the superior court. Defendant, however, does not claim the municipal court had appellate jurisdiction over the injunctive order of the superior court. He does not argue the municipal court had authority to overturn or dissolve the injunction. Rather, in the municipal court, defendant sought to assert the alleged invalidity of the injunction collaterally, as a defense in a different cause. The claim that such an order is unconstitutional is a recognized defense in a contempt action. Such a claim does not seek to overturn the order, but merely to challenge its use in a separate cause.
(2a) As for the authority of the appellate department of the superior court to entertain defendant's claim on appeal from his contempt conviction, it is true that one superior court generally lacks jurisdiction to overturn, enjoin or declare void the order of another superior court, as the authorities cited by the Court of Appeal show. The state Constitution limits the power to overturn a superior court's order to the appellate courts. (Cal. Const., art. VI, § 11.) Again, however, defendant does not claim that on appeal from the misdemeanor contempt judgment, the appellate department had authority to overturn or enjoin enforcement of the injunction issued by another department of the superior court. Rather, defendant sought to raise the issue of the constitutional validity of the injunction collaterally, as an issue on appeal from the contempt judgment.
The authorities relied on by the Court of Appeal are distinguishable. They involve parties who request a superior court to overturn or enjoin execution of a judgment of another department of that court. Thus in Williams v. Superior Court, supra, 14 Cal.2d 656, the litigant petitioned one department of the superior court to declare void the order of another department of the superior court to which the cause had been assigned. And although Ford v. Superior Court, supra, 188 Cal. App.3d 737, did involve a collateral attack on a judgment, the collateral attack sought to enjoin enforcement of the order  a remedy essentially indistinguishable from an order overturning the judgment. The remedy defendant sought in this case, however, would leave the injunctive order entirely intact, simply limiting the effect of the order in a separate cause.
*816 In sum, although the authorities cited by the Court of Appeal certainly establish that neither the municipal court nor the appellate department of the superior court could dissolve or enjoin enforcement of the injunction,[3] they are silent regarding a court's authority to entertain an argument seeking to avoid the effect of the injunction at trial in a separate contempt action. The propriety of such a collateral challenge, as we shall demonstrate, is an accepted fact of California contempt jurisprudence.

B. The Law of Contempt.

(3) Contempt of a valid order of a court may be punished in two ways. First, an order to show cause regarding an alleged act of contempt may issue in the court that made the order that was violated, commencing a separate action in the ordering court. Upon a finding of contempt, the contemner may be punished with up to five days in jail and a fine. (Code Civ. Proc., §§ 1209, subd. (a)(5), 1218; 3 Witkin, Cal. Procedure (3d ed. 1985) Actions, § 17, pp. 48-50.) Because of the potential punishment, this type of proceeding is considered quasi-criminal, and the defendant possesses some of the rights of a criminal defendant. (Ross v. Superior Court (1977) 19 Cal.3d 899, 913 [141 Cal. Rptr. 133, 569 P.2d 727]; Raiden v. Superior Court (1949) 34 Cal.2d 83, 86 [206 P.2d 1081]; In re Witherspoon (1984) 162 Cal. App.3d 1000 [209 Cal. Rptr. 67]; see also Mitchell v. Superior Court (1989) 49 Cal.3d 1230, 1240-1244 [265 Cal. Rptr. 144, 783 P.2d 731] (plur. opn of Eagleson, J.); 3 Witkin, Cal. Procedure, supra, Actions, § 17, pp. 48-50.) The contemner possesses no right of appeal, however, and review of the contempt judgment is by extraordinary writ. (Code Civ. Proc., § 1222; Bermudez v. Municipal Court (1992) 1 Cal.4th 855, 861 fn. 5 [4 Cal. Rptr.2d 609, 823 P.2d 1210]; Brunton v. Superior Court (1942) 20 Cal.2d 202, 204 [124 P.2d 831]; 8 Witkin, Cal. Procedure, supra, Enforcement of Judgment, § 354, p. 306, and cases cited.)
Disobedience of a valid order of a court may also be punished as contempt under section 166, making it a misdemeanor to engage in, among other things, "[w]illful disobedience of any process or order lawfully issued by any court." (§ 166, subd. (a)(4), italics added.) (1b) Defendant was charged under this statute.
According to section 166, it is only the violation of an order "lawfully issued" that is punishable as contempt. In the case of quasi-criminal contempt as well, "[a]n order of contempt cannot stand if the underlying order is invalid." (In re Misener (1985) 38 Cal.3d 543, 558 [213 Cal. Rptr. 569, 698 P.2d 637]; see also Crawford v. Workers' Comp. Appeals Bd. (1989) 213 *817 Cal. App.3d 156, 169 [259 Cal. Rptr. 414]; Watsonville Canning & Frozen Food Co. v. Superior Court (1986) 178 Cal. App.3d 1242, 1246 [224 Cal. Rptr. 303].)
The rule is well settled in California that a void order cannot be the basis for a valid contempt judgment. We established in In re Berry (1968) 68 Cal.2d 137, 147 [65 Cal. Rptr. 273, 436 P.2d 273] (Berry), a case involving a misdemeanor contempt prosecution, that "the violation of an order in excess of the jurisdiction of the issuing court cannot produce a valid judgment of contempt [citations], and that the `jurisdiction' in question extends beyond mere subject matter or personal jurisdiction...." Rather, "`any acts which exceed the defined power of a court in any instance, whether that power be defined by constitutional provision, express statutory declaration, or rules developed by the courts and followed under the doctrine of stare decisis, are in excess of jurisdiction.'" (Ibid.) Specifically, we held in Berry that a defendant should not be tried in the municipal court for misdemeanor contempt for violating a temporary restraining order issued by the superior court during a labor dispute, when the superior court's order was violative of defendant's First Amendment rights.
This court and the Courts of Appeal have frequently acknowledged that violation of a void order is not punishable as contempt. In In re Misener, supra, 38 Cal.3d 543, for example, we held that a quasi-criminal contempt judgment against an attorney could not stand "if the underlying order [violated] is invalid." (Id. at p. 558.) Similarly, in San Diego Teachers Assn. v. Superior Court (1979) 24 Cal.3d 1, 5 [154 Cal. Rptr. 893, 593 P.2d 838], we held that a superior court's quasi-criminal contempt judgment should be annulled on a writ of review because the judgment was based on an injunction relating to a labor dispute that was beyond the court's authority to issue. And in an earlier case, Fortenbury v. Superior Court (1940) 16 Cal.2d 405, 408-409 [106 P.2d 411], we annulled a superior court's quasi-criminal contempt judgment on certiorari, finding the superior court's order enjoining peaceful picketing during a labor dispute void. (See also Watsonville Canning & Frozen Food Co. v. Superior Court, supra, 178 Cal. App.3d at p. 1246 [valid injunctive order is prerequisite of contempt judgment based on violation of order]; Mowrer v. Superior Court (1969) 3 Cal. App.3d 223, 229-230 [83 Cal. Rptr. 125] [violation of invalid court order cannot produce valid contempt judgment]; 8 Witkin, Cal. Procedure, supra, Enforcement of Judgment, § 342, p. 294 ["contempt adjudication cannot be upheld if the order violated was itself fatally defective"]; 2 Witkin, Cal. Procedure, supra, Jurisdiction, § 277, p. 683 [void order never binding; violation cannot constitute contempt]; 6 Witkin, Cal. Procedure, supra, Provisional Remedies § 330, p. 278 ["contempt adjudication falls if it is determined that the injunction was void"].)
*818 Some other jurisdictions require persons affected by injunctive orders to challenge the injunctive order directly, and in the meantime, to obey the order. Disobedience of the order is punished as contempt whether the order is valid or not.[4] This is known as the "collateral bar" rule. California law is otherwise. Section 166 has defined misdemeanor contempt as involving only the violation of "lawfully issued" orders ever since the statute was first enacted in 1872. Further, out of a concern to protect the constitutional rights of those affected by invalid injunctive orders, and to avoid forcing citizens to obey void injunctive orders on pain of punishment for contempt, this court has firmly established that a person subject to a court's injunction may elect whether to challenge the constitutional validity of the injunction when it is issued, or to reserve that claim until a violation of the injunction is charged as a contempt of court. That is, the defendant in a contempt proceeding in this state may challenge the validity of an injunction, the violation of which is the basis for the contempt prosecution, even if no such claim was made when the injunction issued. (Berry, supra, 68 Cal.2d at pp. 148-149; Fortenbury v. Superior Court, supra, 16 Cal.2d at pp. 408-409.) Although most cases on this topic involve quasi-criminal contempt proceedings in the court authoring the injunction, our language in Berry applies this rule in the context of criminal contempt prosecutions pursuant to section 166.
(4) As we said in Berry, supra, 68 Cal.2d 137, unlike in jurisdictions that do not permit collateral challenges to injunctive orders, "[i]n this state a person affected by an injunctive order has available to him two alternative methods by which he may challenge the validity of such order on the ground that it was issued without or in excess of jurisdiction. He may consider it a more prudent course to comply with the order while seeking a judicial declaration as to its jurisdictional validity. [Citation.] On the other hand, he may conclude that the exigencies of the situation or the magnitude of the rights involved render immediate action worth the cost of peril. In the latter event, such a person, under California law, may disobey the order and raise his jurisdictional contentions when he is sought to be punished for such *819 disobedience. If he has correctly assessed his legal position, and it is therefore finally determined that the order was issued without or in excess of jurisdiction, his violation of such void order constitutes no punishable wrong." (Id. at pp. 148-149, italics added.)
We observed that our rule is "considerably more consistent with the exercise of First Amendment freedoms" than that of other jurisdictions that have adopted the so-called collateral bar rule barring collateral attack on injunctive orders. (Berry, supra, 68 Cal.2d at p. 150.) The high court of Washington has made a similar observation, stating that "[f]requently an injunction issues immediately before the planned activity is to occur and there is then no time available to the enjoined party to make a direct attack upon the injunction. The practical result then is that the enjoined party has no adequate remedy at law and cannot engage in a lawful activity because of an unconstitutional order. To us `[i]t ... seems unlikely that allowing collateral attack would significantly reduce citizen compliance with lawful decrees; the citizen still faces a substantial risk of criminal penalties if proved wrong in collateral, rather than direct, attack on the decree's validity.'" (State ex rel. Superior Ct. of Snohomish Co. v. Sperry, supra, 483 P.2d at p. 611; see also Note, Defiance of Unlawful Authority (1970) 83 Harv. L.Rev. 626, 635 [observing that especially in the case of preliminary injunctions, to require obedience to the order pending review or a full hearing is to effectively restrain freedom of speech: "[i]f collateral attack is barred when there is insufficient time [before the planned speech or strike] for direct attack on the order, the wrongly enjoined party has no adequate remedy [fns. omitted]"]; Labunski, The "Collateral Bar" Rule and the First Amendment: the Constitutionality of Enforcing Unconstitutional Orders (1988) 37 Am. U.L.Rev. 323, 327 [criticizing collateral bar rule on ground it "places in the hands of the judiciary the power to threaten contempt to force temporary obedience to invalid orders that never should have been issued"].)
California courts continue to reject the collateral bar rule adopted by other jurisdictions. Instead, they apply the rule that in the contempt proceeding, the contemner may, for the first time, collaterally challenge the validity of the order he or she is charged with violating. (See Corenevsky v. Superior Court (1984) 36 Cal.3d 307, 327 [204 Cal. Rptr. 165, 682 P.2d 360]; United Farm Workers of America v. Superior Court (1975) 14 Cal.3d 902, 907, fn. 3 [122 Cal. Rptr. 877, 537 P.2d 1237]; Condor Enterprises, Ltd. v. Valley View State Bank (1994) 25 Cal. App.4th 734, 741-742 [30 Cal. Rptr.2d 613]; Zal v. Steppe (9th Cir.1992) 968 F.2d 924, 927; see also 7 Witkin, Summary of Cal. Law (9th ed. 1988) Constitutional Law, § 84, p. 134; 6 Witkin, Cal. Procedure, supra, Provisional Remedies, § 329, pp. 277-278; Note, Defiance of Unlawful Authority, supra, 83 Harv. L.Rev. at p. 633, fn. 48.)
*820 (1c) The question remains, however, which court may adjudicate a collateral attack on a superior court injunctive order.

C. The Proper Forum for Adjudication of Defendant's Challenge.

Defendant argues the municipal court had authority to entertain his challenge to the validity of the injunction in the contempt proceeding, and that the appellate court could review the validity of the injunction on appeal from the contempt judgment.
The People, in opposition, concede that our decision in Berry entitles a defendant to challenge the validity of the injunction at some point during the contempt proceedings. They do not advocate  or even mention  the position of the Court of Appeal that article VI, sections 4 and 11 of the state Constitution limit the power of the trial court to consider a collateral attack on the constitutionality of a superior court's injunctive order. Nonetheless, they ask us to "clarify" Berry and hold that the issue of the validity of an injunction in the context of a contempt prosecution may be raised only in writ proceedings in the Court of Appeal or this court. Challenges in the trial court, they assert, should be barred.

1. Municipal Court Jurisdiction.

We find no cases supporting the People's position that the trial court lacked jurisdiction to entertain defendant's challenge. While the reported decisions naturally emanate from appellate courts, this fact says nothing of the power of a trial court to entertain such a claim. The People's suggestion that Berry, supra, 68 Cal.2d 137, recognizes only collateral attacks by way of writ petition is unfounded; as we will show, Berry acknowledges the power of the municipal court to entertain a collateral attack on an injunction that is raised on demurrer. (Id. at p. 146.)
The municipal court had jurisdiction to try the charge of misdemeanor contempt for willful disobedience of a superior court's order. (Cal. Const., art VI, § 10; Pen. Code, § 1462; People v. Lindemann (1992) 8 Cal. App.4th Supp. 7 [11 Cal. Rptr.2d 886].) A court with jurisdiction over a cause has jurisdiction to resolve all issues before it. (Code Civ. Proc., § 187; Kennedy v. Hamer (1861) 19 Cal. 374, 387; Holibaugh v. Stokes (1961) 192 Cal. App.2d 564, 570 [13 Cal. Rptr. 528]; Guardianship of Peterson (1944) 64 Cal. App.2d 473, 478 [149 P.2d 65].) The validity of the order defendant is charged with violating is such an issue, for, as we have seen, California law defines misdemeanor contempt as, among other things, disobedience of an order "lawfully issued" by a court. (§ 166, subd. (a)(4).) As we have also *821 shown, California law has long established there can be no contempt of an invalid injunctive order. (Berry, supra, 68 Cal.2d at p. 147 [void order cannot sustain contempt judgment; where order is void, "petitioner should not have been adjudged guilty of contempt"]; Watsonville Canning & Frozen Food Co. v. Superior Court, supra, 178 Cal. App.3d at p. 1246; see also In re Blaze (1969) 271 Cal. App.2d 210, 212 [76 Cal. Rptr. 551].) Because under settled law there can be no contempt of a void injunctive order, and because we have long recognized the propriety of collateral attacks on void orders, it seems evident that the trial court is a proper forum in which to raise the issue of the validity of the injunction.
In fact, in Berry itself we stated in dictum that the municipal court, as trial court in a misdemeanor contempt charge, had authority to entertain an attack on the validity of an injunction issued by the superior court. There the petitioners, like the defendant here, were charged with criminal contempt in municipal court for violation of an injunctive order, namely, a temporary restraining order (TRO) issued by the superior court. They obtained a stay of the municipal court criminal proceedings and attacked the constitutionality of the TRO they were charged with violating by way of a petition for writ of habeas corpus in the superior court. We decided they were not obligated to raise the invalidity of the TRO in municipal court in the first instance. But we noted the defendants could have demurred to the misdemeanor complaint in the municipal court on the ground of the invalidity of the superior court's TRO, if the complaint in municipal court had set forth the TRO or referred to it other than "generically." We stated: "[I]n the circumstances of this case [habeas] relief is not barred by the failure of petitioners to challenge directly the jurisdiction of the municpal [sic] court and thus give that court the opportunity to examine its own jurisdiction in light of the constitutional contentions here made. The sole method available for launching such a challenge prior to trial is by a demurrer ... which reaches only defects appearing on the face of the accusatory pleading. [Citation.] Since the order whose constitutional validity [e.g., the TRO] is here challenged was neither set forth nor referred to, other than generically, in the original complaints, the matters presently at issue could not have been raised by demurrer. The remedy of habeas corpus is appropriate in these circumstances; we proceed to the merits of the controversy." (Berry, supra, 68 Cal.2d at p. 146, fn. omitted.)
We conclude the municipal court had authority to entertain defendant's challenge to the validity of the injunction he was charged with violating.

2. Appellate Department Jurisdiction.

(2b) Next, we consider the authority of the appellate department to entertain defendant's claim on appeal from the contempt judgment. The full *822 terms of the injunction defendant was charged with violating were made part of the record at trial. As the Court of Appeal recognized, ordinarily, on appeal from a municipal court contempt adjudication, the appellate department of the superior court would have jurisdiction to decide such issues as the validity of the order that was the basis for the contempt adjudication. The Court of Appeal concluded, however, that no such review was available in the appellate department because the challenged order was that of another department of the superior court. This analysis was based on the assumption that the state Constitution deprived the appellate department of authority to review the order of another department of the superior court. The Court of Appeal erred, as we have shown, in failing to recognize that although a direct attack seeking to overturn the order would not be permitted, a collateral challenge seeking to avoid the effect of the order in another cause is appropriate under established law.
The appellate department of the superior court has appellate jurisdiction over municipal court judgments, and defendant may appeal a final judgment of conviction to the appellate department. (Cal. Const., art. VI, § 11; Pen. Code, § 1466.) Under section 1466, defendant was entitled to raise on appeal any errors of law occurring at trial, the sufficiency of the evidence to support the judgment, the validity of the judgment and any error in denying a motion for new trial. (§ 1466, subd. (a)(2); 6 Witkin, Cal. Criminal Law (2d ed. 1989) Appeal, § 3163, p. 3919.) As we have seen, it is firmly established that a judgment of contempt is invalid and cannot stand if it is based on a violation of a void injunction (Berry, supra, 68 Cal.2d at p. 147 [violation of unconstitutional order "cannot produce a valid judgment of contempt"]; see also In re Misener, supra, 38 Cal.3d at p. 558; San Diego Teachers Assn. v. Superior Court, supra, 24 Cal.3d at p. 5; 6 Witkin, Cal. Procedure, supra, Provisional Remedies, § 330, p. 278.) Just as the constitutionality of the statute or ordinance under which a defendant is convicted is a proper subject for appeal (7 Witkin, Summary of Cal. Law, supra, Constitutional Law, § 84, p. 134 ["a defendant in a criminal or civil proceeding brought under a statute may challenge its constitutionality in the trial court and appeal from an adverse decision...."]), the constitutional validity of an injunction which is the basis for a criminal contempt judgment must be appealable as well.

D. The People's Claims.

(5) The People cite Signal Oil etc. Co. v. Ashland Oil Co. (1958) 49 Cal.2d 764 [322 P.2d 1] (Signal Oil), for the proposition that "`[a]n injunction duly issuing out of a court of general jurisdiction with equity powers'" must be obeyed, even if erroneous, so long as the issuing court had subject *823 matter and personal jurisdiction. (Id. at p. 776, fn. 6.) An erroneous order, however, is not necessarily an order in excess of the issuing court's jurisdiction, as an order that is unconstitutional on its face would be. We acknowledged in Berry that Signal Oil held that an injunctive order enforcing an invalid contract, the invalidity of which is not apparent on its face, is not an injunction issued "in excess of jurisdiction." (Berry, supra, 68 Cal.2d at p. 148.) But we also explained in Berry the overriding principle that an order unconstitutional on its face is in excess of jurisdiction and cannot sustain a contempt judgment. (Ibid.)
Further, the People's reliance on the language quoted from Signal Oil, supra, 49 Cal.2d 764, seems inconsistent with their concession that an unconstitutional order may be challenged in a contempt proceeding, albeit, according to the People, only in the Court of Appeal or this court. To the extent the People claim, despite their concession, that no such challenge is permitted as long as the issuing court had subject matter and personal jurisdiction, we reject the argument. As we have seen, this argument was explicitly rejected in Berry, as follows: "In this state it is clearly the law that the violation of an order in excess of the jurisdiction of the issuing court cannot produce a valid judgment of contempt [citations], and that the `jurisdiction' in question extends beyond mere subject matter or personal jurisdiction to ... `any acts which exceed the defined power of a court in any instance, whether that power be defined by constitutional provision, express statutory declaration, or rules developed by the courts and followed under the doctrine of stare decisis. ...'" (Berry, supra, 68 Cal.2d at p. 147, first italics added; see also Fortenbury v. Superior Court, supra, 16 Cal.2d at pp. 407-408, 410.) No reason is given for reconsidering this conclusion here.
The People also urge policy grounds in support of their claim that no collateral attack on a superior court's injunctive order should be permitted except by way of extraordinary writ in the Court of Appeal or this court. They point out that the purpose of the contempt charge is to "`enable the courts to vindicate their authority and maintain the dignity and respect due to them.'" (In re McKinney (1968) 70 Cal.2d 8, 12 [73 Cal. Rptr. 580, 447 P.2d 972].) This argument has been accepted as an overriding consideration in jurisdictions that have adopted the collateral bar rule,[5] but, as explained above, California has rejected that rule. Nor do we see how it serves the stated purpose of vindicating the power of the court issuing the injunction to permit a collateral attack in the Court of Appeal, but not in the trial court. A total bar on collateral attacks would serve that purpose by requiring conformance with and punishing violation of even invalid orders. But as long as *824 this state acknowledges that an unconstitutional order cannot give rise to a valid contempt judgment  a premise the People apparently do not dispute  a person subject to such an injunctive order will be able to violate the order and raise the invalidity of the order as a defense, whether the claim is made in the trial court or by way of extraordinary writ.
The People also argue that to permit a collateral attack in the trial court or appellate department adversely affects those persons or interests that were to be protected by the injunctive order  here, the interest of local residents in avoiding imminent harm to their peaceful enjoyment of their homes and neighborhood. Of course, these third parties have no protectable interest in imposing unconstitutional restraints on defendant's conduct. And again, unless collateral attacks are barred altogether, the interest asserted by the People cannot be served.
Next, the People argue the trial court is ill suited to entertain a challenge to the validity of an injunction issued by another court, because it does not have the facts giving rise to the injunctive order before it, nor could it consider such facts in the context of a demurrer to the complaint. This claim is of little weight, because defendant primarily sought to attack the injunction on its face, a claim that requires, and indeed permits, no factual determination. (Tobe v. City of Santa Ana (1995) 9 Cal.4th 1069, 1091-1092 [40 Cal. Rptr.2d 402, 892 P.2d 1145].)
The People argue the trial court should not entertain collateral attacks on injunctive orders, because of the danger of piecemeal derogation of superior court orders resulting in judgments without precedential value. Permitting a collateral attack only in the Court of Appeal, the argument continues, would at least produce an opinion binding on all parties involved in the litigation over the injunction.
This is, indeed, a substantial concern, yet it is one overbalanced by the need to protect the individual's interest in being free from the coercive effects of unconstitutional orders. In Berry itself, we acknowledged the authority of the municipal court, by sustaining a demurrer, to prevent trial on a charge of violation of an invalid order. (Berry, supra, 68 Cal.2d at p. 146.) Such an order would have no precedential value. Nevertheless, as we established in Berry, and as the very wording of section 166 makes clear, in this state, the interest of the individual in avoiding the coercive effect of void injunctive orders is more substantial than the interest of society in vindicating a court's power by maintaining deference even to void orders through the contempt power.
Finally, we observe that the Court of Appeal ordinarily is not involved in reviewing misdemeanor proceedings, because appellate jurisdiction over *825 misdemeanor judgments rests with the appellate department of the superior court, with further review only by a discretionary transfer under rule 62(a) of the California Rules of Court. We are not inclined to increase the role of the Courts of Appeal and this court in reviewing misdemeanor convictions in the manner suggested by the People, when the state Constitution and the Legislature have assigned that function primarily to the superior courts.

III. CONCLUSION
We conclude the judgment of the Court of Appeal should be reversed, as the municipal court and the appellate department of the superior court had authority to entertain defendant's challenge to the validity of the superior court injunctive order that was the basis of the charges of contempt.
Because of this conclusion, we need not address the Court of Appeal's concern with avoiding a violation of equal protection with respect to the right of appeal. No need arises, accordingly, to vest the superior court with original jurisdiction over misdemeanor cases, and we do not consider the parties' arguments relating to this point. Nor do we consider the People's argument that we should determine the validity of the injunction. Neither party petitioned for review on this ground. (California Rules of Court, rule 29.3.)
The judgment of the Court of Appeal is reversed, and the matter remanded to the Court of Appeal for further proceedings not inconsistent with this opinion.
Mosk, J., Kennard, J., Arabian, J., Baxter, J., George, J., and Werdegar, J., concurred.
NOTES
[1]  In their petitions for review, the parties did not challenge the order of the Court of Appeal limiting the issues, and we therefore do not consider its propriety. (See, e.g., People v. Dupuis (1992) 7 Cal. App.4th 696, 700 [8 Cal. Rptr.2d 923] [concluding Court of Appeal has power to limit issues when it transfers cause to itself under rule 62(a) of the California Rules of Court].)
[2]  The constitutional provision is given effect by section 1466, which provides, in pertinent part, that "[a]n appeal may be taken from a judgment or order of an inferior court, in an infraction or misdemeanor case, to the superior court of the county in which the inferior court is located...." (§ 1466, subd. (a).)
[3]  Defendant concedes as much in this court.
[4]  See, e.g., Walker v. City of Birmingham (1967) 388 U.S. 307 [18 L.Ed.2d 1210, 87 S.Ct. 1824] (following so-called collateral bar rule, with certain exceptions); Ex parte Purvis (Ala. 1980) 382 So.2d 512, 514-515 (same); Cologne v. Westfarms Assocs. (1985) 197 Conn. 141 [496 A.2d 476, 481] (same); Dade County Classroom Teachers' Ass'n v. Rubin (Fla. 1970) 238 So.2d 284, 288 (same); Dept. of Rev. v. Universal Foods Corp. (1993) 318 Or. 78 [862 P.2d 1288, 1291-1292] (appeal from contempt adjudication may not collaterally attack underlying order, with certain exceptions); but see Wood v. Goodson (1972) 253 Ark. 196 [485 S.W.2d 213, 217] (recognizing collateral attack on void order); Phoenix Newpapers, Inc. v. Superior Court (1966) 101 Ark. 257 [418 P.2d 594, 596] (unconstitutional order is void and may be collaterally attacked); Ex parte Tucci (Tex. 1993) 859 S.W.2d 1, 2 (rejecting collateral bar rule); State ex rel. Superior Ct. of Snohomish Co. v. Sperry (1971) 79 Wn.2d 69 [483 P.2d 608, 611] (noting criticism of collateral bar rule and rejecting it as to orders void on their face).
[5]  See, e.g., Walker v. City of Birmingham, supra, 388 U.S. at page 321 [18 L.Ed.2d at page 1220]; United Elec. Workers v. 163 Pleasant Street Corp. (1st Cir.1992) 960 F.2d 1080, 1098; Ex parte Purvis, supra, 382 So.2d at page 515.
