xoops forums

wanikoo

Not too shy to talk
Posted on: 2004/11/26 7:59
wanikoo
wanikoo (Show more)
Not too shy to talk
Posts: 129
Since: 2003/12/27
#1

XOOPS PM(Private Message)-Hack

// XOOPS - PM(Private Message) Hack1.0

This is a XOOPS PM(Private Message)-Hack^^
I hope this hack helpful and useful to XOOPS-users^^

---With this hack,
You can use some PM-Boxs to manage your PMs^^
<RECEIVE>
INBOX( For New PMs[delete button])
READBOX(for PMs already read[delete button,save button])
RSAVEBOX(for saved PMs[delete button])
<POST>
OUTBOX(Posted PMs, not read or not deleted without reading by your partner[delete button])
SENTBOX(Posted PMs, read or deleted without reading by your partner[delete button,save button])
PSAVEBOX(saved PMs[delete button])

This hack is still a beta-version^^
(It tooks two days to make this hack^^...
So..maybe..a few bugs^^??If you find bugs,please inform to me( wani@wanisys.net)

<Upgrade Plan>
planing to add some other functions to this hack^^(someday..Maybe...^^)
filtering,reject, Max-limit for each box etc^^

Demo:

http://kjw0815.codns.com/wanisys/japanese/xoops/html/

Downloads:

http://www.wanisys.net/data/wanipmhack.zip


How to install

1, Open this file(/html/wanipmhack.sql) and execute the sql query on the file^^
( Use phpmyadmin...if you are DB-novice!!Please, watch out table prefix[xoops_])
2, Overwrite All files into proper directory!!
(You must back-up original files...before this hack!!!!)
3, Open this file(/html/language/{yourlanguage}/pmsg.txt)
4, Add the contents of pmsg.txt to pmsg.php.
5, That's all!! Enjoy this new PM system!!


PS:
If you want to add my new PM-Partner Search function to this hack,
please follow this link below^^

http://www.xoopscube.jp/modules/newbb ... hp?topic_id=6274&forum=14

If you want to send a welcome PM to your new member automatically, please follow this link below^^

http://www.xoopscube.jp/modules/newbb ... hp?topic_id=6253&forum=14

And my other hacks
# Redirection logout Hack,newlogout^^
http://www.xoopscube.jp/modules/newbb ... hp?topic_id=6237&forum=14

#User Menu Block Hack( How to display {Welcome, ID!, Rank (title and image), Level, Group(s), Last login})
http://www.xoopscube.jp/modules/newbb ... hp?topic_id=6136&forum=14

#Online Status Block Hack(How to display {Latest,NewToday,NewYesterday,Total Members})
http://www.xoopscube.jp/modules/newbb ... hp?topic_id=6119&forum=14



^^//...(^^)...

From wani[wani@wanisys.net]

the most educational site, wanisys.net [ http://www.wanisys.net ]

Herko

XOOPS is my life!
Posted on: 2004/11/26 8:15
Herko
Herko (Show more)
XOOPS is my life!
Posts: 4238
Since: 2002/2/4 1
#2

Re: XOOPS PM(Private Message)-Hack

Very very nice features Can you submit this hack to the XOOPS Core Hack/patch Submission Tracker, so we can review the code and add it to the core? Thanks!

Herko

wanikoo

Not too shy to talk
Posted on: 2004/11/26 9:59
wanikoo
wanikoo (Show more)
Not too shy to talk
Posts: 129
Since: 2003/12/27
#3

Re: XOOPS PM(Private Message)-Hack

Quote:

Herko Coomans wrote:
Very very nice features Can you submit this hack to the XOOPS Core Hack/patch Submission Tracker, so we can review the code and add it to the core? Thanks!

Herko


Thanks for your reply
Umm..
I have submitted this hack^^
Have a nice day^^
bye~~

irmtfan

Module Developer
Posted on: 2004/11/26 10:52
irmtfan
irmtfan (Show more)
Module Developer
Posts: 3419
Since: 2003/12/7
#4

Re: XOOPS PM(Private Message)-Hack

AH
very amasing and great
just i must say something about outbox :


Quote:
OUTBOX(Posted PMs, not read or not deleted without reading by your partner[delete button]

auto notify pms must send from someone( for example webmaster) so there is a LOT and LOT pms in the outbox. could you put a NOT LIKE ( 'from' , 'subject') for outbox?
many thanks

wanikoo

Not too shy to talk
Posted on: 2004/11/26 11:51
wanikoo
wanikoo (Show more)
Not too shy to talk
Posts: 129
Since: 2003/12/27
#5

Re: XOOPS PM(Private Message)-Hack

Quote:
auto notify pms must send from someone( for example webmaster) so there is a LOT and LOT pms in the outbox. could you put a NOT LIKE ( 'from' , 'subject') for outbox?
many thanks


Normally,people are interested in the status of SENTBOX, not OUTBOX
and ,I think, they can estimate the status of OUTBOX by checking SENTBOX.

As you know, a lot of PMs in one box...doen't mean the overload of PM system...
because one PM...must exist in one box of 3 boxs(when post or when receive)...not existing in two or three boxs at the same time
until both of them(Sender and Receiver) delete one PM ( to_delete=1 and from_delete=1 means real delete of one PM...so..It can't happen^^)
So a lot of PMs in OUTBOX means the minus of that amount in SENTBOX.
^^Umm...
I think Exception is not good in this PM system^^

irmtfan

Module Developer
Posted on: 2004/11/26 12:04
irmtfan
irmtfan (Show more)
Module Developer
Posts: 3419
Since: 2003/12/7
#6

Re: XOOPS PM(Private Message)-Hack

i just said that for this reason:
if a lot of pms in each link the load of them take too many times
so if u put page number for that i think its enough
and another feature is set the order for pms ( descending / ascending )
by the way i use this hack in my site now.IT WORKS AND im going to do other your great hacks

wanikoo

Not too shy to talk
Posted on: 2004/11/26 12:17
wanikoo
wanikoo (Show more)
Not too shy to talk
Posts: 129
Since: 2003/12/27
#7

Re: XOOPS PM(Private Message)-Hack

If you hate the congestion of OUTBOX, you can post a PM with from_delete=1....It means... you post and delete a PM at the same time.
And still your partner can receive your PM because still to_delete=0^^
So you can solve this problem if you use $pm_handler->setFromdelete($pm) at the same time when you post a PM($pm_handler->insert($pm)).

irmtfan

Module Developer
Posted on: 2004/11/26 13:21
irmtfan
irmtfan (Show more)
Module Developer
Posts: 3419
Since: 2003/12/7
#8

Re: XOOPS PM(Private Message)-Hack

Quote:
you can post a PM with from_delete=1

i think this can be with more hacks in files
i explain my real problem for u:
i have 8 moderator at my site so we create an id "Your help" and users must contact with this id for thier problems ( i know the help desk is the solution )
and we send auto notify pms with this id too
and now with your great hack send " welcome to new registerd users " also with this id.
so the " sentbox " has big size and the " outbox" has Tremendous size and anyone dont going to that

wanikoo

Not too shy to talk
Posted on: 2004/11/26 14:04
wanikoo
wanikoo (Show more)
Not too shy to talk
Posts: 129
Since: 2003/12/27
#9

Re: XOOPS PM(Private Message)-Hack

haha...You're really in a pickle. ,,,,in a special pickle(--;;...unexpected^^
I think your case will make me add page, search and sort function to each box in next version!!^^
So hard .....--;;
Ok^^I will try...^^..in the nex version^^
Have a nice time
bye^^I have to sleep^^(because GMT+09:00)

script_fu

Friend of XOOPS
Posted on: 2004/11/26 14:27
script_fu
script_fu (Show more)
Friend of XOOPS
Posts: 1494
Since: 2002/12/27
#10

Re: XOOPS PM(Private Message)-Hack

Woa... Been looking for something like this for awhile.

Thank you...