• Resolved norbiu

    (@norbiu)


    I’m trying to add some simple html code inside one of the inputs of a theme option:

    <span class="abc">

    I can add it without the quotes, and it works, but it doesn’t validate. Any ideas?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Try single quotes? Or try escaping the quotes..

    <span class='abc'>
    <span class=\"abc\">

    Thread Starter norbiu

    (@norbiu)

    I used stripslashes for calling the info from the theme options

    <?php
      global $options;
      foreach ($options as $value) {
        if (stripslashes(get_option( $value['id'] )) === FALSE) { $$value['id'] = $value['std']; }
        else { $$value['id'] = stripslashes(get_option( $value['id'] )); }
        }
    ?>

    and htmlspecialchars() for the value of the input inside the options.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘HTML Code Inside Theme Option Input Fields?’ is closed to new replies.