
61 Cal.App.2d 189 (1943)
A. L. BENSON, Appellant,
v.
CITY OF LONG BEACH et al., Respondents.
Civ. No. 13924. 
California Court of Appeals. Second Dist., Div. Three.  
Oct. 28, 1943.
 Cree & Brooks for Appellant.
 Irving M. Smith, City Attorney, Nowland M. Reid, Assistant City Attorney, and Frank C. Charvat, Deputy City Attorney, for Respondents.
 BISHOP, J. pro tem.
 Plaintiff was engaged in the business of an agent placing bets on race horses for those who fancied they could increase their fortunes in that way. His activities would have been considered unquestionably unlawful, because in violation of the provisions of section 337a of the Penal Code, but for the facts that the Legislature had given its stamp of approval to betting on horse races under the pari mutuel system (Stats. 1933, p. 2046; Deering's Gen. Laws, 1937, Act 3421) and had broadened the scope of its approval by an amendment made in 1935 (Stats. 1935, p. 1943). The provisions of the amendment are set forth in the case soon to be cited. We are not concerned with those provisions but only with these consequences: the attorney general interpreted them as authorizing such activities as plaintiff was engaged in; defendant's city prosecutor advised its city council that he concurred in the attorney general's interpretation; and the city council, city manager and city clerk accepted that interpretation. So it was that the city council adopted an amendatory ordinance, adding plaintiff's business to the list of businesses for which licenses were required under the city's general license ordinance, and fixing a fee of $3,000 as the tax for each license. Plaintiff applied for licenses to operate his business at two locations in the defendant city, paying $6,000 as required by the ordinance. On December 21, 1937, the licenses were issued by the city clerk and mailed to the plaintiff.
 Unknown to the city clerk, and also on December 21, 1937, an opinion was filed in the case of In re Goddard, (1937) 24 Cal.App.2d 132 [74 P.2d 818], the effect of which was that plaintiff's business remained an offense under section 337a of the Penal Code. On December 22, even before the mail *191 brought the plaintiff his licenses, defendant's chief of police notified the plaintiff that his business was forbidden by state law and if he continued in it he would be arrested and prosecuted. For some twenty days after the chief's warning the plaintiff continued to carry on his unlawful business (unlawful because of section 337a, Penal Code, not unlawful because conducted without the license required by the city ordinance) but he then desisted and in this action, begun in June, 1939, seeks to recover from the city the price paid for his licenses. The trial court entered its judgment that the plaintiff take nothing, and from this judgment the plaintiff has appealed. We have reached the conclusion that the judgment should be affirmed because we know of no legally sufficient ground upon which a judgment in favor of the plaintiff can be sustained, the sympathy that is naturally aroused for one who has, through no fault of his own, made a bad bargain, not constituting such a ground.
 [1a] The theories advanced by the plaintiff to support his case have a fundamental fallacy running through them. It first appears in paragraph III of his complaint, where he alleges that the defendant city enacted an ordinance "purporting to legalize the operation of ... horse-race betting agencies." Then in his opening brief he states one of the questions involved to be: "Where a business license fee has been paid to a city under a void ordinance containing criminal penalties which the city threatened to invoke if the fee were not paid, is the payor of such license fee entitled to a refund of the money paid by him therefor?" The concluding paragraph of plaintiff's closing brief opens with this sentence: "Fundamental justice requires that a license fee charged and collected under an invalid ordinance should under the circumstances found here be repaid." Nowhere does the plaintiff develop the idea that the ordinance is void or invalid, but reading between the lines of his argument we find the same thought as that found in paragraph III of his complaint; the ordinance is invalid, he believes, because it attempted to legalize that which the Legislature had made a public offense.
 An examination of the ordinance discloses no such futile effort on the part of the Long Beach City Council. [2] It is true, as revealed by the stipulation of facts which constituted the evidence in this case, that at the time the ordinance in question was adopted the city council was of the opinion, as *192 were the defendant's city prosecutor and the attorney general of the state, that the Legislature had removed the ban of the penal law from the business which the plaintiff was conducting. But while their opinion that plaintiff's business could be carried on lawfully may have caused them to adopt the ordinance, that opinion did not become a part of the ordinance. [1b] The ordinance in question had the simple effect of adding to the city's general licensing ordinance a new section providing that "Every person conducting, managing or carrying on the business in the city of Long Beach of an agent for the purpose of receiving, transmitting or paying bets on horse races shall pay a license tax of $3,000.00 (Three Thousand Dollars) per year." We have here no attempt on the part of the city to authorize the carrying on of the business of a betting agent. The ordinance did not attempt to provide that one who took out a license thereby had the legal right to conduct the business licensed, but only that he could not conduct it without obtaining a license and paying a tax for the privilege. Without delving deeply into the collateral subject, we note that it has been held proper to require a license tax of those practicing as attorneys (In re Galusha, (1921) 184 Cal. 697 [195 P. 406]); of those carrying on the business of physicians and surgeons (City of Redding v. Dozier, (1922) 56 Cal.App. 590, 592 [206 P. 465]); and of a corporation doing a banking business (Mendocino County v. Bank of Mendocino, (1890) 86 Cal. 255, 259 [24 P. 1002]). In each instance it was by state law declared to be unlawful for one to carry on the "business" required to be licensed for revenue, without first obtaining a state license. The licensing ordinances of the state subdivisions, (city in the first two cases, county in the third) were not interpreted as attempts to legalize the carrying on of the activities, for which local licenses were required, in lieu of or in the absence of the requisite state permits. Incidentally, the authority to license for revenue which had been exercised in these cases was in each instance limited, by the grant of authority, to activities which were lawful. No such limitation appears in section 33 of article IV of the Long Beach City Charter which enumerates among the powers of the city the power: "To license ... the carrying on of any and all professions, trades, callings, occupations and kinds of business, carried on within the limits of said city; and to fix the amount of license tax thereon. ..." [3] The legality of a license tax does not *193 depend on the legality of the business for which the tax is required. As stated in United States v. Constantine, (1935) 296 U.S. 287, 293 [56 S.Ct. 223, 80 L.Ed. 233, 238]: "The United States has the power to levy excises upon occupations, and to classify them for this purpose; and need look only to the fact of the exercise of the occupation or calling taxed, regardless of whether such exercise is permitted or prohibited by the laws of the United States or by those of a State. The burden of the tax may be imposed alike on the just and the unjust."
 [1c] Plaintiff's contention that the ordinance purported to legalize a business outlawed by the state statute is untenable not only for the reasons already advanced but also because of a limitation found within the ordinance itself. After declaring that a license tax had to be paid by every person carrying on the business "of an agent for the purpose of receiving, transmitting or paying bets on horse races" it added that for its purposes the term "agent" should mean and include "any person who, for another, transfers or transmits for a consideration bets or wagers to a legalized race track where such is permitted under the laws of this state."
 [4a] Much has been said, in the briefs before us, on the subject of the involuntary character of plaintiff's payment of the license tax. There is, of course, no contention, as there is no basis for one, that the city defrauded the plaintiff into taking out his licenses, or used any actual coercive measures. The payments were involuntary, it is claimed, because of the penal provisions of the licensing ordinance and because plaintiff's application for a license was made under a mutual mistake of law. As we view the matter we need not determine whether or not the payment was involuntary, for that is a material question only where the invalid nature of a tax gives rise to a cause of action for its return. The tax, however, has not been made to appear invalid.
 [5] Plaintiff's opening brief is silent on the point, suggested by the allegations of his complaint, that the fact that he and the city officials mutually entertained what proved to be a mistaken view of the law, could in some way afford him relief. That the situation was not one in which relief would be given because of a mutual mistake of law would seem to follow from Wingerter v. San Francisco, (1901) 134 Cal. 547, *194 548 [66 P. 730, 86 Am.St.Rep. 294] and Campbell v. Rainey, (1932) 127 Cal.App. 747, 750 [16 P.2d 310], in each of which this quotation from Cooley v. County of Calaveras, (1898) 121 Cal. 482, 486 [53 P. 1075], is made: "The understanding of the law prevailing at the time of the settlement of a contract, although erroneous, will govern, and the subsequent settlement of a question of law by judicial decision does not create such a mistake of law as courts will rectify." In his closing brief plaintiff acknowledges that his acquisition of the licenses was not a contractual transaction, which could be rescinded in the event of a mutual mistake of law. Rather he takes the position already indicated, that his mistake of law affected the nature of his payment, rendering it involuntary. [4b] A tax is not recoverable, we have already said, because its payment was involuntarily made; not only must the payment be involuntary but the tax must for some reason be invalid. The invalidity of the license tax which plaintiff paid not appearing, no reason appears why the city should be compelled to repay it.
 The judgment is affirmed.
 Shinn, Acting P. J., and Wood (Parker), J., concurred.
