function setParams() { var params = { 'language': "<?php echo (isset($_GET['language'])) ? $_GET['language'] : ''; ?>" }; return params; }The above example is based on PHP code but you can replace PHP code with the code your website has developed. Or you can also simply hard code the language based on the user sessions or your location based website. For example
function setParams() { var params = { 'language': "es" }; return params; }Make sure your website doesn't have already existed function with the name of setParams in your JS code. *Note: The value language should be in standard shortcode, like “en” for English, “es” for Spanish.