1
DarthHH
outbox?
  • 2006/8/14 12:38

  • DarthHH

  • Just popping in

  • Posts: 16

  • Since: 2006/6/28


is there a module to add outbox for private messages?

2
davidl2
Re: oubox?
  • 2006/8/14 12:42

  • davidl2

  • XOOPS is my life!

  • Posts: 4843

  • Since: 2003/5/26



3
WarDick
Re: oubox?
  • 2006/8/14 13:26

  • WarDick

  • Just can't stay away

  • Posts: 890

  • Since: 2003/9/13


@DarthHH

Soon is a relative term.

If you want an outbox you might want to try Wanikoo's pm hack.
Urging XOOPS to be the Best It Can Be.
Richard......

4
davidl2
Re: oubox?
  • 2006/8/14 14:00

  • davidl2

  • XOOPS is my life!

  • Posts: 4843

  • Since: 2003/5/26


Wardick - the developer has been working hard on this, and he's currently testing the latest release on his site... only issue is getting the French translation - so it shouldnt be long before a new release

5
WarDick
Re: oubox?
  • 2006/8/14 14:58

  • WarDick

  • Just can't stay away

  • Posts: 890

  • Since: 2003/9/13


@davidl2

I was not referring to the new module you have pointed out.

I have no knowledge of it as I do not speak french.

If it has this feature - that is great news!

A PM module!
Urging XOOPS to be the Best It Can Be.
Richard......

6
davidl2
Re: outbox?
  • 2006/8/14 15:09

  • davidl2

  • XOOPS is my life!

  • Posts: 4843

  • Since: 2003/5/26


I'm struggling to use it at the moment.. but it is very impressive. (I was trying to translate it - but i've not enough time at the moment )

7
WarDick
Re: outbox?
  • 2006/8/14 22:20

  • WarDick

  • Just can't stay away

  • Posts: 890

  • Since: 2003/9/13


This looks like a great module for managing PM's and it is definitely need.

However, I do not see an outbox.

So, as I said try Wanikoo's.
Urging XOOPS to be the Best It Can Be.
Richard......

8
3lr0n
Re: outbox?
  • 2006/8/14 23:20

  • 3lr0n

  • Not too shy to talk

  • Posts: 167

  • Since: 2004/3/13


I found this code in the forums i think... i check it and work.. and have to add a link to outbox.php (in your root)

<?php

$xoopsOption
['pagetype'] = "pmsg";


include_once 
"mainfile.php";

if ( !
$xoopsUser ) {
    
$errormessage _PM_SORRY."<br />"._PM_PLZREG."";
       
redirect_header("user.php",2,$errormessage);
} else {
    include 
XOOPS_ROOT_PATH.'/header.php';
       
$pm_handler =& xoops_gethandler('privmessage');


    
$sql "SELECT * FROM ".$xoopsDB->prefix("privmessage")." where subject not like '[any subject you do not want to select]'
            and from_userid="
.$xoopsUser->getVar('uid')." order by msg_id";

    
//$result = $xoopsDB->query($sql);

//    $criteria = new CriteriaCompo();
//    $criteria->add(new Criteria('subject', '[Trisomy 18 Support]%', 'LIKE'));
//    $criteria->add(new Criteria( 'test%', 'subject', 'NOT LIKE'));

//    $pm_arr =& $pm_handler->getObjects($criteria);

    
$criteria = new CriteriaCompo();

    
$criteria1=new Criteria('from_userid'$xoopsUser->getVar('uid'));
    
$criteria2=new Criteria'subject''[Trisomy 18 Support]%''NOT LIKE');
    
$criteria->add($criteria1);
    
$criteria->add($criteria2);
    
$pm_arr =& $pm_handler->getObjects($criteria);

    
//$criteria->add(new Criteria('subject', '[Trisomy 18 Support]%', 'LIKE'));
    //$criteria2->add(new Criteria('uid', $uid), 'OR');

    //$criteria->add(new Criteria('from_userid', $xoopsUser->getVar('uid')));
    //$pm_arr =& $pm_handler->getObjects(criteria);
    //    $pm_arr =& $pm_handler->getObjects(new Criteria('subject', 'test', 'NOT LIKE'));
    //    $pm_arr =& $pm_handler->getObjects(new Criteria('subject', '[Trisomy 18 Support]'));


    // OLD ONE
    // $pm_arr =& $pm_handler->getObjects(new Criteria('from_userid', $xoopsUser->getVar('uid')));

//    if ( $xoopsUser->getVar('uid') == 1){
//        echo "Testing: <br><br>";
//        echo $pm_arr[2];
//
//        echo "<br><br>Finished Testing<br><br>";
//    }

    
echo "<h4 style='text-align:center;'>Bandeja de Salida</h4>

    <hr><a href='userinfo.php?uid="
$xoopsUser->getVar("uid")."'>"_PM_PROFILE ."</a>&nbsp;<span style='font-weight:bold;'>&raquo;&raquo;</span> <small>Outbox</small><br /><br /><table border='0' cellspacing='1' cellpadding='4' width='100%' class='outer'>n";
    echo 
"<form name='prvmsg' method='post' action='viewpmsg.php'>";
    echo 
"<tr align='center' valign='middle'><th><img src='images/download.gif' alt='' border='0' /></th><th>"_PM_TO ."</th><th>"_PM_SUBJECT ."</th><th align='center'>"_PM_DATE ."</th></tr>n";

    
$total_messages count($pm_arr);

    if ( 
$total_messages == ) {
        echo 
"<tr><td class='even' colspan='6' align='center'>"._PM_YOUDONTHAVE."</td></tr> ";
        
$display0;
    } else {
    
//    echo "<tr><td class='even' colspan='6' align='center'>Feature will be active shortly.</td></tr> ";
        
$display 1;
    }
//    if ( $xoopsUser->getVar('uid') == 1){
    
for ($i 0$i $total_messages$i++) {
        
$class = ($i == 0) ? 'even' 'odd';
        echo 
"<tr align='left' class='$class'>n";
        if (
$pm_arr[$i]->getVar('read_msg') == 1) {
            echo 
"<td valign='top' width='5%' align='center'><img src='images/read.gif' alt='"._PM_NOTREAD."' /></td>n";
        } else {
            echo 
"<td valign='top' width='5%' align='center'><img src='images/unread.gif' alt='"._PM_NOTREAD."' /></td>n";
        }
        
        
$postername XoopsUser::getUnameFromId($pm_arr[$i]->getVar("to_userid"));
        echo 
"<td valign='middle' width='10%'>";
        
// no need to show deleted users
        
if ($postername) {
            echo 
"<a href='userinfo.php?uid=".$pm_arr[$i]->getVar("to_userid")."'>".$postername."</a>";
        } else {
            echo 
$xoopsConfig['anonymous'];
        }
        echo 
"</td>n";
        if (
$pm_arr[$i]->getVar('read_msg') == 1) {
        echo 
"<td valign='middle'><a href='readoutbox.php?start=$i&amp;total_messages=$total_messages'>".$pm_arr[$i]->getVar("subject")."</a></td>";
} else {
        echo 
"<td valign='middle'><a href='readoutbox.php?start=$i&amp;total_messages=$total_messages'><b>".$pm_arr[$i]->getVar("subject")."</b></a></td>";
}
        echo 
"<td valign='middle' align='center' width='20%'>".formatTimestamp($pm_arr[$i]->getVar("msg_time"))."</td></tr>";
    }
//    }
    
if ( $display == ) {
        echo 
"<tr class='foot' align='left'><td colspan='6' align='left'><input type='button' class='formButton' onclick='javascript:openWithSelfMain("".XOOPS_URL."/pmlite.php?send=1","pmlite",450,380);' value='"._PM_SEND."' />&nbsp;</td></tr></form>";
    } else {
        echo 
"<tr class='bg2' align='left'><td colspan='6' align='left'><input type='button' class='formButton' onclick='javascript:openWithSelfMain("".XOOPS_URL."/pmlite.php?send=1","pmlite",450,380);' value='"._PM_SEND."' /></td></tr></form>";
    }
    echo 
"</table>";
    include 
"footer.php";
}
?>
Spanish Overclocking Community xoops based site : www.overclocking.es

9
DarthHH
Re: outbox?
  • 2006/8/18 13:43

  • DarthHH

  • Just popping in

  • Posts: 16

  • Since: 2006/6/28


thanks

Login

Who's Online

231 user(s) are online (131 user(s) are browsing Support Forums)


Members: 0


Guests: 231


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits