AIRMail Beta 2.1

Here you go Scott. Use at your own risk. As I said, we are both using different templates. You should be good to go on my new mail menu though no matter what skin you are using.

As far as the you got mail sounds go, look in the check_mail file to change sounds. I included my sounds folder.

I can not be held responsible for your use of these files. I hope you can use them or get some good info from them and code up your own. Enjoy!

Ok So I am out of attachment quota. I will PM you a link. Please PM me when you grab the file so I can remove it.

Ray

Hi Dave. Quick question for you if I may. I edited the mail_sentitems.tpl file. I wanted it to NOT show the message sent and instead make the subject line a link to the message. I got the subject to work as a message, but every time I go to click on the subject as a link, it tells Me that I can not view someone else’s mail.

I am not sure what code I need to include and where at to view it that way. The issue I was having that prompted me to try this method was, some posts are extremely long and that page is WAY long. And with it bunching the entire message up on the right side of the page was making it REALLY long too.

I thought of trying to format the page like a forum post where it shows all the important info on the left and the post on the right, but struck out there too. I had errors flying all over the place. I personally never look at the sent items folder, but I began catching hell about it from other pilots. I am sure it is a simple fix and I am just being to dam blonde to figure it out. I been at it about 4 days now. I figured I might finally ask about it. I try until my hair gets ripped out before I ask.

Thanks for the read.

Ray

**EDIT**

On second thought, I now know why it is doing that and it most likely is not going to work the way I need it to. I will just have to re skin the table to mimic a forum looking post. That should solve the long drawn out page.

I was looking at this the other day, i didnt manage to get it to work either, the closest i came was to hover over the subject and ecco out to the url the message

Right now Mark, I am game to try anything. As I said previously, I had pondered even skinning it to look like a forum post. All the date and other info on the left and the post on the right.

If you know any nifty tricks I can try for the mean time that looks ok, fill me in. I have tried everything short of a recode on this one page. All the other airmail pages are top notch though.

Ray

There must be a way to get this to display in a popup or something. But im stuck as you at the moment with this one

Ok, just so I am following… In the sent items display you just want the subject, date, and who you sent it to; and you want to click on the subject as a link to view the body… Am I close?

Yeah Dave, you are spot on. I did get the subject to be a link, but the way the Airmail sees it, when the link (subject) is clicked, it thinks I am trying to open someone else’s Airmail. I understand why it sees it that way, I just can’t figure a way around it.

It really is fine as is, BUT if people keep replying to the Airmail over and over, it becomes VERY long and drawn out. I know it is not a bug and the Airmail is working as class act as it was designed to. I guess it is more of a want than a need.

Yes i agree like i said up a bit i managed to echo out the sent message to the subject line so if you hover over the url is the message but just couldnt get it to display in another page or popup.

You got it one more step then what I did then Mark.

I found a decent work around for this for the time being. I simply removed the message part from the heading and dropped the colspan down to make it look right. Then I added in the message part below the rest in standard table cell. Works out quite nice.

I found a decent work around for this for the time being. I simply removed the message part from the heading and dropped the colspan down to make it look right. Then I added in the message part below the rest in standard table cell. Works out quite nice.

Care to share the code

Care to share the code

As soon as I get back on my pc I will. On my cell phone right now

Hi Mark. Here is my change. I am sure it is not the cleanest in the world and there is a better way to do it, but this was my quick dirty fix that worked and made the guys happy.

<?php
//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-2010, David Clark
//@license http://creativecommons.org/licenses/by-nc-sa/3.0/
?>
<style type="text/css">
   .left {
       width: 200px;
       float: left;
       min-height: 300px;
       padding: 15px 0 15px 5px;
   }
   .right {
       float: left;
       margin-left: 10px;
   }
</style>
<div>
   <?php Template::Show ('mail_menu.tpl'); ?>
</div>
<div>
   <center>
       <table width="100%" cellspacing="1" cellpadding="5" border="1">
           <tr>
               <td colspan="2"><img src="<?php echo SITE_URL?>/mailimages/airmail_logo.png" border="0" alt="AIRMail" /></td>
               <td colspan="3" align="center"><b>AIR</b>mail sent items for <b><?php echo Auth::$userinfo->firstname.' '.Auth::$userinfo->lastname.' '.$pilotcode; ?></b></td>
               <td colspan="1" align="center"><img src="<?php echo SITE_URL?>/mailimages/mail_small.png" border="0" alt="AIRMail" /></td>
           </tr>
           <tr bgcolor="#cccccc">
               <td colspan="7" align="center"><img src="<?php echo SITE_URL?>/mailimages/env_closed.gif" border="0" alt="Unread"> = message unread | <img src="<?php echo SITE_URL?>/mailimages/env_open.gif" border="0" alt="Read">= message read</td>
           </tr>
           <tr bgcolor="#cccccc">
               <td align="center"><b>Status</b></td>
               <td align="center"><b>To</b></td>
               <td align="center"><b>Subject</b></td>
               <td align="center"><b>Date sent</b></td>
               <td align="center"><b>Time sent</b></td>
               <td align="center"><b>Remove From<br />Sent List</b></td>
           </tr>
		<?php
       if(!$mail) {
           echo '<tr><td colspan="7">You have no sent messages.</td></tr>';
       }
       else {
           ?>
   <?php
   foreach($mail as $test) {
                   if ($test->read_state=='0') {
                       $status = 'env_closed.gif ';
                   }
                   else {
                       $status = 'env_open.gif';
                   }
                   ?>
                   <?php $user = PilotData::GetPilotData($test->who_to); $pilot = PilotData::GetPilotCode($user->code, $test->who_to); ?>

           <tr bgcolor="#eeeeee">
               <td align="center"><img src="<?php echo SITE_URL?>/mailimages/<?php echo $status;?>" border="0" /></td>
               <td align="center"><?php
                   if ($test->notam=='1') {
           echo 'NOTAM<br />(All Pilots)';
       }
       else {
           echo $user->firstname.' '.$user->lastname; ?><br /><?php echo $pilot;
                           } ?>
               </td>
               <td align="center"><?php echo $test->subject; ?></td>
               <td align="center"><?php echo $test->date; ?></td>
               <td align="center"><?php echo $test->time; ?></td>
               <td align="center"><a href="<?php echo SITE_URL ?>/index.php/Mail/sent_delete/?mailid=<?php echo $test->id;?>"><img src="<?php echo SITE_URL?>/mailimages\delete.gif" alt="Delete" border="0"/></a></td>
           </tr>
		<tr bordercolor="eeeeee">
		    <td colspan="7"align="center"><?php echo $test->message; ?></td>
		</tr>

   <?php
   }
}
?>	
       </table>
   </center>
       <br />
</div>
<br />
<center><b><font size="1.5px">AIRmail © 2009 <a href="http://www.simpilotgroup.com">simpilotgroup.com</a></font></b></center>
<br />

You will have to fix the opening two div tags if you still use the default menu. I have a custom menu so I got rid of the div classes.

Cheers Ray working a treat

I dont know why i didnt think about adding an extra row, what a plank

Cheers Ray working a treat

I dont know why i didnt think about adding an extra row, what a plank

Well, to be honest, I never thought about it either. I was just siting here staring off in to space and I was suddenly like Duhhhhh! Why not add a extra row Ray? Hell it might work…and it did. Like I said, it is a dirty fix, but it works.

Glad it worked out for ya.

Now I am working on a delete all function for it. I find my self getting carpel tunnel trying to delete a mass amount of mail. I have a ll the tick boxes working and in place and a delete all button, but for some reason I can not get it to delete the mails from the system.

Well after many failed attempts, I am not sure what I was doing wrong. I could get the button to work when I clicked check all, but when I clicked the delete all button, it would never work. If any of you php/sql wizards would like to have a try at it, that would be the cats ass!

I have put the Delete All option on hold momentarily. The date the mail is sent is showing as yyyy/mm/dd in the Inbox. I found this in the inbox.tpl file

<?php echo $data->date; ?>

Is that server date? And if so how can I make the airmail show as mm/dd/yyyy instead?

I tried to grab some code from the forum addon and make it work but it was a slight disaster.

Good day,

Could someone assist please…

I am on the latest phpvms 2.1.934

I tried installing AIRMail2 and i encountered the following message

“Warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, ‘Mail::inbox’ was given in /home5/XXXXXX/public_html/PIREP/core/classes/MainController.class.php on line 218”

I guess i did install it correctly and the SQL commands were executed without errors.

Your help are much appreciated

Thank you

This is the second time today I have seen this pop up. I have just downloaded the copy of this module off of the site and installed it on a fresh install of ver934 without issue. Are you using the base template? if not try switching back to the crystal template and see if the module works and let me know.