Search The ForumSearch   RegisterRegister  LoginLogin

AfterLogic WebMail Lite 7

 AfterLogic Forum : AfterLogic WebMail Lite 7
Subject Topic: A few questions. Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
Fonzie
Newbie
Newbie
Avatar

Joined: 24 March 2015
Location: United Kingdom
Online Status: Offline
Posts: 4
Posted: 25 March 2015 at 12:26am | IP Logged Quote Fonzie

First, thank you for a wonderful piece of software, it is very very good.

I have spent months looking for a good desktop client (for mac and linux) that does threaded email, of the few I have found, they either look ugly, or take up huge system resources for multiple accounts.

I would like to replace my current email client with AfterLogic Webmail, but before I commit and buy the pro version, would like to know if you can help on the following problems I currently have.


1) When I expand a thread, the colour of each thread in the message is a slightly different colour, I would like to change this to make threads in this group of messages stand out. Is it possible to do this ?

2) I monitor emails for 5 different accounts on my own domain (enquiries, sales, repairs etc), is it possible to monitor more than one account at one time?

3) Desktop notifications don't appear to be working (on my mac), despite being enabled in settings, what is supposed to show up ? is there supposed to be a sound ?





Back to Top View Fonzie's Profile Search for other posts by Fonzie
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6104
Posted: 25 March 2015 at 1:17am | IP Logged Quote Igor

Hello,

First of all, please let me clarify that WebMail Lite is not a demo or trial of the Pro version, it's a different product. WebMail Pro is available for full-featured 30-days trial download, and unlike WebMail Lite, it comes with guaranteed free support from AfterLogic provided via HelpDesk, during trial period too.

Quote:
1) When I expand a thread, the colour of each thread in the message is a slightly different colour, I would like to change this to make threads in this group of messages stand out. Is it possible to do this ?


Sorry, not sure if I understand what color you are speaking of. Is this about background color or text color, and which element specifically? Also, which skin are you using?

Quote:
I monitor emails for 5 different accounts on my own domain (enquiries, sales, repairs etc), is it possible to monitor more than one account at one time?


No that's not currently supported.

Quote:
3) Desktop notifications don't appear to be working (on my mac), despite being enabled in settings, what is supposed to show up ? is there supposed to be a sound ?


When new email message is received, and browser window/tab with WebMail is not active (you're working in another tab, for example) a small message would show up notifying you of new incoming email (there isn't supposed to be any sound there). Make sure you have notifications enabled in the browser (example for Google Chrome).

--
Regards,
Igor, AfterLogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 
webdbase2
Valued Community Member
Valued Community Member


Joined: 25 March 2015
Location: Bulgaria
Online Status: Offline
Posts: 81
Posted: 25 March 2015 at 1:08pm | IP Logged Quote webdbase2

I've succeeded in making a sound notification and it works in any HTML5 compliant browser. It does not meet the requirements of an Afterlogic plugin and breaks the main code, but that was the quickest way. I am aware that upon update it would be lost, but the changes are minor an could be recovered.

1. Manually alter table awm_settings, add column sound_notify varchar(255)

2. Alter libraries/afterlogic/common/managers/db/classes/sql.php
add a new line
Code:
new CDbField('sound_notify', CDbField::VAR_CHAR, '0'),

after the line
Code:
new CDbField('auto_checkmail_interval', CDbField::INT, 0),


3. Alter libraries/afterlogic/common/managers/users/classes/user.php
add a new line
Code:
'SoundNotify'   => '0',

after the line
Code:
'AutoCheckMailInterval' => $oDomain->AutoCheckMailInterval,

and a new line
Code:
'SoundNotify'           => array('string(255)', 'sound_notify'),

after the line
Code:
'AutoCheckMailInterval' => array('int', 'auto_checkmail_interval'),


4. Alter templates/Index.html
add a line
Code:
<script src=sound-notify.js></script>

after the line
Code:
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />


5. Create sound-notify.js file in the root of your installation
Code:

function initAJAX()
{

var ajaxRequest;

try{
// Opera 8.0+, Firefox, Safari
   ajaxRequest = new XMLHttpRequest();
} catch (e){
    // Internet Explorer Browsers
    try{
       ajaxRequest = new ActiveXObject("Msxml2.XMLHTTP");
    } catch (e) {
      try{
        ajaxRequest = new ActiveXObject("Microsoft.XMLHTTP");
      } catch (e){
        // Something went wrong
        alert("You browser does not support AJAX!");
        return false;
      }
    }
}
return ajaxRequest;
}

http_save_sound=initAJAX();
http_get_sound=initAJAX();
function save_sound(what)
{
http_save_sound.open("GET", "sound-notify.php?f="+what, true);
http_save_sound.onreadystatechange = function()
   {
   if ((http_save_sound.readyState == 4) && (http_save_sound.status == 200))
      {
      if (http_save_sound.responseText=="0")
         App.Api.showReport(AfterLogicApi.i18n("SETTINGS/COMMON_SOUND_TURNED_OFF"));
      else
         App.Api.showReport(AfterLogicApi.i18n("SETTINGS/COMMON_SOUND_TURNED_ON")+http_save_sound.responseText);
      }
   }
http_save_sound.send("");
}

function get_sound(action)
{
http_get_sound.open("GET", "sound-notify.php", true);
http_get_sound.onreadystatechange = function()
   {
   if ((http_get_sound.readyState == 4) && (http_get_sound.status == 200))
      {
      if (action)
         {
         if (http_get_sound.responseText!="0")
            {
            var notif_sound = new Audio(http_get_sound.responseText);
            notif_sound.play();
            }
         }
      else
         {
         document.getElementById("sound_notify").value=http_get_sound.responseText;
         }
      }
   }
http_get_sound.send("");
}


5. Create sound-notify.php file in the root of your installation
Code:

<?php
include('libraries/afterlogic/api.php');
extract($_GET,EXTR_SKIP);
$oApiIntegratorManager = \CApi::Manager('integrator');
$oApiUsers = \CApi::Manager('users');
$id=$oApiIntegratorManager->GetLogginedUserId();
if ($id)
   {
   $oAccount = $oApiUsers->GetDefaultAccount($id);
   if (isset($f))
      {
      $oAccount->User->SoundNotify=$f;
      $oApiUsers->UpdateAccount($oAccount);
      echo $f;
      }
   else
      echo $oAccount->User->SoundNotify;
   }
?>


6. Alter templates/views/Settings/CommonSettingsViewModel.html
put
Code:

<div class="row">
  <span class="label" data-i18n="SETTINGS/COMMON_USE_SOUND" data-bind="i18n: 'text'"></span>
  <select id=sound_notify class="value input" onchange="save_sound(this.value)">
    <option value="0" data-i18n="SETTINGS/COMMON_USE_NO_SOUND"  data-bind="i18n: 'text'"></option>
    <option value="file1.wav">file1.wav</option>
    <option value="file2.wav">file2.wav</option>
    <!- put here as many files as you want -->
    <option value="fileN.wav">fileN.wav</option>
  </select><img src="play.png" width="20" onload="get_sound(0);" data-bind="customTooltip: 'SETTINGS/COMMON_PLAY_SOUND'" onclick="a=new Audio(document.getElementById('sound_notify').value);a.play()">
</div>

after
Code:


<div class="row">
  <span class="label" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_EVERY" data-bind="i18n: 'text'"></span>
  <select class="value input" data-bind="value: autocheckmailInterval">
    <option value="0" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_OFF" data-bind="i18n: 'text'"></option>
    <option value="1" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_1" data-bind="i18n: 'text'"></option>
    <option value="3" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_3" data-bind="i18n: 'text'"></option>
    <option value="5" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_5" data-bind="i18n: 'text'"></option>
    <option value="10" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_10" data-bind="i18n: 'text'"></option>
    <option value="15" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_15" data-bind="i18n: 'text'"></option>
    <option value="20" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_20" data-bind="i18n: 'text'"></option>
    <option value="30" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_30" data-bind="i18n: 'text'"></option>
  </select>
</div>


7. Add localisation in the SETTINGS section of your language file:
Code:

COMMON_USE_NO_SOUND = "No sound notification"
COMMON_USE_SOUND = "Sound notification"
COMMON_PLAY_SOUND = "Play"
COMMON_SOUND_TURNED_OFF = "The sound notification is turned off."
COMMON_SOUND_TURNED_ON = "The sound notification is turned on: "



8. Upload sound files file1.wav ... fileN.wav to the root of your installation. Any sound file should do the job .

9. Switch to app.js instead of app-min.js

10. Alter static/js/app.js
place
Code:
                get_sound(1);

before the line
Code:
                App.desktopNotify(oParameters);



11. Find a suitable image for a play button (play.png) and place it in the root of your installation.

And the result looks as follows

Back to Top View webdbase2's Profile Search for other posts by webdbase2
 
webdbase2
Valued Community Member
Valued Community Member


Joined: 25 March 2015
Location: Bulgaria
Online Status: Offline
Posts: 81
Posted: 25 March 2015 at 2:03pm | IP Logged Quote webdbase2

Fonzie wrote:

2) I monitor emails for 5 different accounts on my own domain (enquiries, sales, repairs etc), is it possible to monitor more than one account at one time?


Why don't you install it in 5 different directories and open them simultaneously?
Back to Top View webdbase2's Profile Search for other posts by webdbase2
 
Fonzie
Newbie
Newbie
Avatar

Joined: 24 March 2015
Location: United Kingdom
Online Status: Offline
Posts: 4
Posted: 25 March 2015 at 11:32pm | IP Logged Quote Fonzie

Thank you for your reply.

Lets say there's ten emails in the thread, when you click on the number to expand the thread, all the messages in that thread are shown, along with the sender and the subject.

I would like to colour each one of the backgrounds of these to highlight them as being part of the thread, making them easy to distinguish as being part of the thread.

I am using the standard skin.


It's a great pity that for my question number2, thats not possible, I would have dumped my desktop client immediately, any plans for such a feature ?


As for question3, I have it working now, thank you, the lack of sound and the fact it only stays on my screen for around half a second, meant I missed it.

Thanks for your help.

Igor wrote:
Hello,

First of all, please let me clarify that WebMail Lite is not a demo or trial of the Pro version, it's a different product. WebMail Pro is available for full-featured 30-days trial download, and unlike WebMail Lite, it comes with guaranteed free support from AfterLogic provided via HelpDesk, during trial period too.

Quote:
1) When I expand a thread, the colour of each thread in the message is a slightly different colour, I would like to change this to make threads in this group of messages stand out. Is it possible to do this ?


Sorry, not sure if I understand what color you are speaking of. Is this about background color or text color, and which element specifically? Also, which skin are you using?

Quote:
I monitor emails for 5 different accounts on my own domain (enquiries, sales, repairs etc), is it possible to monitor more than one account at one time?


No that's not currently supported.

Quote:
3) Desktop notifications don't appear to be working (on my mac), despite being enabled in settings, what is supposed to show up ? is there supposed to be a sound ?


When new email message is received, and browser window/tab with WebMail is not active (you're working in another tab, for example) a small message would show up notifying you of new incoming email (there isn't supposed to be any sound there). Make sure you have notifications enabled in the browser (example for Google Chrome).

--
Regards,
Igor, AfterLogic Support
Back to Top View Fonzie's Profile Search for other posts by Fonzie
 
Fonzie
Newbie
Newbie
Avatar

Joined: 24 March 2015
Location: United Kingdom
Online Status: Offline
Posts: 4
Posted: 25 March 2015 at 11:50pm | IP Logged Quote Fonzie

My workaround to date was to write a php page that regularly updates the number of unread emails, there's also a link that allows me to open each account into a frame on the page.

Not ideal, but works.


webdbase2 wrote:
Fonzie wrote:

2) I monitor emails for 5 different accounts on my own domain (enquiries, sales, repairs etc), is it possible to monitor more than one account at one time?


Why don't you install it in 5 different directories and open them simultaneously?
Back to Top View Fonzie's Profile Search for other posts by Fonzie
 
Fonzie
Newbie
Newbie
Avatar

Joined: 24 March 2015
Location: United Kingdom
Online Status: Offline
Posts: 4
Posted: 25 March 2015 at 11:53pm | IP Logged Quote Fonzie

WOW, impressive.

I'm not going to try and implement that on my current system as I can't take the risk of breaking our company email, I will install to our development server and come back to you with results.

Thanks, very much appreciated.


webdbase2 wrote:
I've succeeded in making a sound notification and it works in any HTML5 compliant browser. It does nor meet the requirements of an Afterlogic plugin and breaks the main code, but that was the quickest way. I am aware that upon update it would be lost, but the changes are minor an could be recovered. The localisation is poor - only in the modified template.

1. Manually alter table awm_settings, add column sound_notify varchar(255)

2. Alter libraries/afterlogic/common/managers/db/classes/sql.php
add a new line
Code:
new CDbField('sound_notify, CDbField::VAR_CHAR, '0'),

after the line
Code:
new CDbField('auto_checkmail_interval', CDbField::INT, 0),


3. Alter libraries/afterlogic/common/managers/users/classes/user.php
add a new line
Code:
'SoundNotify'   => '0',

after the line
Code:
'AutoCheckMailInterval' => $oDomain->AutoCheckMailInterval,

and a new line
Code:
'SoundNotify'           => array('string(255)', 'sound_notify'),

after the line
Code:
'AutoCheckMailInterval' => array('int', 'auto_checkmail_interval'),


4. Alter templates/Index.html
add a line
Code:
<script src=sound-notify.js></script>

after the line
Code:
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />


5. Create sound-notify.js file in the root of your installation
Code:

function initAJAX()
{

var ajaxRequest;

try{
// Opera 8.0+, Firefox, Safari
   ajaxRequest = new XMLHttpRequest();
} catch (e){
    // Internet Explorer Browsers
    try{
       ajaxRequest = new ActiveXObject("Msxml2.XMLHTTP");
    } catch (e) {
      try{
        ajaxRequest = new ActiveXObject("Microsoft.XMLHTTP");
      } catch (e){
        // Something went wrong
        alert("You browser does not support AJAX!");
        return false;
      }
    }
}
return ajaxRequest;
}

http_save_sound=initAJAX();
http_get_sound=initAJAX();
function save_sound(what)
{
http_save_sound.open("GET", "sound-notify.php?f="+what, true);
http_save_sound.onreadystatechange = function()
   {
   if ((http_save_sound.readyState == 4) && (http_save_sound.status == 200))
      {
      if (http_save_sound.responseText=="0")
         alert("Sound notification is turned off.");
      else
         alert("Sound notification is set to "+http_save_sound.responseText);
      }
   }
http_save_sound.send("");
}

function get_sound(action)
{
http_get_sound.open("GET", "sound-notify.php", true);
http_get_sound.onreadystatechange = function()
   {
   if ((http_get_sound.readyState == 4) && (http_get_sound.status == 200))
      {
      if (action)
         {
         if (http_get_sound.responseText!="0")
            {
            var notif_sound = new Audio(http_get_sound.responseText);
            notif_sound.play();
            }
         }
      else
         {
         document.getElementById("sound_notify").value=http_get_sound.responseText;
         }
      }
   }
http_get_sound.send("");
}


5. Create sound-notify.php file in the root of your installation
Code:

<?php
include('libraries/afterlogic/api.php');
extract($_GET,EXTR_SKIP);
$oApiIntegratorManager = \CApi::Manager('integrator');
$oSettings =& CApi::GetSettings();
$sPrefix = $oSettings->GetConf('Common/DBPrefix');
$host = $oSettings->GetConf('Common/DBHost');
$user = $oSettings->GetConf('Common/DBLogin');
$pass = $oSettings->GetConf('Common/DBPassword');
$db = $oSettings->GetConf('Common/DBName');
mysql_connect($host,$user,$pass);
mysql_select_db($db);

$id=$oApiIntegratorManager->GetLogginedUserId();
if (isset($f))
   {
   mysql_query("update {$sPrefix}awm_settings set sound_notify='$f' where id_user=$id");
   echo $f;
   }
else
   {
   $res=mysql_query('select sound_notify from '.$sPrefix.'awm_settings where id_user='.$id);
   $row=mysql_fetch_assoc($res);
   echo $row['sound_notify'];
   }
?>


6. Alter templates/views/Settings/CommonSettingsViewModel.html
put
Code:

<div class="row">
  <span class="label" data-i18n="SETTINGS/COMMON_USE_SOUND" data-bind="i18n: 'text'"></span>
  <select id=sound_notify class="value input" onchange="save_sound(this.value)">
    <option value="0" data-i18n="SETTINGS/COMMON_USE_NO_SOUND"  data-bind="i18n: 'text'"></option>
    <option value="file1.wav">file1.wav</option>
    <option value="file2.wav">file2.wav</option>
    <!- put here as many files as you want -->
    <option value="fileN.wav">fileN.wav</option>
  </select><img src="play.png" width="20" onload="get_sound(0);" title="Play" onclick="a=new Audio(document.getElementById('notify').value);a.play()">
</div>

after
Code:


<div class="row">
  <span class="label" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_EVERY" data-bind="i18n: 'text'"></span>
  <select class="value input" data-bind="value: autocheckmailInterval">
    <option value="0" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_OFF" data-bind="i18n: 'text'"></option>
    <option value="1" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_1" data-bind="i18n: 'text'"></option>
    <option value="3" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_3" data-bind="i18n: 'text'"></option>
    <option value="5" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_5" data-bind="i18n: 'text'"></option>
    <option value="10" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_10" data-bind="i18n: 'text'"></option>
    <option value="15" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_15" data-bind="i18n: 'text'"></option>
    <option value="20" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_20" data-bind="i18n: 'text'"></option>
    <option value="30" data-i18n="SETTINGS/COMMON_AUTOCHECKMAIL_30" data-bind="i18n: 'text'"></option>
  </select>
</div>


7. Add localisation in the SETTINGS section of your language file:
Code:

COMMON_USE_NO_SOUND = "No sound notification"
COMMON_USE_SOUND = "Sound notification"


8. Upload sound files file1.wav ... fileN.wav to the root of your installation. Any sound file should do the job .

9. Switch to app.js instead of app-min.js

10. Alter static/js/app.js
place
Code:
                get_sound(1);

before the line
Code:
                App.desktopNotify(oParameters);



11. Find a suitable image for a play button (play.png) and place it in the root of your installation.

And the result looks as follows


To improve localisation, instead of alert one could use
Code:

App.Api.showReport(AfterLogicApi.i18n('SOME_SECTION/SOME_MESSAGE'));

and instead of title="..."
Code:

data-bind="customTooltip: 'SOME_SECTION/PLAY'"
Back to Top View Fonzie's Profile Search for other posts by Fonzie
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6104
Posted: 26 March 2015 at 6:18am | IP Logged Quote Igor

Quote:
Lets say there's ten emails in the thread, when you click on the number to expand the thread, all the messages in that thread are shown, along with the sender and the subject.

I would like to colour each one of the backgrounds of these to highlight them as being part of the thread, making them easy to distinguish as being part of the thread.

I am using the standard skin.


Oh I see. In skins/Default/styles.css file, locate the following bit:

Code:
.items_list .use_threads .threaded {
  background: #f9f8f6;


- that's background color of those messages under a thread.

Quote:
It's a great pity that for my question number2, thats not possible, I would have dumped my desktop client immediately, any plans for such a feature ?


While it's fairly easy to implement that one for desktop client which maintains local storage of emails, situation with WebMail is different as it accesses mails on the server directly, so getting information on multiple account means sending multiple requests to IMAP server, every single time. Thus, adding this feature can cause various performance-related issues.

And yes, we do plan to add a way to monitor multiple accounts, so that you could at least get a number of new messages for every account you have. But there's no ETA here as this is rather major overhaul of the product, due to the reasons mentioned above.

--
Regards,
Igor, AfterLogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6104
Posted: 26 March 2015 at 6:21am | IP Logged Quote Igor

webdbase2, oh wow, this is absolutely an awesome contribution! Thank you!

Would you please allow us to include this into the product? That would bring another nice feature to customers, and of course, it wouldn't be lost upon upgrades.

--
Regards,
Igor, AfterLogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 
webdbase2
Valued Community Member
Valued Community Member


Joined: 25 March 2015
Location: Bulgaria
Online Status: Offline
Posts: 81
Posted: 26 March 2015 at 7:05am | IP Logged Quote webdbase2

Igor wrote:
webdbase2, oh wow, this is absolutely an awesome contribution! Thank you!

Would you please allow us to include this into the product? That would bring another nice feature to customers, and of course, it wouldn't be lost upon upgrades.

--
Regards,
Igor, AfterLogic Support

Yes, absolutely, be my guest!
Just beautify it
I was planning on developing a plugin, but it would take me more time to get acquainted with your API, so I dared to break your code
It's almost ready. The idea is each user to upload his own file, which would be stored in the database.

I'm sorry for the Bulgarian localisation, but you'll get the idea.


and download or delete it later.



I just didn't have time to find out how to hook to the notification process.
Back to Top View webdbase2's Profile Search for other posts by webdbase2
 
webdbase2
Valued Community Member
Valued Community Member


Joined: 25 March 2015
Location: Bulgaria
Online Status: Offline
Posts: 81
Posted: 26 March 2015 at 7:57am | IP Logged Quote webdbase2

By the way, I'm a great fan of AfterLogic WebMail Lite, too.
I did the first Bulgarian localisation for v.6.4.3. and after that sent you updates for versions 6.5.0, 6.5.1, and 6.6.0.
Back to Top View webdbase2's Profile Search for other posts by webdbase2
 
webdbase2
Valued Community Member
Valued Community Member


Joined: 25 March 2015
Location: Bulgaria
Online Status: Offline
Posts: 81
Posted: 26 March 2015 at 2:45pm | IP Logged Quote webdbase2

One correction
the line in step 6
Code:

</select><img src="play.png" width="20" onload="get_sound(0);" title="Play" onclick="a=new Audio(document.getElementById('notify').value);a.play()">

should read
Code:

</select><img src="play.png" width="20" onload="get_sound(0);" title="Play" onclick="a=new Audio(document.getElementById('sound_notify').value);a.play()">

it's
('sound_notify')
not
('notify')

I corrected the post (Posted: 25 March 2015 at 1:08pm) in case someone doesn't want to bother reading down.
Back to Top View webdbase2's Profile Search for other posts by webdbase2
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide