
915 P.2d 359 (1996)
Michael C. WASHINGTON, Petitioner/Appellant,
v.
STATE ex rel. DEPARTMENT OF CORRECTIONS, et al., Respondents/Appellees.
No. 85295.
Supreme Court of Oklahoma.
April 16, 1996.
Michael C. Washington, McAlester, pro se.
Linda L. Samuel-Jaha, Assistant Attorney General, Oklahoma City, for Appellees.
*360 KAUGER, Vice Chief Justice:
The only issue presented on certiorari is whether the trial court erred when it dismissed the appellant's lawsuit pursuant to the appellees' motion to dismiss/motion for summary judgment without giving the appellant an opportunity to respond to the motion. We find that it did.

FACTS
This cause concerns a lawsuit brought by the appellant, Michael C. Washington, (Washington/appellant), an inmate at the Oklahoma State Penitentiary in McAlester, Oklahoma, against the appellees, the Department of Corrections and several prison officials (prison officials/appellees), pursuant to 42 U.S.C. § 1983 (1994).[1] In January of 1995, Washington filed a petition in the District Court of Pittsburg County, Oklahoma, seeking injunctive and monetary relief for alleged constitutional violations by various prison officials.[2]
The substance of Washington's claims are that: 1) he was subjected to unconstitutional strip-searches; 2) prison officials revised disciplinary procedures which resulted in an ex post facto violation; and 3) a number of prison officials and guards violated his civil rights through a defective disciplinary proceeding which deprived him of good-time credits and the possibility of parole. On February 23, 1995, the appellees filed a motion to dismiss/motion for summary judgment, arguing that Washington's cause should be dismissed under 12 O.S.1991 § 2012(B)(6) because he had failed to state a claim upon which relief could be granted.[3]
On March 2, 1995, the trial court dismissed Washington's lawsuit, finding that his *361 lawsuit was frivolous and totally without merit.[4] Apparently unaware of the trial court's dismissal, the appellant filed a motion for an enlargement of time on March 8, 1995, requesting that the trial court grant him an additional thirty days after March 5, 1995, to respond to the appellees' motion to dismiss/motion for summary judgment. The trial court, by a court minute which was filed with the county clerk on March 10, 1995, found that Washington's request for an extension of time was moot because his lawsuit had already been dismissed.
Washington appealed the March 2, 1995, dismissal order, arguing that the trial court erred in dismissing his cause without permitting him to respond to the appellees' motion to dismiss/motion for summary judgment. The Court of Appeals affirmed without specifically addressing the issue of whether the trial court erred when it dismissed the appellant's lawsuit pursuant to the appellees' motion without giving the appellant an opportunity to respond. We granted certiorari on February 27, 1996, to determine whether the trial court erred when it dismissed the appellant's lawsuit.[5]

TITLE 12 O.S.1991 § 2012 AND RULE 13, 12 O.S.1991, CH. 2 APP., RULES FOR THE DISTRICT COURTS, REQUIRE THAT THE APPELLANT BE GIVEN AN OPPORTUNITY TO RESPOND TO THE APPELLEES' MOTION UNDER THE FACTS PRESENTED.
On certiorari, Washington argues that the trial court erred when it dismissed his lawsuit without first giving him an opportunity to respond to the appellees' motion to dismiss/motion for summary judgment. The appellees' motion asserts that Washington's cause should either be dismissed because his amended petition failed to state a claim upon which relief could be granted or that they were entitled to summary judgment.
Our review of the trial court's dismissal for failure to state a claim upon which relief can be granted, involves a de novo consideration as to whether the petition is legally sufficient.[6] In considering the sufficiency of a petition, the accepted rule is that a petition should not be dismissed for failure to state a cause of action unless it appears beyond any doubt that the plaintiff cannot prove facts in support of the claim entitling relief.[7] However, 12 O.S.1991 § 2012, mandates that: 1) when a motion to dismiss for failure to state a claim upon which relief can be granted includes matters outside the pleadings and those matters are not excluded by the court, the motion shall be treated as one for summary judgment; and 2) all of the parties shall be given a reasonable opportunity to present all material made pertinent to such a motion by the rules for summary judgment.[8]
The prison officials filed a motion seeking dismissal for failure to state a claim or in the alternative, summary judgment in their favor. In support of the motion they attached a brief which included various evidentiary *362 materials which were outside of the pleadings and which cited legal authority in support of their position.[9] These matters were not excluded by the trial court.[10] Consequently, under 12 O.S.1991 § 2012, the summary judgment procedure must be used.[11]
Rule 13, 12 O.S.1991, Ch. 2 app., Rules for the District Courts, in clear and mandatory language requires that a party opposing a motion for summary judgment be allowed at least 15 days to respond to the motion and to provide evidentiary materials which would support a denial of the motion.[12] Instead, the trial court entered its order dismissing the appellant's cause seven days after the appellees' filed their motion. It is clear from Washington's motion for an extension of time that he intended to oppose the prison officials' motion. The trial court erred when it failed to give Washington a reasonable opportunity to respond as required by 12 O.S.1991 § 2012 and Rule 13, 12 O.S.1991, Ch. 2 app., Rules for the District Courts.[13]
Even assuming arguendo, that the trial court excluded all of the matters which were outside of the pleading, and that it considered the appellees' motion as one for dismissal, we find that the appellant's cause was dismissed prematurely because not all of his claims appear to be frivolous on their face or without merit.[14] Accordingly, the trial *363 court's order is reversed and the cause is remanded with directions to allow the appellant a reasonable opportunity in which to respond to the appellees' motion to dismiss/motion for summary judgment and to present proof of his allegations.

CONCLUSION
Title 12 O.S.1991 § 2012, mandates that: 1) when a motion to dismiss for failure to state a claim upon which relief can be granted includes matters outside the pleadings and those matters are not excluded by the court, the motion shall be treated as one for summary judgment; and 2) all parties shall be given a reasonable opportunity to present all material made pertinent to such a motion by the rules for summary judgment.[15] Rule 13, 12 O.S.1991, Ch. 2 app., Rules for the District Courts, in clear and mandatory language requires that a party opposing a motion for summary judgment be allowed at least 15 days to respond to the motion and to provide evidentiary materials which would support a denial of the motion.[16]
Because the appellees' motion included matters outside of the pleadings and these matters were considered by the trial court, the trial court erred when it dismissed the appellant's cause without allowing him the opportunity to respond to the appellees' motion. Even assuming arguendo, that the trial court excluded all of the matters which were outside the pleadings and considered the appellees' motion as one for dismissal, we find that the appellant's cause was dismissed prematurely because not all of his claims appear to be frivolous on their face or without merit.[17]

CERTIORARI PREVIOUSLY GRANTED; COURT OF APPEALS OPINION VACATED; TRIAL COURT REVERSED AND REMANDED.
ALMA WILSON, C.J., and LAVENDER, SIMMS, HARGRAVE, OPALA and SUMMERS, JJ., concur.
HODGES, WATT, JJ., dissent.
WATT, Justice, dissenting:
Because the Petition for Certiorari was not timely filed, this Court was without jurisdiction to reach the merits as the majority *364 opinion does today. Therefore, I respectfully dissent.
NOTES
[1]  Title 42 U.S.C. § 1983 (1994) provides:

"Every person who, under color of any statute, ordinance, regulation, custom, or usage, of any State or Territory or the District of Columbia, subjects, or causes to be subjected, any citizen of the United States or other person within the jurisdiction thereof to the deprivation of any rights, privileges, or immunities secured by the Constitution and laws, shall be liable to the party injured in any action at law, suit in equity, or other proper proceeding for redress. For the purposes of this section, any Act of Congress applicable exclusively to the District of Columbia shall be considered to be a statute of the District of Columbia."
Section 1983 provides a federal remedy for deprivation of rights established by the Constitution or other laws which may be heard by the courts of this state. Willbourn v. City of Tulsa, 721 P.2d 803, 805 (Okla.1986). Even in the absence of a § 1983 claim, state courts review alleged violations of federal constitutional rights which occur within our borders if the parties are subject to state court jurisdiction. Prock v. District Court of Pittsburg County, 630 P.2d 772, 775-76 (Okla. 1981).
[2]  Originally, the appellant initiated his lawsuit in August of 1993, and the defendants filed a motion to dismiss on February 22, 1994. Subsequently, Washington attempted to supplement his pleadings to add another claim against additional prison officials. On December 14, 1994, the trial court allowed Washington to amend his petition to include all of the elements of his original petition and all supplemental matters that he wished to include. The trial court gave the prison officials 30 days after the petition had been filed to respond. It also found that any previous motions concerning discovery or motions to dismiss would be considered moot, and that the parties could file such motions after the amended petition was filed. Consequently, it is Washington's amended petition which was filed in January of 1995, and the prison officials' subsequent motion to dismiss/motion for summary judgment which was filed on February 23, 1995, which are at issue here.
[3]  Title 12 O.S.1991 § 2012 provides in pertinent part:

"... (B) Every defense, in law or in fact, to a claim for relief in any pleading, whether a claim, counterclaim, cross-claim, or third-party claim, shall be asserted in the responsive pleading thereto if one is required, except that the following defenses may at the option of the pleader be made by motion: ...
6. Failure to state a claim upon which relief can be granted; ..."
[4]  The trial court's March 2, 1995, order provides:

"Comes on for consideration of the Defendant's Motion to Dismiss. This Court hs [sic] reviewed the entire file and considered all pleadings therein.
The Plaintiff's Amended Petition fails to state any claim upon which any relief can or should be granted. The Plaintiff's claims have no basis in law. The Plaintiff's case is frivolous and totally without merit. In fact it constitutes an abuse of the court system and harassment of the defendants. To describe this lawsuit as frivolous and without merit is being generous to the Plaintiff.
Justice, common sense and the law requires that this case be ended now. No further response from the Plaintiff is needed.
This case is hereby DISMISSED." (Emphasis in original.).
[5]  This Court affords certiorari claimants review of issues undecided in an appeal which are properly preserved and briefed. Hough v. Leonard, 867 P.2d 438, 445-46 (Okla.1993).
[6]  Indiana National Bank v. D.H.S., 880 P.2d 371, 375 (Okla.1994).
[7]  Brown v. Founders Bank & Trust Co., 890 P.2d 855, 861 (Okla.1994); Frazier v. Bryan Memorial Hosp. Auth., 775 P.2d 281, 287 (Okla.1989); Valley Vista Dev. Corp., Inc. v. City of Broken Arrow, 766 P.2d 344, 348 (Okla.1988).
[8]  Title 12 O.S.1991 § 2012 provides in pertinent part:

"... (B) ... 6. Failure to state a claim upon which relief can be granted; ...
A motion making any of these defenses shall be made before pleading if a further pleading is permitted. No defense or objection is waived by being joined with one or more other defenses or objections in a responsive pleading or motion. If a pleading sets forth a claim for relief to which the adverse party is not required to serve a responsive pleading, he may assert at trial any defense in law or fact to that claim for relief. If, on a motion asserting the defense numbered 6 of this subsection to dismiss for failure of the pleading to state a claim upon which relief can be granted, matters outside the pleading are presented to and not excluded by the court, the motion shall be treated as one for summary judgment and all parties shall be given a reasonable opportunity to present all material made pertinent to such a motion by the rules for summary judgment. A motion to dismiss for failure to state a claim upon which relief can be granted shall separately state each omission or defect in the petition, and a motion that does not specify such defects or omissions shall be denied without a hearing and the defendant shall answer within twenty (20) days after the notice of the court's action."
[9]  Attached to the brief in support of the motion to dismiss/motion for summary judgment were copies of Washington's disciplinary records at the prison, the investigator's report, disciplinary hearing actions, incident/staff reports, policies and procedures for disciplinary matters, the classifications for various disciplinary offenses committed and the range of sanctions, the policies and procedures for strip-searches and an affidavit from one of the prison officials.
[10]  The trial court order specifically provides that it considered all of the matters in the file and the pleadings. See discussion note 4, supra.
[11]  Aven v. Reeh, 878 P.2d 1069 (Okla.1994); Dyke v. Saint Francis Hospital, Inc., 861 P.2d 295, 298-99 (Okla.1993); Title 12 O.S.1991 § 2012, see note 8, supra.
[12]  Rule 13, 12 O.S.1991 Ch. 2, app., Rules for the District Courts, provides in pertinent part:

"... b. If the adverse party or parties wish to oppose the granting of the motion, they shall serve on the moving party and file with the court clerk within fifteen days after service of the motion a concise written statement of the material facts as to which he or they contend a genuine issue exists and the reasons for denying the motion. The adverse party shall attach to the statement affidavits and other materials containing facts that would be admissible in evidence, but the adverse party cannot rely on the allegations or denial in his pleading. In the statement, the adverse party or parties shall set forth and number each specific material fact which is claimed to be in controversy and reference shall be made to the pages, paragraphs, and/or lines of the depositions, admissions, answers to interrogatories and to requests for admission, affidavits, exhibits and other materials whether filed by the moving party or by the adverse party, and he shall attach to the statement the portions relied upon. All material facts set forth in the statement of the movant which are supported by admissible evidence shall be deemed admitted for the purpose of summary judgment unless specifically controverted by the statement of the adverse party which is supported by admissible evidence. If the motion for judgment is granted, the party or parties opposing the motion cannot on appeal rely on any fact or material that is not referred to or included in the statement in order to show that a substantial controversy exists...."
[13]  Title 12 O.S.1991 § 2012, see note 8, supra; Rule 13, 12 O.S.1991 Ch. 2 app., Rules for the District Courts, see note 12, supra.
[14]  The appellant's allegations of ex post facto violations and due process violations regarding the fact that his disciplinary hearing was conducted by a single hearing officer, rather than a three-member committee are without legal support. However, not all of his claims appear to be without merit. For example, the gravamen of Washington's claim that he has been subjected to unconstitutional strip-searches from which he seeks injunctive relief is that: 1) he has been required to stand nude in the center of the quadrant and expose private body parts in full view of other inmates and staff who are either on the exercise yard or inside their cells; 2) the strip-searches could be conducted in private, rather than in full view of everyone; and 3) he has been subjected to strip-searches in a discriminatory manner from that used for other inmates. The appellant has not alleged any facts which would support a claim that any search was done in an abusive fashion or with unnecessary force under the Eighth Amendment. However, it appears that Washington may be able to prove facts which would support a claim under the Fourth Amendment. It is possible that he can make a rational argument on the law and facts to support his Fourth Amendment claim. The question of whether a strip-search is unreasonable under the Fourth Amendment requires a balancing of the need for the particular search against the invasion of personal rights that the search entails. Bell v. Wolfish, 441 U.S. 520, 559, 99 S.Ct. 1861, 1884, 60 L.Ed.2d 447 (1979). The court must consider the scope of the particular intrusion, the manner in which it is conducted, the justification for initiating it, and the place in which it is conducted. Id. At a bare minimum, the factual allegations raised by the appellant concerning the strip-search should bar dismissal of the cause. The appellant should be allowed an opportunity to offer evidentiary material which support his allegations concerning the circumstances under which the alleged strip-searches took place and the reasonableness of them. Similarly, we note that the prison officials assert that they were entitled to qualified immunity. However, once a defendant raises qualified immunity, the burden shifts to the plaintiff to come forward with facts which show that the defendant's alleged conduct violated the law and that the law was clearly established when the alleged violation occurs. Guffey v. Wyatt, 18 F.3d 869, 871 (10th Cir.1994); Pueblo Neighborhood Health Centers, Inc. v. Losavio 847 F.2d 642, 646 (10th Cir.1988). Because the trial court prematurely dismissed the appellant's cause, he was not allowed to respond to the appellees' assertions that they were entitled to qualified immunity.
[15]  Title 12 O.S.1991 § 2012, see note 8, supra.
[16]  Rule 13, 12 O.S.1991 Ch. 2, app., Rules for the District Courts, see note 12, supra.
[17]  See discussion, note 14, supra.
