Jump to content

Recommended Posts

Posted

Is there any way to easily add code (does it have to be bootstrap), to a Mail navigation like the shout box indicator here on the forums?

See image below:

http://screencast.com/t/fy5Lasts

I am using SimPilot's AirMail module and want to add a Navigation Link, (see below) to show the number of AirMail to be read! I want to add it to a none bootstrap skin I am working on.

http://screencast.com/t/uA39Shbw

But a smaller number indicator like the ShoutBox one!

Is this difficult to add to his AirMail module?

Thanks!

Posted

Yeah when I get mail (the number of messages would be great) or just an indicator that I have mail without the number right next to my AirMail link, if the number is more difficult to code :) I was wanted to learn to be able to do it myself just to learn coding :) But if someone knows how to, or can guide me in the right direction to do it myself so I can learn, it would be appreciated. Not something I have to have just wanted to either learn how to do it, or see if someone could code it for me so I can learn from the code.

You know the SimPilot AirMail module comes with an flash mailbox if you have mail but I don't want to use that! Even just a small RED or GREEN tiny box would be fine. Something to indicate New Mail is all I am looking for really, the number of messages is a bonus!

Hope that made sense :)

Posted

I have mine to show a number, not red.

Copy this and replace your whole mail_check file. Make a back up copy first.

<?php
//AIRMail3
//simpilotgroup addon module for phpVMS virtual airline system
//
//simpilotgroup addon modules are licenced under the following license:
//Creative Commons Attribution Non-commercial Share Alike (by-nc-sa)
//To view full icense text visit http://creativecommons.org/licenses/by-nc-sa/3.0/
//
//@author David Clark (simpilot)
//@copyright Copyright (c) 2009-2011, David Clark
//@license http://creativecommons.org/licenses/by-nc-sa/3.0/
?>
<center>
<?php
if ($items > 0)
{

echo ' '.$items.' Message(s)';

}
else
{
echo 'Mail';
}
?>
</center>

Posted

I am going to try your's next. This is what I came up with and still working on it!

Not pretty but it works!

New Mail:

http://screencast.com/t/jPG9GPYVMrV

No Mail: (looking for the same envelope as New Mail with the red flag down, I saw it when I got the new mail icon and didn't down load it )

http://screencast.com/t/ucFM77SDNi

Getting ready to try yours!

And this is yours flyalaska, Awesome! Thanks so much! Changed font to RED, can't get the number RED breaks the code!

New Messages:

http://screencast.com/t/JnSJhZX1qyK

No Mail:

http://screencast.com/t/YiB75rh4K

What's cool is that both links are clickable! Very nice, once again Thanks! Might try to combine the two codes!

Posted

Back Up! Back Up! Back up!

The original mail_check.tpl file and the images before making these changes!

Here is my code. You will have to grab images yourself and name them new_mail.gif and no_mail.gif (have to be gif's or change code)! And put them in the core/modules/Mail/mialimages folder!

Code edited for mail_check.tpl:

<?php

//AIRMail3

//simpilotgroup addon module for phpVMS virtual airline system

//

//simpilotgroup addon modules are licenced under the following license:

//Creative Commons Attribution Non-commercial Share Alike (by-nc-sa)

//To view full icense text visit http://creativecommo...s/by-nc-sa/3.0/

//

//@author David Clark (simpilot)

//@copyright Copyright © 2009-2011, David Clark

//@license http://creativecommo...s/by-nc-sa/3.0/

?>

<left>

<?php

if ($items > 0)

{

echo '<img src="'.SITE_URL.'/core/modules/Mail/mailimages/new_mail.gif" border="0" />';

}

else

{

echo '<img src="'.SITE_URL.'/core/modules/Mail/mailimages/no_mail.gif" border="0" />';

}

?>

</left>

Changed the center alignment to left, took out the <br>, and added the no_mail.gif image! Still working on my alignment and images I like!

No Mail:

http://screencast.com/t/yUN5bgUSYz

New Mail:

http://screencast.com/t/pk3MlYnRE4M

Thanks to SimPilot for the original code!

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...