Skip to content
Snippets Groups Projects
Commit 8ed94a25 authored by Sebastian Paul's avatar Sebastian Paul
Browse files

replace special chars in sitename with empty space

parent 4392fb97
Branches
Tags
No related merge requests found
......@@ -15,9 +15,11 @@ function unityReady() {
if (external && external.getUnityObject) {
jQuery(window).load(function(){
// workaround as unity strips special chars from name:
var strippedname = Drupal.settings.unity_api.sitename.replace(/[^a-zA-Z0-9]/g,'');
var Unity = external.getUnityObject(1.0);
Unity.init({
name: Drupal.settings.unity_api.sitename,
name: strippedname,
iconUrl: Drupal.settings.unity_api.favicon,
onInit: unityReady,
domain: Drupal.settings.unity_api.baseurl
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment