
58 Cal.Rptr.3d 218 (2007)
149 Cal.App.4th 1530
CITY OF MONTE SERENO, Plaintiff and Respondent,
v.
Darla PADGETT, et. al., Defendants and Appellants.
No. H029631.
Court of Appeal of California, Sixth District.
April 23, 2007.
*219 McManis Faulkner & Morgan, James McManis, Michael Reedy and Christine Peek, San Jose, for Defendants and Appellants.
Logan & Powell, Kirsten M. Powell and Leigh F. Prince, for Plaintiff and Respondent.
ELIA, J.
The City of Monte Sereno ("City") sued defendants Darla and Joseph Padgett for abatement of a public nuisance and violations of the Monte Sereno Municipal Code (MSMC). The parties settled before trial, with an agreement that the action would be "deemed dismissed" upon defendants' compliance with the City's demands, and that the City could thereafter seek its attorney fees. The trial court awarded the City its fees based on two provisions of the MSMC. On appeal, defendants challenge the validity of these provisions. Defendants further contend that the City should not have received any award because they were prevented from complying with the City's demands, the City used the lawsuit to harass them and selectively enforce its ordinances, and the amount of the award was excessive. We agree with defendants that the MSMC provisions on which the City relied were not a proper basis for attorney fees. Accordingly, we must reverse the judgment.

Background
The dispute between the City and defendants arose from Darla Padgett's plans to improve defendants' property with new structures and remodeling of an existing structure. In March 1999 she obtained a site development permit (SDP), which included a landscaping plan. The following October she obtained a building permit covering construction, plumbing, mechanical, and electrical improvements. The building permit was to expire, however, if the work was abandoned for more than 180 days, or if defendants failed to arrange for a final inspection of the work within 180 days of completion.
During construction defendants removed a eucalyptus tree, contrary to the landscape plan. The City then imposed an additional "mitigation" condition on the *220 SDP: Defendants were required to plant six evergreen trees along the property line. They did not plant those trees at that time, however. According to Darla Padgett, defendants could not plant the trees because of pending utility easements and because the driveway had not been completed. She further stated that she could not complete the requirements of the building permit because of an existing injunction related to litigation initiated by her neighbors. As for the fence, Padgett expressed willingness to lower it "if the City could assure [her] that it would enforce the fence law equally." [1]
The City filed a suit in abatement in February 2003, alleging building code violations, violations of the MSMC, and public nuisance. In its first amended complaint in March 2004, the City specifically alleged that defendants' removal of the eucalyptus tree and their failure to plant the "Mitigation Trees" violated the SDP. The City further alleged that defendants had failed to schedule their final inspection as required by the applicable building code, resulting in expiration of their building permit. Finally, the City alleged that defendants had constructed and maintained a fence that exceeded the maximum height allowance under the MSMC. In addition to requesting an injunction and abatement, the City sought costs of suit, including "the attorney's fees and costs authorized pursuant to section 6.17.170 of the MSMC."
The parties settled the case on January 12, 2005, six days before the scheduled trial. The remedial terms of the settlement called for lowering of the fence to six feet, the planting of six trees, and an independent final inspection by January 18, 2005. If the final inspection produced "a sign-off, everything's approved," then the matter would be "deemed dismissed on that date, [January 18]."[2] The parties further agreed that the City had the right to file a request for costs, including attorney fees, but that defendants were entitled to oppose both entitlement to and amount of those fees. The City was claiming attorney fees of about $175,000.
On February 14, 2005 a "Notice of Dismissal" was filed, stating that the action was "deemed dismissed on February 11, 2005." The City filed a memorandum of costs on February 24 and a motion for costs and attorney fees on March 2, 2005. According to the City, attorney fees were recoverable under Code of Civil Procedure section 1033.5, subdivisions (a)(10)(B) and (a)(10)(C), because they were authorized under the MSMC, by sections 6.17.170 and 5.05.010. Defendants moved to strike or tax costs. The City eventually submitted a revised fee claim of $158,646.00.
On October 7, 2005, after receiving extensive written and oral argument from both parties, the trial court denied defendants' motion and granted the City's, awarding it attorney fees of $153,842.00. The court entered judgment on both motions on October 24, and on November 14, 2005, the City voluntarily dismissed the action.

Discussion
On appeal, defendants challenge both the City's entitlement to attorney fees and the amount awarded. They acknowledge *221 the general rule that attorney fees are permitted in a civil action when authorized by statute, contract, or law. (Code Civ. Proc., § 1033.5, subd. (a)(10).) A municipal ordinance is a law within the meaning of this provision. (City of Santa Paula v. Narula (2003) 114 Cal.App.4th 485, 492-493, 8 Cal.Rptr.3d 75; see also Segundo v. Rancho Mirage City (9th Cir. 1989) 873 F.2d 1277, 1278-1279.) Defendants contend, however, that MSMC section 6.17.170 conflicts with or is preempted by Government Code section 38773.5, subdivision (b) ("section 38773.5(b)"), which defines the procedures a city may establish for abating nuisances. They further argue that fees were not authorized under MSMC section 5.05.010 because that ordinance did not become effective until six days after the case was "deemed dismissed." Finally, defendants contend that the amount of the fee award was excessive in view of the City's litigation conduct and the result achieved.
As defendants observe, the first two issues are matters for this court's independent review, as they involve questions of law. (Cf. Wakefield v. Bohlin (2006) 145 Cal.App.4th 963, 52 Cal.Rptr.3d 400; MHC Financing Ltd. Partnership Two v. City of Santee (2005) 125 Cal. App.4th 1372, 1397, 23 Cal.Rptr.3d 622.) The third issue concerning the amount of the fee award addresses a discretionary ruling which may not be overturned unless it is clearly wrong. (Foundation for Taxpayer and Consumer Rights v. Garamendi (2005) 132 Cal.App.4th 1375, 1394, 34 Cal. Rptr.3d 368; Padilla v. McClellan (2001) 93 Cal.App.4th 1100, 1107, 113 Cal.Rptr.2d 680.)


1. MSMC Section 6.17.170

MSMC section 6.17.170 describes the penalties to which a Monte Sereno property owner may be subjected for maintaining a nuisance in the City. In addition to providing for imposition of a fine and imprisonment, the ordinance states: "[S]hould the City commence a civil or criminal proceeding to abate a public nuisance, the costs of abatement which may be recorded shall include all legal costs including reasonable attorneys' fees incurred by the City in commencing and pursuing civil or criminal remedies."
Defendants contend that this provision is invalid because it conflicts with section 38773.5(b), which requires an ordinance allowing attorney fees to permit their recovery by the "prevailing party, rather than limiting recovery of attorneys' fees to the city if it prevails." (Emphasis added.) The trial court agreed with the City that section 38773.5(b) was intended to apply specifically to "recovery of fees as a special assessment in connection with summary abatement administrative proceedings." In those procedures, the City and the court reasoned, reciprocity provides an essential procedural safeguard, whereas judicial proceedings already afford the property owner procedural and substantive protections. The court also agreed with the City that permitting a city alone to recover its fees furthered the public policy to encourage the pursuit of abatement actions by reducing the costs of such actions. (Cf. City of Santa Paula v. Narula, supra, 114 Cal.App.4th at p. 493, 8 Cal.Rptr.3d 75.)
We disagree with the City and trial court's construction of section 38773.5(b) limiting its application. It is true that Government Code section 38773 permits summary abatement of a nuisance at a property owner's expense. That statute also allows a city to make the expense of abatement a lien against the property as well as a personal obligation of the property owner, "in accordance with Section 38773.1 or 38773.5." But there is no indication *222 in section 38773.5 that it is, in effect, a subdivision of section 38773. Subdivision (a) of section 38773.5 allows abatement procedures as an alternative to the procedure established in section 38773.1, which permits liens on property as a means of collecting nuisance abatement costs. (§ 38773.5, subd. (a).) Section 38773.5(b) then provides for attorney fees as follows: "A city may, by ordinance, provide for the recovery of attorneys' fees in any action, administrative proceeding, or special proceeding to abate a nuisance. If the ordinance provides for the recovery of attorneys' fees, it shall provide for recovery of attorneys' fees by the prevailing party, rather than limiting recovery of attorneys' fees to the city if it prevails. The ordinance may limit recovery of attorneys' fees by the prevailing party to those individual actions or proceedings in which the city elects, at the initiation of that individual action or proceeding, to seek recovery of its own attorneys' fees. In no action, administrative proceeding, or special proceeding shall an award of attorneys' fees to a prevailing party exceed the amount of reasonable attorneys' fees incurred by the city in the action or proceeding."
In the plain language of its terms, the attorney fees provision applies to any action to abate a nuisance, not just a summary administrative or special proceeding. The statute does not impose reciprocity of fees on a city's ordinance as does Civil Code section 1717, but instead simply requires that the ordinance provide for recovery by the prevailing party and forbids the unilateral recovery by the city. The City's ordinance in this case therefore violates section 38773.5, and its application cannot be upheld.

2. MSMC Section 5.05.010
As an alternative basis for its decision, the court' applied MSMC section 5.05.010, which provided for attorney fees to the "prevailing party in any judicial action and/or administrative proceeding to abate a nuisance." By its terms, the ordinance took effect 30 days after its passage, February 17, 2005.[3] Notwithstanding the "deemed dismissed" date of February 11, 2005, the court ruled that MSMC section 5.05.010 could be applied here because the City had not yet "requested entry of dismissal or execution of a judgment of dismissal. Thus, the action is still pending in this Court." The court further determined that retroactive application of MSMC section 5.05.010 was permissible because it was a procedural enactment which did not create a new cause of action or deprive defendants of a defense. The court expressly found that "it was the reasonable legislative intent of the City to have the new ordinance applied to this and future actions."
We take no issue with the court's factual conclusion that the City intended to apply the new law to this case so that it could recover its attorney fees. That intent is immaterial, however, if imposition of the fees was unauthorized. The key question is whether the court's ruling amounts to a retroactive application of the ordinance and, if so, whether that application was legally permissible.
Our Supreme Court has described a retroactive law as "'"one [that] affects rights, obligations, acts, transactions and conditions which are performed or exist prior to the adoption of the statute."' [Citations.] Similarly, the United States Supreme Court has stated: `"[E]very statute, which takes away or impairs vested *223 rights acquired under existing laws, or creates a new obligation, imposes a new duty, or attaches a new disability, in respect to transactions or considerations already past, must be deemed retrospective."' (Landgraf v. USI Film Products (1994) 511 U.S. 244, 269, 114 S.Ct. 1483, 128 L.Ed.2d 229____) Phrased another way, a statute that operates to `increase a party's liability for past conduct' is retroactive. (Id. at p. 280, 114 S.Ct. 1483 ...; Evangelatos [v. Superior Court (1988) 44 Cal.3d 1188, 1206, 246 Cal.Rptr. 629, 753 P.2d 585].)" (Myers v. Philip Morris Companies, Inc. (2002) 28 Cal.4th 828, 839, 123 Cal.Rptr.2d 40, 50 P.3d 751.)
As the Supreme Court has repeatedly emphasized, a legislative enactment is presumed to operate prospectively and not retroactively unless a different intention is clearly expressed or implied from the legislative history or the context of the enactment. (Evangelatos v. Superior Court (1988) 44 Cal.3d 1188, 1207-1210, 246 Cal.Rptr. 629, 753 P.2d 585; Aetna Cas. & Surety Co. v. Ind. Acc. Com. (1947) 30 Cal.2d 388, 393, 182 P.2d 159; Californians For Disability Rights v. Mervyn's, LLC (2006) 39 Cal.4th 223, 230, 46 Cal. Rptr.3d 57, 138 P.3d 207.) In this case there can be no question that prospective application of the ordinance was intended; its plain language specified that it was to take effect 30 days later. As the new law changed the legal consequences of past conduct by imposing a new liability for that conduct, we conclude that its application here would be retroactive, contrary to the express intent of the ordinance itself.
The City argues that MSMC section 5.05.010 may be applied retroactively because it is strictly a procedural law that neither creates a new cause of action nor deprives defendants of a defense. The Supreme Court's disapproval of the artificial distinction between purely procedural and purely substantive laws addresses that contention. "In truth, the distinction relates not so much to the form of the statute as to its effects. If substantial changes are made, even in a statute which might ordinarily be classified as procedural, the operation on existing rights would be retroactive because the legal effects of past events would be changed, and the statute will be construed to operate only in futuro unless the legislative intent to the contrary clearly appears." (Aetna Cas. & Surety Co. v. Ind. Acc. Com., supra, 30 Cal.2d at p. 394, 182 P.2d 159; see also Western Security Bank v. Superior Court (1997) 15 Cal.4th 232, 244, fn. 4, 62 Cal. Rptr.2d 243, 933 P.2d 507.) The key consideration is "`the effect of a law on a party's rights and liabilities, not whether a procedural or substantive label best applies. Does the law "change[ ] the legal consequences of past conduct by imposing new or different liabilities based upon such conduct[?]" [Citation.] Does it "substantially affect[] existing rights and obligations[?]" [Citation.] If so, then application to a trial of preenactment conduct is forbidden, absent an express legislative intent to permit such retroactive application. If not, then application to a trial of preenactment conduct is permitted, because the application is prospective.'" (Californians For Disability Rights v. Mervyn's, LLC, supra, 39 Cal.4th at p. 231, 46 Cal. Rptr.3d 57, 138 P.3d 207.)
Thus, "[t]he substantive-procedural distinction does not prevail in California because both `procedural' and `substantive' statutes are subject to the presumption against retroactive effect." (Russell v. Superior Court (1986) 185 Cal.App.3d 810, 815, 230 Cal.Rptr. 102.) "Both types of statutes may affect past transactions and be governed by the presumption against retroactivity. The only exception which we can discern from the cases is a subcategory *224 of procedural statutes which can have no effect on substantive rights or liabilities, but which affect only modes of procedure to be followed in future proceedings. As Aetna pointed out, such statutes are not governed by the retroactivity presumption, but not because they are `procedural' but simply because they are not in fact retroactive. (30 Cal.2d at p. 394, 182 P.2d 159.) Aetna may thus be read as drawing the true distinction not between 'substantive' or `procedural' statutes, but between those affecting past transactions and those impacting only on future events." (Id. at p. 816, 230 Cal.Rptr. 102.)
Here, retroactive application of the ordinance to make attorney fees available would impose an "additional liability" on defendants and substantially change the legal rights and obligations of the parties as circumscribed by their settlement agreement.[4] (Aetna Cas. & Sur. Co. v. Ind. Acc. Com., supra, 30 Cal.2d at p. 395, 182 P.2d 159.) The City nevertheless relies on City of Sausalito v. County of Marin (1970) 12 Cal.App.3d 550, 90 Cal. Rptr. 843 and ARA Living Centers-Pacific, Inc. v. Superior Court (1993) 18 Cal. App.4th 1556, 23 Cal.Rptr.2d 224 in urging retroactive application of MSMC section 5.05.010. In ARA supra, 18 Cal.App.4th 1556, 23 Cal.Rptr.2d 224, a statutory amendment was applied retroactively to provide for attorney fees in elder-abuse cases. In City of Sausalito, supra, 12 Cal.App.3d 550, 90 Cal.Rptr. 843, the appellate court noted that a statute that is procedural in effect (rather than form) may be applied to "pending and future litigation even if the event underlying the cause of action therein occurred before the statute took effect." (Id. at p. 557, 90 Cal.Rptr. 843, italics added.) Neither case involved a dispute that had already been resolved by the time the law took effect.
The City maintains, however, that this action was still pending when MSMC section 5.05.010 became operative. The City points out that its request for dismissal and the clerk's entry of dismissal were not filed until November 14, 2005, nearly nine months after the effective date of the ordinance. Consequently, it argues, the action was subject to the new provision on February 17, 2005. We might accept this position but for the agreement between the parties that the action was dismissed for purposes of any request for attorney fees. The settlement and ensuing "Notice of Dismissal" did not limit the effect of the dismissal to amounts and dates the fees were incurred.[5] Defendants agreed that the City had the right to seek attorney fees, not that it was entitled to those fees under any existing law or any law then contemplated by the City Council. Defendants expressly reserved the right to dispute the City's claim, "both in terms of the City's entitlement to those costs as well as *225 the amount of the costs."[6]
Without any evidence of limitations on the scope and effect of the stipulated dismissal, we conclude that the parties' settlement was based on their understanding of the state and local law (namely, MSMC section 6.17.170) as it existed at the time the action was deemed by them to be "over." Their contractual expectations would be defeated by applying the new ordinance to the dispute already resolved by settlement. We cannot uphold the application of MSMC section 5.05.010 here.

Conclusion
The ordinance in effect at the time the City incurred its attorney fees in the abatement action was invalid, as it impermissibly conflicted with Government Code section 38773.5. The ordinance the City subsequently enacted was also not a proper basis for its attorney fees, because the case had been deemed dismissed for purposes of that very recovery. Because attorney fees were unavailable to the City in this case, the award cannot stand. Accordingly, it is unnecessary to decide whether the factual history of the underlying lawsuit justifies the appropriateness of the award and the reasonableness of the amount.

Disposition
The judgment awarding attorney fees is reversed. Costs on appeal are awarded to appellants.
WE CONCUR: RUSHING, P.J., and PREMO, J.
NOTES
[1]  Padgett complained that defendants had built a fence like that of a neighbor, but "the only ones the City sued ... were Joe and me."
[2]  If there was a "punch list" requiring another inspection, the dismissal would be deemed as of the final approval. However, if the City unreasonably refused to sign off on the' punch list, then the dismissal would be deemed as of the date the final approval should have been granted.
[3]  MSMC section 5.05.010 was passed by the City Council on January 18, 2005, which, defendants point out, was the day scheduled for trial in this action.
[4]  Defendants do not argue that retroactive application of the ordinance would amount to an unconstitutional impairment of contract; hence, we will not delve into that arena. (See U.S. Const., art. I, § 10, cl. 1; Cal. Const., art. I, § 9; Energy Reserves Group, Inc. v. Kansas Power and Light (1983) 459 U.S. 400, 411, 103 S.Ct. 697, 74 L.Ed.2d 569.)
[5]  During the January 12, 2005 hearing at which the settlement terms were recited, the court clarified that the "real" dismissal date was the date the formal dismissal would be entered, "so that we don't lose track of the case to make sure things are resolved." The "deemed dismissed" or, in the trial court's words, "fictitious dismissal" date, allowed the parties to "know it's over," and it allowed the attorney fees motion to "go forward": "that's the day from which we start counting your when you have to file your motion. And it's also the day that the dismissal is entered for purposes of the [attorney fees] motion." The parties' counsel agreed.
[6]  The City suggests that defendants cannot complain of surprise because they were aware of the attorney fees request throughout the litigation, and the ordinance was being considered "long before there was a settlement on the horizon." Defendants, however, are asserting invalidity, not surprise.
