Client Script in plain text

Shivani29
Mega Guru

HI,

I am trying to write new client script in Studio but today I am getting a message as mentioned below:

New client-scripts are run in strict mode, with direct DOM access disabled. Access to jQuery, prototype and the window object are likewise disabled. To disable this on a per-script basis, configure this form and add the "Isolate script" field. To disable this feature for all new globally-scoped client-side scripts set the system property "glide.script.block.client.globals" to false.

 

and I am not able to write scripting in normal way. Below is the snapshot of the script I designed yesterday and modified it today. Once update,entire script is in plain text. 

Any help please.

 

find_real_file.png

1 ACCEPTED SOLUTION

VigneshMC
Mega Sage

Issue is not because of any property, click on the highlighted icon , you will get the normal scripting ui

find_real_file.png

find_real_file.png

View solution in original post

7 REPLIES 7

asifnoor
Kilo Patron

Hi Shivani,

Kindly refer to this post for the solution.

https://community.servicenow.com/community?id=community_question&sys_id=d3e10fa9db98dbc01dcaf3231f961996

Making the changes as mentioned there will solve the problem for you.

Aslo, you can refer to this link which has screenshots for reference. https://community.servicenow.com/community?id=community_question&sys_id=d3e10fa9db98dbc01dcaf3231f961996

 

Mark the answer as correct if this works.

Shivani29
Mega Guru

Hi Asif,

 

I created glide.script.block.client.globals system propery and set it false but still same thing. Below is the snapshot.

 

find_real_file.png

 

 

 

I added the isolated field and tried making it Active and inactive both but same problem.

Hi Shivani,

Once you do that, try accessing jquery variable and check if its working or not.

The blue message that you see at the top is annotation and it will be there always.

Ref: https://hi.service-now.com/kb_view.do?sysparm_article=KB0694479 

Mark correct and helpful if this helps.

Hi Shivani,

If you are referring to the syntax only, then just click on the script icon and it will show the syntax. If you are referring ot hte message, then follow the steps as given above and it will work.

Kindly mark the answer as correct/helpful if this helps.