javascript - WYSIWYG without the HTML tags? -


is possible take text wysiwyg editor? example, if have following text:

<a href="whatever"> sdadsa<>,.<> <p </a> 

is possible take text inside sdadsa<>,.<>?

some might don't use editor need make 2 copies 1 tags , other without html tags , html tags match.

is possible take text without html tags?

if want strip html tags out of output, have 2 methods:

  • with php - use strip_tags($output).

  • with javascript - type

    var plaintext= editoroutput.replace(/(<([^>]+)>)/ig,"");

    or use php.js's equivalent php method.


Comments

Popular posts from this blog

javascript - backbone.js Collection.add() doesn't `construct` (`initialize`) an object -

php - Get uncommon values from two or more arrays -

Adding duplicate array rows in Php -