Gregory James Eddins is currently in the custody of the Alabama Department of Corrections (“the DOC”), serving a 30-year sentence after pleading guilty to murder in October 2004. In January 2014, Eddins filed a form “Petition for Relief from Conviction or Sentence,” purportedly pursuant to Rule 32, Ala. R.Crim. P. In his verified petition, Eddins alleged that in September 2010, while he was incarcerated, laboratory tests indicated that he has diabetes. He also alleges that annual laboratory tests performed since 2010 support his claim that he is diabetic. Nonetheless, Eddins says, he is not being treated for diabetes, and, thus, he asserts, he runs the risk of going blind, losing a limb, going into a diabetic coma, or dying. Among the relief Eddins requested in his petition is an order directing the State of Alabama— presumably the DOC — to provide him with necessary or appropriate medical care to treat his diabetes. In other words, Ed-dins’s action is actually a civil action alleging that the State has acted with deliberate indifference to his medical needs.
On March 27, 2014, the trial court dismissed Eddins’s petition on the ground that it failed to state a claim and failed to raise any material issues. Specifically, the trial court stated that the remedy Eddins sought, i.e., an order requiring the State to provide him with necessary or appropriate medical care, “is not a remedy available through a Rule 32[, Ala. R.Crim. P.,] petition.” 1 Because the petition was dismissed, the trial court added, Eddins’s motions requesting that the trial court issue subpoenas for medical records and testimony of medical personnel were denied.2
*20Eddins appealed to the Alabama Court of Criminal Appeals, which transferred the appeal to this court on June 19, 2014. According to the order of the Court of Criminal Appeals transferring the appeal, the claim alleged in Eddins’s petition “challenged the conditions of his confinement” and was civil in nature and the petition sought injunctive relief. Accordingly, the Court of Criminal Appeals determined that it did not have jurisdiction over the appeal.
Eddins contends that the trial court erred in summarily dismissing his petition. Although it is not a model of clarity, the brief Eddins submitted on appeal appears to argue that the State improperly withheld medical treatment in violation of his rights under the Eighth Amendment to the United States Constitution to be free of cruel and unusual punishment. Among other relief Eddins seeks on appeal, Eddins requests that this court order medical testing or proper treatment for what he says is his diabetic condition.
It has long been the law that nomenclature is not the determining factor regarding the nature of a party’s pleadings or motions. In Assurant, Inc. v. Mitchell, 26 So.3d 1171, 1175 (Ala.2009), our supreme court wrote:
“The substance of [a plaintiffj’s complaint controls in determining the claims alleged therein.
“ ‘The substance of the plaintiffs allegations control, not the effort given by the plaintiff to style the claims throughout litigation. Bailey v. Faulkner, 940 So.2d 247, 253 (Ala.2006) (“Faulkner places great reliance on the fact that he has been careful to style his claims throughout this litigation as negligence and wantonness claims, rather than as an alienation-of-affections claim. However, ‘[t]his Court has always looked to substance over form.’ Southern Sash Sales & Supply Co. v. Wiley, 631 So.2d 968, 971 (Ala.1994).” (footnote omitted)).’
“Elizabeth Homes [, L.L.C. v. Cato ], 968 So.2d [1,] 8 [ (Ala.2007) ]. Further, ‘a plaintiff is in control of his or her complaint, [and] we [therefore] accept [the plaintiffs] allegations on their face.’ National Auction Group, Inc. v. Hammett, 854 So.2d 65, 70 (Ala.2003).”
See also Underwood v. Alabama State Bd. of Educ., 39 So.3d 120, 126 (Ala.2009) (same).
Although Eddins’s petition was written on a form intended for inmates to use in seeking Rule 32 relief from their convictions or sentences, the substance of the petition clearly alleges that the State improperly and intentionally denied him medical treatment. The trial court recognized the nature of Eddins’s claim in its judgment of dismissal, in which it stated that, “[i]n his present Rule 32 petition Eddins complains that the medical treatment given him by the State is either inadequate or improper.” Based on the authority of Assurant and Underwood, the trial court should have treated Eddins’s petition according to its substance rather than its caption; that is to say, it should have treated Eddins’s petition as a complaint alleging deliberate indifference to Eddins’s medical care. Assurant, supra (and cases cited therein).
In reviewing whether the trial court properly dismissed Eddins’s action, this court applies the following standard:
“In Crosslin v. Health Care Authority of Huntsville, 5 So.3d 1193, 1195 (Ala.2008), our supreme court stated:
*21‘“In considering whether a complaint is sufficient to withstand a motion to dismiss under Rule 12(b)(6), Ala. R. Civ. P., a court “must accept the allegations of the complaint as true.” Creola Land Dev., Inc. v. Bentbrooke Housing, L.L.C., 828 So.2d 285, 288 (Ala.2002) (emphasis omitted). “ ‘The appropriate standard of review under Rule 12(b)(6)[, Ala. R. Civ. P.,] is whether, when the allegations of the complaint are viewed most strongly in the pleader’s favor, it appears that the pleader could prove any set of circumstances that would entitle [it] to relief.’ ” Smith v. National Sec. Ins. Co., 860 So.2d 343, 345 (Ala.2003) (quoting Nance v. Matthews, 622 So.2d 297, 299 (Ala.1993)). In determining whether this is true, a court considers only whether the plaintiff may possibly prevail, not whether the plaintiff will ultimately prevail. Id. Put another way, “ ‘a Rule 12(b)(6) dismissal is proper only when it appears beyond doubt that the plaintiff can prove no set of facts in support of the claim that would entitle the plaintiff to relief.’ ” Id. (emphasis added).’ ”
Murray v. Prison Health Sens., Inc., 112 So.3d 1103, 1106 (Ala.Civ.App.2012).
“ ‘An inmate in a state penal institution has a constitutional right to adequate medical treatment. Estelle v. Gamble, 429 U.S. 97, 97 S.Ct. 285, 50 L.Ed.2d 251 (1976); Fountain v. State, 648 So.2d 591 (Ala.Civ.App.1994). This court has further held that “[a]n evidentiary hearing is warranted in order for the trial court to determine whether an inmate in a state penal institution is receiving adequate medical attention.” Fountain, 648 So.2d at 592 (citations omitted).’ “Perry [ v. State Dep’t of Corr.,] 694 So.2d [24,] 25 [ (Ala.Civ.App.1997) ].”
Crouch v. Allen, 76 So.3d 264, 266 (Ala.Civ.App.2011); Murray, 112 So.3d at 1106 (same).
To the extent that Eddins’s petition sought an order directing the State to provide him with adequate medical testing and treatment for his alleged diabetic condition, there is no question that Eddins would be entitled to the relief he sought if he is able to make the proper showing of proof. In other words, Eddins has stated a claim for which relief can be granted. Accordingly, the trial court erred in dismissing the action.
In reaching this conclusion, this court is not expressing an opinion as to the substantive merits of Eddins’s claim. We merely hold that, at this stage of the litigation, Eddins has alleged a set of circumstances that, if proved, would entitle him to the injunctive relief he seeks. We note that such relief would not affect Eddins’s conviction or sentence.
For the reasons set forth above, the judgment is reversed and the cause is remanded to the trial court for further proceedings.
Eddins’s motion to strike the State of Alabama’s brief on appeal is denied.
REVERSED AND REMANDED.
All the judges concur.. Rule 32, Ala. R.Crim. P., provides a mechanism by which a person convicted of a criminal offense pan institute a proceeding to seek postconviction relief from his or her conviction and/or sentence for certain reasons enumerated in the rule.
. In the judgment dismissing Eddins’s action, the trial court also stated: "Circuit Court of Madison County has no authority to compel the State to provide medical care for an inmate confined to Donaldson Correctional Facility.” We take judicial notice that Donaldson Correctional Facility is in Jefferson County. To the extent that the trial court’s statement contemplates that venue may not be proper in Madison County, we note that our review of the record indicates that venue was not raised as an issue in the trial court. The issue of venue may be waived. Rule 12(h)(1), Ala. R. Civ. P.; see also Ex parte American Res. Ins. Co., 58 So.3d 118, 121 n. 2 (Ala.2010) ("Restoration Coatings did not argue to the trial court that Mobile County was an improper venue under § 6-3-7(a), Ala.Code 1975. Thus, any such argument has been waived.”). Moreover, we note that, pursuant to Rule 82(d), Ala. R. Civ. P., if venue is in fact improper in Madison County, then "the court, on timely motion of any defendant, shall transfer the action to the court in which the action' might have been properly filed and the case shall proceed as though originally filed therein.” As mentioned, the issue of venue has not been raised *20in the trial court, and this court expresses no opinion as to where proper venue lies.