I have the following function call inside a jsp page.

```
jQuery(function($){
   $("#product").mask("99/99/9999",{placeholder:" "});
});

```

What I want to do is pass a different string into the `.mask` function. In pseudo code it would look something along the lines of:

```
String passedParam= someString  
if(test):
  passedParam = "someotherString"

jQuery(function($){
   $("#product").mask(passedParam,{placeholder:" "});
});

```

Being new to both jsp and javascript I do not know the correct way to translate this pseudo code into actual working code.