Modify Field label on a form.

Nishant Kharat1
Tera Contributor

Hello All,

 

We have a requirement in which we have to modify Field label on a form.

Field label=Please ensure that all collaterals/ artifacts (Brochures/ Flyers, White Papers, Blogs, etc.) are submitted and approved at Collabarative publication portal.we have to modify it in such a way that Collabarative publication portal becomes a hyperlink and user clicks on that they are redirect to some xyz page.

I tried to write a onload client script but it just paste the a tag along with the content.

 

var abc = g_form.getLabelOf("please_ensure_that_all_collaterals_artifacts_brochures_flyers_white_papers");
var modified = abc.replace('Collabarative publication portal', '<a href="https://xyz...">Collabarative publication portal</a>');
alert(modified);
g_form.setLabelOf("please_ensure_that_all_collaterals_artifacts_brochures_flyers_white_papers", modified);

 

Please can anyone help into this?

 

Thanks,

Nishant.

5 REPLIES 5

You can add annotation before or after the field, with modified text which would make sense.

 

For more details: https://docs.servicenow.com/bundle/rome-servicenow-platform/page/administer/workspace/task/set-up-fo... 

 

 

If I could help you with your Query then, please hit the Thumb Icon and mark my answer as Correct!!

Thank you,
Ali