
773 N.E.2d 188 (2002)
332 Ill. App.3d 640
265 Ill.Dec. 826
In re C.L.P., a Minor (The People of the State of Illinois, Petitioner-Appellee,
v.
C.L.P., Respondent-Appellant).
No. 2-01-0326.
Appellate Court of Illinois, Second District.
July 10, 2002.
For C.L.P., Appellant: G. Joseph Weller Deputy Defender, Kim M. DeWitt, Paul J. Glaser, Office of the State Appellate Defender, Elgin, IL.
For People of the State of Illinois, Appellee: Honorable Paul A. Logli, Winnebago County State's Attorney, Rockford, IL, Martin P. Moltz Deputy Director, Peggy F.J. Bradford, State's Attorneys Appellate Prosecutor, Elgin, IL.
JUSTICE CALLUM delivered the opinion of the Court:
The minor respondent, C.L.P. (the minor), born June 10, 1986, appeals from a final dispositional order of the circuit court that committed him to the Department of Corrections, Juvenile Division (DOC), for an indeterminate term. The minor contends that the dispositional order violated section 5-710(7) of the Juvenile Court Act of 1987 (Act) (705 ILCS 405/5-710(7) (West *189 2000)) because, as written, the order would allow him to remain committed to the DOC for a period greater than the period for which an adult could be sentenced for the same act. The minor asserts that he is therefore entitled to have the dispositional order vacated and the cause remanded for the entry of a new dispositional order that complies with section 5-710(7). The minor also asserts that the new order should include credit for the time that he served in custody prior to the disposition. For the reasons that follow, we modify the dispositional order so that it complies with section 5 710(7) and otherwise affirm.
We recite the facts only to the extent necessary for an understanding of the issues presented. On January 24, 2000, the State filed a petition alleging that the minor was delinquent. As amended, the petition alleged that the minor committed aggravated battery (720 ILCS 5/12-4(b)(3) (West 2000)), aggravated assault (720 ILCS 5/12-2(a)(3) (West 2000)), and two counts of disorderly conduct (720 ILCS 5/26-1(a)(1) (West 2000)). All of the offenses, except the aggravated assault and one of the counts of disorderly conduct, were alleged to have occurred on different dates.
On March 13, 2000, pursuant to an agreement, the minor admitted to aggravated battery and to the two counts of disorderly conduct. The charge of aggravated assault was dismissed. The State also refrained from filing an additional assault charge. After accepting the minor's admissions, the trial court adjudicated him delinquent, made him a ward of the court, and placed him on probation for two years.
On April 21, 2000, and May 18, 2000, the State filed separate petitions to revoke the minor's probation. On August 31, 2000, after the minor admitted some of the allegations in the petitions, the trial court found that the minor had violated his probation. On September 1, 2000, the trial court committed the minor to the DOC and specified that the matter was set for review on December 5, 2000. On December 5, 2000, the trial court reinstated the minor's probation.
On January 2, 2001, the State filed a third petition to revoke the minor's probation. As amended, the third petition alleged that on January 1, 2001, the minor committed mob action and violated his probation by associating with other minors on probation. On February 5, 2001, the trial court conducted a hearing on the third petition and found that the minor had violated his probation.
On February 9, 2001, the trial court entered a dispositional order and mittimus. The order committed the minor to the DOC for the offenses for which he had been placed on probation, i.e., one count of aggravated battery and two counts of disorderly conduct. The trial court stated that the minor was committed to the DOC for an indeterminate period. This court subsequently allowed the minor to file a late notice of appeal.
On appeal, the minor first contends that he is entitled to have the dispositional order vacated and the cause remanded for the entry of a new dispositional order because the trial court erred in committing him to the DOC for an indeterminate period. The minor argues that the dispositional order violated section 5-710(7) of the Act. The minor construes section 5-710(7) as prohibiting the commitment of a juvenile offender to the DOC for a period greater than the maximun adult sentence for the same offense. The minor maintains that, as written, the dispositional order allows him to remain in the DOC until he attains the age of 21 years. In the minor's view, the dispositional order violated section 5-710(7) because, if he remained *190 in the DOC until he attained the age of 21 years, he would have been committed to the DOC for a period greater than the period for which an adult could be incarcerated for the same offense.
The State initially responds that the minor has waived this issue because he failed to raise it in the trial court. The minor counters that he may raise the issue at any time because the trial court's judgment was void to the extent that it violated section 5-710(7). We agree that the minor has framed an issue that could involve a void judgment, and a void judgment may be attacked at any time. People v. Wade, 116 Ill.2d 1, 5, 107 Ill.Dec. 63, 506 N.E.2d 954 (1987). We will therefore address the merits of the issue.
The minor raises an issue of statutory construction. The cardinal rule of statutory construction is to ascertain and give effect to the true intent of the legislature. In re D.D., 196 Ill.2d 405, 418, 256 Ill.Dec. 870, 752 N.E.2d 1112 (2001). The best indication of legislative intent is the language of the statute. In re D.L., 191 Ill.2d 1, 9, 245 Ill.Dec. 256, 727 N.E.2d 990 (2000). When the language of a statute is plain and unambiguous, a court may not read into it exceptions, limitations, or other conditions (D.D., 196 Ill.2d at 419), and there is no need to resort to other aids of construction (D.L., 191 Ill.2d at 9). We review de novo an issue of statutory construction. D.D., 196 Ill.2d at 418.
The minor relies on his construction of section 5-710(7) of the Act. Section 5-710(7) provides:
"In no event shall a guilty minor be committed to the Department of Corrections, Juvenile Division for a period of time in excess of that period for which an adult could be committed for the same act." 705 ILCS 405/5-710(7) (West 2000).
We agree with the minor that the plain language of section 5-710(7) prohibits the commitment of a juvenile offender to the DOC for a period greater than the maximum adult sentence for the same offense.
In this case, the minor admitted committing aggravated battery, a Class 3 felony (720 ILCS 5/12-4(e) (West 2000)), and two counts of disorderly conduct, a Class C misdemeanor (720 ILCS 5/26-1(b)(1) (West 2000)). The maximum period of incarceration for an adult who commits a Class 3 felony is five years. 730 ILCS 5/5-8-1(a)(6) (West 2000). The maximum period of incarceration for an adult who commits a Class C misdemeanor is 30 days. 730 ILCS 5/5-8-3(a)(3) (West 2000). Nothing in the record suggests that the trial court contemplated committing the minor to the DOC for a period that was analogous to consecutive sentences for an adult. Therefore, under section 5-710(7), the maximum period for which the trial court could commit the minor to the DOC was the maximum sentence that an adult could receive for aggravated battery, i.e., five years.
The dispositional order committed the minor to the DOC for an indeterminate period. This was in accordance with section 5-750(3) of the Act, which provides, in pertinent part:
"[T]he commitment of a delinquent to the Department of Corrections shall be for an indeterminate period which shall automatically terminate upon the delinquent attaining the age of 21 years unless the delinquent is sooner discharged from parole or custodianship is otherwise terminated in accordance with this Act or as otherwise provided for by law." 705 ILCS 405/5-750(3) (West 2000).
*191 Thus, under the plain language of section 5-750(3) of the Act, the indeterminate period for which the minor was committed to the DOC will not automatically terminate until he attains the age of 21 years.
The trial court entered the dispositional order on February 9, 2001. The minor will attain the age of 21 years on June 10, 2007. Therefore, if the minor remained committed to the DOC until he attained the age of 21 years, he would have been committed for a period greater than the 5-year maximum period for which an adult could be incarcerated for aggravated battery. If that occurred, the minor's period of commitment would violate section 5-710(7).
We recognize that section 5-750(3) of the Act provides for the termination of a juvenile offender's commitment to the DOC "in accordance with this Act or as otherwise provided for by law" (705 ILCS 405/5-750(3) (West 2000)). The State urges us to view this provision as a safeguard that will prevent a minor from being committed to the DOC longer than an adult who has committed the same offense. However, we believe that the better practice would be for a trial court to specify in a dispositional order that an indeterminate period of commitment to the DOC cannot exceed the maximum period of incarceration for an adult who committed the same offense. Such an order would comply with the clear legislative intent embodied in section 5-710(7) of the Act. See In re Jesus R., 326 Ill.App.3d 1070, 1072, 762 N.E.2d 717, 261 Ill.Dec. 148 (2002) (dispositional order allowing minor's commitment to DOC until minor's twenty-first birthday, a period longer than comparable adult offender could be incarcerated, violated section 5-710(7)).
For these reasons, we conclude that a trial court that enters a dispositional order committing a minor to the DOC for an indeterminate period must consider whether, if the minor remains in the DOC until he attains the age of 21 years, the commitment period would exceed the maximum sentence that an adult could receive for the same offense. If so, to comply with section 5-710(7), the dispositional order must include a limitation on the period of commitment so that it does not exceed the maximum period of incarceration for a comparable adult.
In this case, the trial court did not include in the dispositional order the maximum period for which the minor may be committed to the DOC for the offense of aggravated battery. Consequently, the order did not comply with section 5-710(7). The minor is therefore entitled to the modification of the dispositional order to include a limitation on the period of commitment to a period that is no greater than the maximum sentence for a comparable adult, i. e., five years.
The minor also requests that the maximum period that he may be committed to the DOC be reduced to reflect credit for the time he served in custody prior to the entry of the dispositional order that committed him to the DOC. This court has held that a juvenile delinquent who has been committed to the DOC for an indeterminate period is not entitled to credit for time served. In re J.J.M., 299 Ill.App.3d 327, 332, 233 Ill.Dec. 896, 701 N.E.2d 1170 (1998). We are aware that the legislature has significantly amended the Act (705 ILCS 405/1-1 et seq. (West 2000)) since this court's opinion in J.J.M. However, after reviewing the amended Act, we believe that J.J.M. remains sound. Accordingly, the minor is not entitled to credit for time served with respect to his commitment to the DOC for an indeterminate period.
*192 Based on the foregoing, we modify the dispositional order that committed the minor to the DOC for an indeterminate period to show that the maximum period that the minor may remain in the DOC is five years. In all other respects, the judgment of the circuit court of Winnebago County is affirmed.
Affirmed as modified.
GEIGER and O'MALLEY, JJ., concur.
