Page 1 of 1

white label again overrided

Posted: Mon 29. Aug 2016, 13:12
by info@eurhosting.net
Hello

With new version of keyhelp the whitelabel javascript setting has been again overrided.

Normally I use this script to hide the news, the changelog and the whitelabel menu in administration.

With the update of keyhelp is uselass, changelog, news and white label menu are still there

Code: Select all

$('document').ready( function () {
	
	var url      = window.location.href;
  
  	// il link whitelabel lo nascondo da tutte le pagine
  	$("div#overallwrapper div.nav ul li a:contains('White Label')").closest('li').hide();
  	$("div#overallwrapper div.nav ul li a:contains('Брендирование')").closest('li').hide();
  	$("div#overallwrapper div.nav ul li a:contains('Whitelabel')").closest('li').hide();
  

	if (url.indexOf("admin_index") >= 0)
	{
		// remove news 
		$("div.page div.content th:contains('News')").closest('div').remove();
		$("div.page div.content th:contains('новости')").closest('div').remove();
		
		
		// rimuovo link changelog
		$("div.page div.content a:contains('See history of changes')").remove();
		$("div.page div.content a:contains('Änderungsprotokoll anzeigen')").remove();
		$("div.page div.content a:contains('История изменений')").remove();
	}
		
});
What do have I to modify to have again this script working?

Re: white label again overrided  [SOLVED]

Posted: Tue 30. Aug 2016, 11:04
by Alexander
Hello,

KeyHelp does not override white label settings. The reason, the settings are no longer working is, that some CSS class names + HTML IDs changed with last update 14.7.0.

(It was also mentioned in the news for the current update: https://www.keyhelp.de/en/news/keyhelp- ... t-support/ )

Replace your current Javascript code, with this one and it will be working again.

Code: Select all

$('document').ready( function () {
   
   var url      = window.location.href;

     // il link whitelabel lo nascondo da tutte le pagine
     $(".sidebar ul li a:contains('White Label')").closest('li').hide();
     $(".sidebar ul li a:contains('Брендирование')").closest('li').hide();
     $(".sidebar ul li a:contains('Whitelabel')").closest('li').hide();
  

   if (url.indexOf("admin_index") >= 0)
   {
      // remove news 
      $("div.content th:contains('News')").closest('div').remove();
      $("div.content th:contains('новости')").closest('div').remove();
      
      
      // rimuovo link changelog
      $("div.content a:contains('See history of changes')").remove();
      $("div.content a:contains('Änderungsprotokoll anzeigen')").remove();
      $("div.content a:contains('История изменений')").remove();
   }
      
});

Re: white label again overrided

Posted: Wed 7. Aug 2019, 09:38
by Alexander
Hello,

For a transparent sidebar and black texts you can use this as a starter.

Code: Select all

#sidebar {
  background-color: rgba(0, 0, 0, 0.0);
}

.menu-label {
  color: #000;
}

.menu-list a {
  color: #000;
}

(The next time, you better start a new thread, instead of using this from 2016 which also having a different topic ;))

Re: white label again overrided

Posted: Fri 23. Aug 2019, 00:27
by tom83
Anyone have could help how to make the panel all whitelabel? What changes and files do we need to make?
(From keyadmin user and regular users)
Where to start?
Thanks!

Re: white label again overrided

Posted: Fri 23. Aug 2019, 08:15
by Alexander
The preferred way is to use the white label feature under "Configuration" -> "White label". Because this is totally update-safe. and you can do a lot with it.

Alternatively you could create your own theme. Have a look into /home/keyhelp/www/keyhelp/theme. Create a new folder, and a put your files there. Themes are written as Twig templates. For how to build a theme, have a look into the other two themes.
Problems may arise later, because you have to keep your themes up to date with new KeyHelp updates.