Support » Fixing WordPress » need to save html in a metabox, problem with add_post_meta

Viewing 3 replies - 1 through 3 (of 3 total)
  • I don’t know php but in javascript you would have to write something like this \/ to add a /

    It would be the same with php. the \ is supposed to escape the next character. But there’s more than that going on here. It strips out the < and > and converts the double quotes to single quotes. Actually when I try to escape a character with the \ it ends up blank so maybe it is interpreting the \ as escape everything else after it.

    For a work around and probably more secure way, I made an input for each meta tag and then in the header have a function that gets those values and builds out the meta tags but I’d like to know how to do it the other way so if I wanted to just have a text area where the user can just type in a block of meta tags and have them added to the header all in one chunk.

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘need to save html in a metabox, problem with add_post_meta’ is closed to new replies.