Page 1 of 1

How can I modify the web console?

Posted: 19 Feb 2014 03:17
by cyberwired
I'm not bad with php etc but the way this is put together isn't what I'm used to, having trouble finding where things are

I want to put the date and time on the same line, so its more compact, and the Recent Messages, Lists etc bar, I want to compact that also

Where would I do that?

Re: How can I modify the web console?

Posted: 19 Feb 2014 14:46
by darky83
This is something we want to do in an next release

This is located somewhere in functions.php, but I have not found the right section just yet :-) (have not spend any time on it..)

Re: How can I modify the web console?

Posted: 20 Feb 2014 00:48
by shawniverson
No worries, I am going to duplicate the Message Listing and Message Operations formatting here ;)

Re: How can I modify the web console?

Posted: 20 Feb 2014 04:39
by cyberwired
I'm embarrassed to say this stared me in the face for way too long and I just kept missing it

/var/www/html/mailscanner/status.php

Change (it may differ slightly on this, I removed it then can't go back)

Code: Select all

DATE_FORMAT(timestamp, '".DATE_FORMAT."<br>".TIME_FORMAT."') AS datetime, 


To

Code: Select all

DATE_FORMAT(timestamp, '".DATE_FORMAT." ".TIME_FORMAT."') AS datetime,   
Basically remove the <br> in the middle there

Re: How can I modify the web console?

Posted: 20 Feb 2014 04:46
by cyberwired
And to make that big bar smaller, open style.css, go down to #menu and change height from 40 to 20, padding from 10 to 5, then #menu li a line-height from 40 to 20

Image

Re: How can I modify the web console?

Posted: 20 Feb 2014 09:27
by shawniverson

Re: How can I modify the web console?

Posted: 20 Feb 2014 10:01
by darky83
:text-goodpost:

Re: How can I modify the web console?

Posted: 26 Feb 2014 00:51
by cyberwired
cyberwired wrote:I'm embarrassed to say this stared me in the face for way too long and I just kept missing it

/var/www/html/mailscanner/status.php

Change (it may differ slightly on this, I removed it then can't go back)

Code: Select all

DATE_FORMAT(timestamp, '".DATE_FORMAT."<br>".TIME_FORMAT."') AS datetime, 


To

Code: Select all

DATE_FORMAT(timestamp, '".DATE_FORMAT." ".TIME_FORMAT."') AS datetime,   
Basically remove the <br> in the middle there
I just realised on smaller monitors this doesn't quite do the trick
editing functions.php I added

Code: Select all

if ($fieldname[$f]=="Date/Time"){ $cellwidth = " width='125'"; } else { $cellwidth = ""; } 
in this location:

Code: Select all

// Column headings
  echo '<tr>'."\n";
  for($f=0; $f<$fields; $f++) {
   if($display[$f]) {
    if($order && $orderable[$f]) {
     // Set up the mysql column to account for operations
     if ($operations != false) {
      $colnum = $f-1;
     } else {
      $colnum = $f;
     }
     echo "  <th>\n";           
     echo "  $fieldname[$f] (<a href=\"?orderby=".mysql_field_name($sth,$colnum)."&orderdir=a".subtract_multi_get_vars(array('$
     echo "  </th>\n";
    } else {
        if ($fieldname[$f]=="Date/Time"){ $cellwidth = " width='125'"; } else { $cellwidth = ""; } 
     echo '  <th'.$cellwidth.'>'.$fieldname[$f].'</th>'."\n";        
    }
   }
  }
also modified

Code: Select all

 echo '  <th>'.$fieldname[$f].'</th>'."\n";   
to be

Code: Select all

 echo '  <th'.$cellwidth.'>'.$fieldname[$f].'</th>'."\n";