Search The ForumSearch   RegisterRegister  LoginLogin

AfterLogic WebMail Pro

 AfterLogic Forum : AfterLogic WebMail Pro
Subject Topic: Add links Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
vo2000
Newbie
Newbie


Joined: 01 October 2008
Online Status: Offline
Posts: 14
Posted: 08 May 2009 at 7:05am | IP Logged Quote vo2000

After I successfully logged in webmail pro php,how can I just put a simple html link on the top of menu bar which is having"xxx@xxx.com","contacts"and"calendar"? Which php or js file I should modify?

A simple html link=<a href=xxxxxx>xxx</a>

Thanks for any help
Back to Top View vo2000's Profile Search for other posts by vo2000
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6104
Posted: 11 May 2009 at 2:54pm | IP Logged Quote Igor

For AJAX version of WebMail Pro interface, modify class.webmail.js file. Let's assume you'd like to have a link to Google which opens in new window. Locate the following lines of code (approx. 1265):

Code:
var a = CreateChildWithAttrs(_calendarTab, 'a', [['href', CalendarUrl], ['target', '_top']]);
a.innerHTML = Lang.Calendar;
WebMail.LangChanger.Register('innerHTML', a, 'Calendar', '');


And add the following lines right after them:
Code:
_newTab = CreateChild(td, 'div');
_newTab.className = 'wm_accountslist_contacts';
var a = CreateChildWithAttrs(_newTab,'a',[['href','http://www.google.com/'],['target', '_blank']]);
a.innerHTML = 'Google';


This applies to both PHP and .NET versions of the product. Using this approach, you can add several links if you like.

As for classic HTML (non-AJAX) interface, modify the following section of classic/class_toolbarpanel.php:
Code:
$this->_accountSelect->doTitle($mailClassName)
.
$hideContacts
.


So that it looks like this:
Code:
$this->_accountSelect->doTitle($mailClassName)
.
$hideContacts
.'<span class="wm_accountslist_contacts"><a href="http://google.com/" target=_blank>Google</a></span>'.


The solution is provided AS IS, no warranty.

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


Joined: 28 April 2017
Location: Poland
Online Status: Offline
Posts: 26
Posted: 13 July 2018 at 1:27am | IP Logged Quote maxxiv1

How to do it in the version 7.7.9?
Back to Top View maxxiv1's Profile Search for other posts by maxxiv1
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6104
Posted: 13 July 2018 at 1:37am | IP Logged Quote Igor

You can modify templates/views/Common/HeaderViewModel.html file, insert your HTML code for custom links between the following two lines:

Code:
<!-- /ko -->

{%INCLUDE-START/Header-Middle/INCLUDE-END%}


To apply changes, be sure to purge data/cache/ directory content.

Also, there's more advanced approach which allows for adding custom screens with their own tabs:

Adding new tab to main menu

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


Joined: 28 April 2017
Location: Poland
Online Status: Offline
Posts: 26
Posted: 13 July 2018 at 2:09am | IP Logged Quote maxxiv1

Thank you! it works :)
Back to Top View maxxiv1's Profile Search for other posts by maxxiv1
 
harryking1234
Newbie
Newbie


Joined: 14 August 2019
Online Status: Offline
Posts: 0
Posted: 14 August 2019 at 12:15am | IP Logged Quote harryking1234

If the users are facing these kinds of linking issues with a Dart programming language then definitely check for a solution from Dart vs Javascript which would be effective for them.
Back to Top View harryking1234's Profile Search for other posts by harryking1234 Visit harryking1234's Homepage
 

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