[ABD] Send PM on Friend

Any abandoned MODs will be moved to this forum.

WARNING: MODs in this forum are not currently being supported or maintained by the original MOD author. Proceed at your own risk.
Forum rules
IMPORTANT: MOD Development Forum rules

WARNING: MODs in this forum are not currently being supported nor updated by the original MOD author. Proceed at your own risk.
Locked
User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

[ABD] Send PM on Friend

Post by blazes » Tue Jun 03, 2008 6:05 pm

MOD title: Send PM on Friend
MOD description: Sends somebody a PM when someone befriends them
MOD version: 0.4.1
phpBB version: 3.0.6

Current Version Notes: I've tested the 0.4.0 installation modx file with AutoMOD. I've added a 0.3.0->0.4.0 upgrade modx file. I've tested it once, however, not with AutoMOD.

Development stage: Beta

MOD Format: MODX

MOD download:http://github.com/blazes816/MODs/raw/ma ... /0.4.1.zip

Credits: Kevin Martin (DualFusion) for the send_friend_pm function which I slightly (very slightly) modified.

Features: When somebody befriends you, you receive a PM with a link to their profile and a link to befriend them.

Todo:
Send PM on friend deletion

Change Log:
  • Fix error where PM has link to add friend, even if the other user is already a friend
Taking feature suggestions.
Last edited by blazes on Fri Oct 09, 2009 9:14 pm, edited 11 times in total.
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

moustafamin
Registered User
Posts: 230
Joined: Thu Aug 30, 2007 8:10 am

Re: [Alpha] Send PM on Friend

Post by moustafamin » Tue Jun 03, 2008 11:08 pm

really cool hack

i need this so so much

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Alpha] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 2:12 am

Thanks.

I was brought to my attention that the MODX file was malformed, but it should be fixed now.
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

User avatar
Yukan
Registered User
Posts: 155
Joined: Mon Aug 27, 2007 5:06 pm
Location: http://localhost/

Re: [Beta] Send PM on Friend

Post by Yukan » Wed Jun 04, 2008 7:42 am

It just loads a white page when you do it. I double checked.

I did each part of the install correctly as said and it only loads a blank/white page.

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Beta] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 7:56 am

Where are you getting the blank page?
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Beta] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 8:03 am

I've solved the problem. Hang on just a minute and I'll give you the details on fixing it.
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Beta] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 8:10 am

Okay. To fix it do this:

Open: language/en/ucp.php

Find:
'FRIEND_PM_SUBJECT' => '%s wants to be friends!',
'FRIEND_PM_MESSAGE' => '<a href="memberlist.php?mode=viewprofile&u=%1$d">%2$s</a> has added you as his or her friend. <a href="ucp.php?i=zebra&add=%2$s">Add %2$s to your friends?</a>',
Replace with:
'FRIEND_PM_SUBJECT' =>'%s wants to be friends!',
'FRIEND_PM_MESSAGE' => '<a href="memberlist.php?mode=viewprofile&u=%1$d">%2$s</a> has added you as his or her friend. <a href="ucp.php?i=zebra&add=%2$s">Add %2$s to your friends?</a>',
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

timmo
Registered User
Posts: 45
Joined: Mon Apr 21, 2008 11:09 pm

Re: [Beta] Send PM on Friend

Post by timmo » Wed Jun 04, 2008 8:11 pm

it works perfect with mee

mee to faced the blank page

and what u add fixed it

now what about adding the avatar in the PM?

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Beta] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 8:37 pm

I'm not really sure where you meant for it to be. Did you mean like:
test has added you as his or her friend. Add test to your friends? (avatar)
And just have the avatar in there?
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

timmo
Registered User
Posts: 45
Joined: Mon Apr 21, 2008 11:09 pm

Re: [Beta] Send PM on Friend

Post by timmo » Wed Jun 04, 2008 8:54 pm

Image

that is what i got

i downloaded the hack from phpbb3modders

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Beta] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 8:59 pm

But where were you wanting the person's avatar to show at?

Also, you're not having any more problems are you?
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

timmo
Registered User
Posts: 45
Joined: Mon Apr 21, 2008 11:09 pm

Re: [Beta] Send PM on Friend

Post by timmo » Wed Jun 04, 2008 9:08 pm

i wanna the avatar right above the message text

i found one error now
it is during redirection page only
[img=http://img390.imageshack.us/img390/7445/3332dp9.th.jpg]

edite the link in th pm that leds to the profile is always leding to user id 0 wish is not exist

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Beta] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 9:17 pm

Open: includes/ucp/ucp_zebra.php

Find: if($mode == 'friends' && $data['add'][0] != ''){

Does the next like look like:

This:

Code: Select all

send_friend_pm($friend_to_be_id, $user->data['username'], $user->data['user_id']);
Or this:

Code: Select all

send_friend_pm($friend_to_be_id, $user->data['username']);
?

It should be the first, so if it's not, change it.

As for the avatar, I'll look into it. Let me know if your problem is solved.
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

timmo
Registered User
Posts: 45
Joined: Mon Apr 21, 2008 11:09 pm

Re: [Beta] Send PM on Friend

Post by timmo » Wed Jun 04, 2008 9:34 pm

the second line was in my code

i changed itbut nothing changed

but the other two errors i found now gone :?

User avatar
blazes
Registered User
Posts: 579
Joined: Mon Feb 20, 2006 7:20 am

Re: [Beta] Send PM on Friend

Post by blazes » Wed Jun 04, 2008 9:37 pm

I still gives the errors on the redirection page? Would you mind zipping up that file and includes/functions_privmsgs? Then I could try and find the problem, because I'm not having it.
Image
I'm lazy and don't check my MOD support threads very often. If you need help and I'm not replying in the thread, PM me and yell.

Locked

Return to “[3.0.x] Abandoned MODs”