Custom script not executing

Custom script not executing

When attempting to update the subject with an employees name using custom script on form submit it won't update the subject. I have been watching all of the videos I can find and at one point had this working in my test environment but trying to replicate in production environment is not working. Is my script correct? Do I have to enable/install anything on the server to get the script to run?

var x=$CS.getValue("SUBJECT");
var y=$CS.getValue("GUDF_CHAR1");
if($CS.isFormSubmit()){
$CS.setValue("SUBJECT", x + "for " + y);
}


Note: GUDF_CHAR1 is the reference to my Additional field I am trying to pull information from.

                  New to ADSelfService Plus?