javascript - How can I real time parse content in a textarea as the user types like how stackoverflow does it? -


when adding post @ stackoverflow, enter text on edit window, , appears modified in display window. instance...

  • if type **some text, see **some text (**some text)
  • if type **some text*, see *some text (*<em>some text</em>)
  • if type **some text**, see some text (<strong>some text</strong>)

how this? there jquery solution?

this syntax writing in comments called markdown. there few javascript markdown parsers. https://code.google.com/p/pagedown/ example


Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -