Skip navigation

A change of the portal URL could be required in case, for example, of a company rebranding, when it is necessary to replace the portal address with another one. This is done remotely and is applied to all set-top boxes.

1. Edit xpcom.common.js file which is by default stored in ../stalker_portal/c/ .

2. Find a part of code:

this.type = stb.RDir('Model').clearnl(); 
}
this.header_ua_ext.push('Model: ' + this.type); 
this.stb_lang = stb.RDir('getenv language').clearnl();

3. Add the following code:

var new_portal = 'http://example.com/stalker_portal/c/index.html'; 
var current_portal = stb.RDir('getenv portal1').clearnl(); 
if (current_portal != new_portal){ 
_debug('setenv portal1 ' + new_portal); 
stb.RDir('setenv portal1 ' + new_portal); 
stb.ExecAction('reboot'); 
return; 
}

here 

}
>>>adding code<<<
this.header_ua_ext.push('Model: ' + this.type);

where
http://example.com/stalker_portal/c/index.html
- new portal URL .

In this case, set-top box when loading the current portal will replace the variable value with a new URL, automatically reload, and, upon reloading, upload a new portal.

For example:

this.type = stb.RDir('Model').clearnl();
}
var new_portal = 'http://example.com/stalker_portal/c/index.html';
var current_portal = stb.RDir('getenv portal1').clearnl();
if (current_portal != new_portal){
_debug('setenv portal1 ' + new_portal);
stb.RDir('setenv portal1 ' + new_portal);
stb.ExecAction('reboot');
return;
}
this.header_ua_ext.push('Model: ' + this.type);
this.stb_lang = stb.RDir('getenv language').clearnl();
Need Help

Cindy is an expert on the Ministra TV platform and the author of this article.

Was this article helpful?

Yes No

Sorry to hear that.
How can we improve this article?

We use cookies in order to optimise our website, provide you with the best possible user experience and help us promote our products. Please read our Cookie Policy to find out how we use cookies and how you can control cookies.
By using this website or closing this message, you acknowledge our Privacy Policy and agree to our use of cookies as described in our Cookie Policy.