Re: [SOGo] My way to customize SOGo's top toolbar

2012-11-20 Thread Daniel Müller
I did as you described and all I get is a blank screen on the webgui of
SOGo? The reason is my entry in UIxPageFrame.wox 
My UIxPageFrame.wox  looks like:
 var:if condition=userHasMailAccess
var:if condition=isMail
span class=activevar:string label:value=Mail
  //span
/var:if
var:if condition=isMail const:negate=YES
  a id=mailBannerLink var:href=relativeMailPath
var:string label:value=Mail //a
/var:if
  /var:if

---My entry--  a id=FTPBannerLink style=color:#1589FF;
var:href=http://comm2/intra/ajaxplorer;
var:string label:value=FTP IAS //a
 
 a id=preferencesBannerLink
var:href=relativePreferencesPath
var:string label:value=Preferences //a
  var:if condition=isSuperUser
 


 Original-Nachricht 
 Datum: Fri, 16 Nov 2012 13:58:09 -0500 (EST)
 Von: gerard.brei...@ias.u-psud.fr
 An: users@sogo.nu
 Betreff: [SOGo] My way to customize SOGo\'s top toolbar

 Ideas for customize the SOGo's top toolbar
 
 Hello 
 As I needed to add some links in the toolbar I thought it would be nice to
 write here how I managed to.
 Suppose we want to add a link for a web ftp-client ajaxplorer that opens
 himself into a new window.
 
 1) 
a) su - sogo
b) cd GNUstep/Library/SOGo/Templates/
c) cp /usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox .
d) cp /usr/lib/GNUstep/SOGo/WebServerResources/generic.js . 
e) vim UIxPageFrame.wox
 
   Find the instruction bloc that begin by var:if
 condition=userHasMailAccess 
   Then just after the end of this bloc and before the bloc a
 id=preferencesBannerLink I added my first link :
 
   a id=FTPBannerLink style=color:#1589FF;
   var:href=https://ajaxplorer.mydomain.fr;
   var:string label:value=FTP IAS //a 
 
 2) 
a) vim generic.js 
b) just after the function onPreferencesClick I created a the function
 onFTPClick 
 
   function onFTPClick(event) {
   var urlstr = https://ajaxplorer.mydomain.fr;;
   var windowSize =
 width=900px,height=600px,resizable=1,scrollbars=1,location=0;
   var w = window.open(urlstr, FTP IAS, windowSize);
   w.opener = window;
   w.focus();
   }
 
c)Then you move into the function configureLinkBanner() and just before
 the
 line link = $(preferencesBannerLink); you  add your link :
 
   link = $(FTPBannerLink);
   if (link) {
   link.observe(mousedown, listRowMouseDownHandler);
   link.observe(click, clickEventWrapper(onFTPClick));
   }
 3) as user root we create symbolic links after deleting the original files
 (you
 could make a copy of each of them before making this)
a) rm -f /usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox 
b) rm - /usr/lib/GNUstep/SOGo/WebServerResources/generic.js 
c) ln -s /home/sogo/GNUstep/Library/SOGo/Templates/UIxPageFrame.wox
 /usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox
d) ln -s /home/sogo/GNUstep/Library/SOGo/Templates/generic.js
 /usr/lib/GNUstep/SOGo/WebServerResources/generic.js 
 
 By following this way you can create several other links that will opens
 themselves in another window by clicking on them.
  
 Note-1 : the symbolic links created above (ln -s ….) are supposed (I
 hope) to
 avoid theses two files to be overwriting at the next upgrade of sogo.
 Note-2 : I do not know why but that doesn't work if my personal link is
 after
 the one of the preferences.
 
 Hoping this can help you…
 
 Gerard-- 
 users@sogo.nu
 https://inverse.ca/sogo/lists
-- 
users@sogo.nu
https://inverse.ca/sogo/lists


[SOGo] My way to customize SOGo's top toolbar

2012-11-16 Thread gerard breiner
1)
   a) su - sogo
   b) cd GNUstep/Library/SOGo/Templates/
   c) cp /usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox .
   d) cp /usr/lib/GNUstep/SOGo/WebServerResources/generic.js .
   e) rm -f /usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox
   f) rm - /usr/lib/GNUstep/SOGo/Templates/generic.js
   g) ln -s /home/sogo/GNUstep/Library/SOGo/Templates/UIxPageFrame.wox 
/usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox
   h) ln -s /home/sogo/GNUstep/Library/SOGo/Templates/generic.js 
/usr/lib/GNUstep/SOGo/WebServerResources/generic.js
   i) vim UIxPageFrame.wox

  Find the instruction bloc that begin by var:if 
condition=userHasMailAccess
  Then just after the end of this bloc and before the bloc a 
id=preferencesBannerLink I added my first link :

a id=FTPBannerLink style=color:#1589FF;
var:href=https://ajaxplorer.mydomain.fr;
var:string label:value=FTP IAS //a

2)
   a) vim generic.js
   b) just after the function onPreferencesClick I created a the function 
onFTPClick

function onFTPClick(event) {
var urlstr = https://ajaxplorer.mydomain.fr;;
var windowSize = 
width=900px,height=600px,resizable=1,scrollbars=1,location=0;
var w = window.open(urlstr, FTP IAS, windowSize);
w.opener = window;
w.focus();
}

   c)Then you move into the function configureLinkBanner() and just before the 
line link = $(preferencesBannerLink);  you  add your link :

link = $(FTPBannerLink);
if (link) {
link.observe(mousedown, listRowMouseDownHandler);
link.observe(click, clickEventWrapper(onFTPClick));
}

By following this way you can create several other links that will opens 
themselves in another window by clicking on them.
Given
Note-1 : the symbolic links created above (ln -s ….) are supposed (I hope) to 
avoid theses two files to be overwriting at the next upgrade of sogo.
Note-2 : I do not know why but that doesn't work if my personal link is after 
the one of the preferences.

Hoping this can help you…

Gerard

-- 
users@sogo.nu
https://inverse.ca/sogo/lists

[SOGo] My way to customize SOGo's to toolbar

2012-11-16 Thread gerard.breiner
Ideas for customize the SOGo's top toolbar

Hello 
As I needed to add some links in the toolbar I thought it would be nice to
write here how I managed to.
Suppose we want to add a link for a web ftp-client ajaxplorer that opens
himself into a new window.

1) 
   a) su - sogo
   b) cd GNUstep/Library/SOGo/Templates/
   c) cp /usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox .
   d) cp /usr/lib/GNUstep/SOGo/WebServerResources/generic.js . 
   e) vim UIxPageFrame.wox

  Find the instruction bloc that begin by var:if
condition=userHasMailAccess 
  Then just after the end of this bloc and before the bloc a
id=preferencesBannerLink I added my first link :

a id=FTPBannerLink style=color:#1589FF;
var:href=https://ajaxplorer.mydomain.fr;
var:string label:value=FTP IAS //a 

2) 
   a) vim generic.js 
   b) just after the function onPreferencesClick I created a the function
onFTPClick 

function onFTPClick(event) {
var urlstr = https://ajaxplorer.mydomain.fr;;
var windowSize =
width=900px,height=600px,resizable=1,scrollbars=1,location=0;
var w = window.open(urlstr, FTP IAS, windowSize);
w.opener = window;
w.focus();
}

   c)Then you move into the function configureLinkBanner() and just before the
line link = $(preferencesBannerLink); you  add your link :

link = $(FTPBannerLink);
if (link) {
link.observe(mousedown, listRowMouseDownHandler);
link.observe(click, clickEventWrapper(onFTPClick));
}
3) as user root we create symbolic links after deleting the original files (you
could make a copy of each of them before making this)
   a) rm -f /usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox 
   b) rm - /usr/lib/GNUstep/SOGo/WebServerResources/generic.js 
   c) ln -s /home/sogo/GNUstep/Library/SOGo/Templates/UIxPageFrame.wox
/usr/lib/GNUstep/SOGo/Templates/UIxPageFrame.wox
   d) ln -s /home/sogo/GNUstep/Library/SOGo/Templates/generic.js
/usr/lib/GNUstep/SOGo/WebServerResources/generic.js 

By following this way you can create several other links that will opens
themselves in another window by clicking on them.
 
Note-1 : the symbolic links created above (ln -s ….) are supposed (I hope) to
avoid theses two files to be overwriting at the next upgrade of sogo.
Note-2 : I do not know why but that doesn't work if my personal link is after
the one of the preferences.

Hoping this can help you…

Gerard-- 
users@sogo.nu
https://inverse.ca/sogo/lists

Re: [SOGo] My way to customize SOGo's top toolbar

2012-11-16 Thread Ludovic Marcotte

You surely found a way to pass that message :-P

--
Ludovic Marcotte
+1.514.755.3630  ::  www.inverse.ca
Inverse inc. :: Leaders behind SOGo (www.sogo.nu) and PacketFence 
(www.packetfence.org)

--
users@sogo.nu
https://inverse.ca/sogo/lists