Difference between revisions of "Rename Student Voice Module"

From UnionCloud Support
Jump to: navigation, search
(Page creation)
 
 
(One intermediate revision by one other user not shown)
Line 3: Line 3:
 
The below code snippet, which should be copied in to Global Javascript, allows your Union to rename all the titles on the Student Voice module to your local brand name. Make sure you change "PUT YOUR NAME HERE" to your local brand name.
 
The below code snippet, which should be copied in to Global Javascript, allows your Union to rename all the titles on the Student Voice module to your local brand name. Make sure you change "PUT YOUR NAME HERE" to your local brand name.
  
  <nowiki>
+
  <syntaxhighlight lang="javascript" line='line'>
 
$(function() {
 
$(function() {
 
     if (window.location.pathname.substring(0, 16) == '/thestudentvoice' && window.location.pathname.length <= 17) {
 
     if (window.location.pathname.substring(0, 16) == '/thestudentvoice' && window.location.pathname.length <= 17) {
Line 12: Line 12:
 
     }
 
     }
 
});
 
});
</nowiki>
+
</syntaxhighlight>

Latest revision as of 15:08, 29 March 2017

Many Union's like to brand their Student Voice module with a different name (e.g. Big Ideas).

The below code snippet, which should be copied in to Global Javascript, allows your Union to rename all the titles on the Student Voice module to your local brand name. Make sure you change "PUT YOUR NAME HERE" to your local brand name.

1 $(function() {
2     if (window.location.pathname.substring(0, 16) == '/thestudentvoice' && window.location.pathname.length <= 17) {
3         var svName = 'PUT YOUR NAME HERE';
4         $('.uc-heading-title span').html(svName);
5         var siteName = document.title.split('@')[1];
6         document.title = svName + ' @' + siteName;
7     }
8 });