Question T2656
Visible to All Users

HTML In Page or Form Title

created 5 years ago

I tried to bold a word in the Title of a survey, the HTML was sanitized so the title became "Title <strong>bold</strong>". I used https://plnkr.co/edit/OC7R7xkJzPScLDMgBVxJ?p=preview as an example to set it directly in JS. Is there another way to do this or is this a feature request?

Answers approved by surveyjs Support

created 5 years ago

Hello Joshua,
You have to use onTextMarkdown event.
Here is the example.

Thank you,
Andrew
SurveyJS Team

    Comments (1)

      I just realized, you may need to support it in Creator.
      In this case, please use the surveyCreator.onSurveyInstanceCreated event, to set the onTextMarkdown event:

      JavaScript
      surveyCreator.onSurveyInstanceCreated.add(function(sender, options) { options.survey.onTextMarkdown.add(function(sender, options) { //here is the code for onTextMarkdown from the previous example }); });

      Thank you,
      Andrew
      SurveyJS Team