0

Hi i was wondering if there is a function in php to take this 1<sup>o</sup>semaster and returns me 1o semaster I want the same function for php as variable.text() method of jquery

1
  • 2
    Just to note, when using strip_tags (like the posts below state) you won't be getting 1o semaster. You'll get 1osemaster -- so.. that's probably just a typo, right? Commented Dec 11, 2011 at 13:54

2 Answers 2

4

You're probably looking for strip_tags

Sign up to request clarification or add additional context in comments.

1 Comment

@MikulasDite: htmlspecialchars() is definitely not like jQuery's .text() (see jsfiddle), but strip_tags() is.
0
$test = "1<sup>o</sup>semaster
echo strip_tags($test);

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.