Plaintiffs John Call and Clark Jenkins, subdividers, brought this action in which they challenge the validity of an ordinance adopted by the defendant City which requires that subdividers dedicate 7 percent of the land to the city, or pay the equivalent of that value in cash, to be used for flood control and/or parks and recreation facilities. The district court upheld the validity of the ordinance and denied plaintiffs’ request for injunctive relief and damages. The latter appeal.
Plaintiffs contend that the ordinance is invalid because: (1) it is not within the City’s granted powers; (2) the land or the money required is not for the benefit of the subdivision, but rather the City as a whole; (3) that the City is attempting to exercise the power of eminent domain without following the requirements thereof and paying just compensation; and (4) it unlawfully imposes a tax.
On January 21, 1975, the City amended an existing ordinance (No. 33) relating to subdivisions by adding the following:
Section 9-C-8(a). In addition to all the other requirements prescribed under this ordinance the subdivider shall be required to dedicate seven percent (7.0%) of the land area of the proposed subdivision to the public use for the benefit and use of the citizens of the City of West Jordan . or in the alternative at the option of the governing body of the City, the City may accept the equivalent value of the land in cash if it deems advisable.
Sections 9-C-8(b) and (d) further provide that the money received “shall be used by the City for its flood control and/or parks and recreational facilities” and that if the City elects to receive money in lieu of land, payment shall be made “by the subdivider on or before final approval of the plat is given by the City Council.”
On May 2, 1977, the plaintiffs presented to the City two plats and maps for a proposed “Wescall subdivision” which, if approved, would result in the future development of 92 lots on about 30 acres of land located in the City. When the City exercised its option to accept money in lieu of land, plaintiff Clark Jenkins paid, under protest, $16,576.00, representing about 7 percent of the value of his land. The City Council then approved the subdivision and the plats were recorded. The City refused plaintiffs’ demand to refund the money and this action resulted.
In rejecting plaintiffs’ attack upon the ordinance, the trial court stated in its memorandum decision:
As it affects the plaintiffs, it is the opinion of this Court that the City of West Jordan, Utah’s ordinance 33, as amended January 21, 1975, is valid and constitutional. It is further the Court’s opinion that there has been no taking of the plaintiff’s property by the defendant without just compensation nor has the defendant levied an invalid tax upon the plaintiffs. See Secs. 10-9-1 through 10-9-30, U.C.A. 1953. [Citing cases.]
The Authority of the City
It is not questioned that cities have no inherent sovereign power, but only those granted by the legislature.1 But it must be realized that it is impractical for statutes to spell out to the last detail all of the things city governments must do to perform the *219functions imposed upon them by law. This Court has in numerous cases recognized this and has held that cities have those powers which are expressly granted and also those necessarily implied to carry out such responsibilities.2
There are a series of statutes through which the City derives its authority to enact ordinances of the character here in question. Sec. 10-8-84, U.C.A. 1953, grants to cities the authority and the duty
. to preserve the health, safety and good order of the city and its inhabitants.
This idea is carried forward and echoed in Section 10-9-1, U.C.A. 1953, which provides that:
For the purpose of promoting health, safety, morals and the general welfare of the community the legislative body of cities and towns is empowered to regulate and restrict . . . the location and use of buildings, structures and land for trade, industry, residence or other purposes.
Further dealing with that subject and more specific as to the establishment of parks, Section 10-9-3 states that such regulations
shall be made in accordance with a comprehensive plan designed to . facilitate adequate provision for transportation, water, sewage, schools, parks and other public requirements.
The Municipal Planning Enabling Act3 empowers a city to have a planning commission which may “adopt and certify to the legislative body, a master plan for the physical development of the municipality.” 4
Section 10-9-22 states that the planning commission “shall have such powers as may be necessary to enable it to perform its functions and promote municipal planning.”
Significantly, Section 10-9-25 then provides:
In exercising the powers granted to it by the act, the planning commission shall prepare regulations governing the subdivision of land within the municipality. A public hearing thereon shall be held by the legislative body, after which the legislative body may adopt said regulations for the municipality.
[all emphasis herein added.]
If the above statutes are viewed together, and in accordance with their intent and purpose, as they should be, it seems plain enough that the ordinance in question is within the scope of authority and responsibility of the city government in the promotion of the “health, safety, morals and general welfare” of the community.5
Just how essential and desirable it is that cities have such authority in planning their growth is brought into sharp focus by reflecting, on the one hand, upon the conditions in the slum and ghetto areas of various cities, where there are none, or inadequate, parks and playgrounds and, on the other, upon the enrichment of life which has been conferred on other cities where there are parks, plazas, recreational and cultural areas (some of which are very famous) for the use of the public.
In modern times of ever-increasing population and congestion, real estate developers buy land at high prices. From the combined pressures of competition and desire for gain, they often squeeze every lot they can into some labyrinthian plan, with only the barest minimum for tortious and circuitous streets, without any arterial ways through such subdivisions, and with little or no provision for parks, recreation areas, or even for reasonable “elbow room.” The need for some general planning and control is apparent, and makes manifest the wisdom underlying the delegation of powers to the cities, as is done in the statutes above referred to.
As undeveloped land is improved, it is also important that some provision for flood control be made. To the extent that the *220establishment of subdivisions increases the need for flood control measures or recreational facilities, it is both fair and essential that subdividers be required to contribute to the costs of providing those facilities.
Lack of Benefit to the Subdivision
In their point No. (2), the plaintiffs attack the ordinance on the ground that the land dedicated (or the money in lieu thereof) is not to be used solely and exclusively for the benefit of the created subdivision. They point to the provision that the land is received “for the benefit and use of the citizens of the City of West Jordan” and the money is used for “its [West Jordan’s] flood control and/or parks and recreation facilities.”
We agree that the dedication should have some reasonable relationship to the needs created by the subdivision.6 But in the planning for the expansion of a city, it is obvious that no particular percentage of each subdivision, or of each lot, could be used as a park or playground in that particular subdivision; and likewise, that it could not be so used for flood control. But it is so plain as to hardly require expression that if the purpose of the ordinance is properly carried out, it will redound to the benefit of the subdivision as well as to the general welfare of the whole community. The fact that it does so, rather than solely benefiting the individual subdivision, does not impair the validity of the ordinance.7
These observations are also pertinent: Although the money which was collected from the plaintiffs in this case was deposited in the City’s general fund, it should not be assumed that the money thus becomes usable for other purposes by the City and is of no special benefit to the area sought to be subdivided. On the contrary, that it will be used for its stated purpose is assured, first, by the integrity and good faith of the public officials charged with that responsibility; and second, by the fact that the recognized principle is that if money is collected from the public for a specific purpose, it becomes a trust fund committed to the carrying out of that purpose.8
The Eminent Domain Issue
There is an obvious fallacy in the plaintiffs’ argument that the City has not followed the proper procedure for taking plaintiffs’ property under eminent domain. This is not a proceeding initiated by the City to acquire property.9 It has indicated no desire to compel the plaintiff to subdivide their property, nor to dedicate any part of it. The plaintiffs are the moving parties, and as a prerequisite for permitting the creation of the subdivision, the City, under the powers conferred upon it as herein-above discussed, can and does impose reasonable regulations.10
Invalidity as a Tax
Plaintiffs urge that the requirements of the ordinance in question are but a revenue-raising scheme for the purpose of meeting the financial needs of the City, and thus constitute an improper levy of a tax upon their property. This labeling is but an ex*221ercise in semantics which misconstrues the purpose of the ordinance to make another attack upon it. It has been adjudicated that such an ordinance, if reasonably designed and carried out for the purpose intended, is a proper form of planning for the good of the community, and is not such a prohibited tax.11
The question as to the percentage of the land in the subdivision (in this instance, 7 percent) to be committed to the public purpose is within the prerogative of the City Council to determine, and so long as it is within reasonable limits, so that it cannot be characterized as capricious or arbitrary, the courts will not interfere therewith.12
In harmony with what has been said above, it is our opinion that the ordinance under attack is within the scope of the powers granted to the City so that it can plan for the general good of the community as well as for the newly-created subdivisions.
We have decided the principal issue which was addressed by the parties in the district court, and on this appeal, as to the validity of the ordinance. However, we observe that in the averments of the affidavits, there are other matters which may need to be resolved on remand; and accordingly, it is deemed appropriate that we make some additional comments.13
There is no question, but that the ordinance should be applied fairly, and without favoritism or discrimination insofar as that can be accomplished. In view of the averment in plaintiffs’ affidavit that that principle has been violated, the trial court should be concerned with examination into and resolution of any legitimate issue raised thereon.
In his affidavit, plaintiff Clark Jenkins averred that he not only paid the $16,-576 (assumed to be 7 percent of the value of the subdivision, $248,000) but was also required to dedicate .028 acres valued at $1,500; and to expend about $19,000 in construction of a storm sewer (which plaintiff urges is flood control) before the City would approve the subdivision. He asserts that these amounts are in excess of the 7 percent required by the ordinance. The City’s affidavit states that it received the $16,576, but says nothing about receiving the other amounts just referred to. It is, of course, essential that the amount the City exacts pursuant to the ordinance is not more than the 7 percent of value of plaintiffs’ property it prescribes.
Our final observation is on plaintiffs’ ur-gence that the $19,000 they expended in constructing a storm sewer should be credited upon their obligation under the ordinance. From what has been said in this decision, it should be sufficiently plain that the 7 percent exacted pursuant to the ordinance is for the general purpose of parks, recreation facilities and flood control, and is to be so administered and expended by the city government for that purpose; and that it is not necessarily to be used solely for the plaintiffs’ subdivision or any other particular one. This does not in any way prevent the City from imposing other reasonable conditions upon the approval of a subdivision and proposed construction therein, including requiring a storm sewer if the conditions are such that it is needed in that subdivision for the protection of future residents thereof or other residents of the City. We therefore do not disagree with the City’s requirement of the storm sewer, nor with its refusal to credit the plaintiff with the cost thereof on its 7 percent required by the ordinance.
The decision of the trial court is affirmed and the case is remanded for further pro*222ceedings consistent with this opinion. No costs awarded.
HALL, J., concurs.. Johnson v. Sandy City Corp., 28 Utah 2d 22, 497 P.2d 644 (1972).
. See Salt Lake City v. Revene, 101 Utah 504, 124 P.2d 537 (1942); and Butt v. Salt Lake City Corp., Utah, 550 P.2d 202 (1976).
. 10-9-19 et seq., U.C.A. 1953.
. 10-9-20, U.C.A. 1953.
. Language from Sec. 10-9-1, U.C.A. 1953.
. See statements in Aunt Hack Ridge Estates, Inc. v. Planning Commission of Danbury, 27 Conn.Sup. 74, 230 A.2d 45 (1967); Krughoff v. City of Naperville, 68 Ill.2d 352, 12 Ill.Dec. 185, 369 N.E.2d 892 (1977); Home Builders Ass’n v. City of Kansas City, Mo., 555 S.W.2d 832 (1977).
. Ayres v. City Council, 34 Cal.2d 31, 207 P.2d 1 (1949); Associated Home Builders, Inc. v. City of Walnut Creek, 4 Cal.3d 633, 94 Cal. Rptr. 630, 484 P.2d 606 (1971).
. 15 McQuillin, Municipal Corporations, Sec. 39.45 states that: “Special funds are often created . . . for a particular purpose, and in such case the general rule is that they cannot be used for any other purpose” and that “. . .a fund raised by a municipality for a special purpose is a trust fund, and equity will, in a proper case, interfere to prevent its diversion.” (Citing cases.)
. See Ayres v. City Council, supra, note 7; Petterson v. City of Naperville, 9 Ill.2d 233, 137 N.E.2d 371 (1956).
. Billings Properties, Inc. v. Yellowstone County, 144 Mont. 25, 394 P.2d 182, 187 (1964); City of Albuquerque v. Chapman, 77 N.M. 86, 419 P.2d 460 (1966); Mid-Continent Builders, Inc. v. Midwest City, Okl., 539 P.2d 1377 (1975).
. Petterson v. City of Naperville, supra, note 9; Jenad v. Village of Scarsdale, 18 N.Y.2d 78, 271 N.Y.S.2d 955, 218 N.E.2d 673 (1966).
. For an excellent discussion of the various constitutional challenges that have been made regarding subdivision legislation, see Associated Home Builders, Inc. v. City of Walnut Creek, supra, note 7, and authorities therein cited.
.See Rule 76(a), U.R.C.P.; LeGrand Johnson Corp. v. Peterson, 18 Utah 2d 260, 420 P.2d 615 (1966).