[ABD] Highway Referral Invitation MOD - 0.1.0c

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
wowforum
Registered User
Posts: 17
Joined: Tue Jan 22, 2008 5:36 am

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by wowforum »

As I go with the installation:

About this MOD
Title:
Highway Referral Invitation MOD

Description:
This mod adds the ability for users to invite friends via email, and keeps track of how many referrals they have. -- Adds a field to registration page which allows new users to enter in the member who referred them.
Gives the ability to use strictly invitations for registration on the board.
Admin can limit the number of allotted invitations per user.
Integrates with Handyman’s Cash MOD

Version:
0.1.0c

Installation Level:
Easy

Installation Time:
~10minutes

Author
Username:
Highway of Life
Email:
highwayoflife@gmail.com
Name:
David Lewis
WWW:
http://startrekguide.com

Files to Edit
includes/constants.php,
includes/ucp/ucp_register.php,
memberlist.php,
styles/prosilver/template/memberlist_body.html,
styles/prosilver/template/memberlist_view.html,
styles/prosilver/template/ucp_register.html,
styles/prosilver/theme/stylesheet.css
Included Files
root/language/en/mods/referral_mod.php,
root/referral.php,
root/scripts/auto_complete.js,
root/styles/prosilver/theme/autocomplete.css,
root/styles/prosilver/theme/images/as_pointer.gif,
root/styles/prosilver/theme/images/ul_corner_tr.gif,
root/styles/prosilver/theme/images/ul_corner_br.gif,
root/styles/prosilver/theme/images/ul_corner_tl.gif,
root/styles/prosilver/theme/images/ul_corner_bl.gif,
root/styles/prosilver/theme/images/hl_corner_br.gif,
root/styles/prosilver/theme/images/hl_corner_bl.gif,
root/styles/prosilver/theme/images/hl_corner_tl.gif,
root/styles/prosilver/theme/images/hl_corner_tr.gif

--------------------------------------------------------------------------------

Disclaimer
For security purposes, please check: http://www.phpbb.com/mods/ for the latest version of this MOD. Downloading this MOD from other sites could cause malicious code to enter into your phpBB Forum. As such, phpBB will not offer support for MODs not offered in our MODs database, located at: http://www.phpbb.com/mods/

Author Notes
Features and planned features:
Features planned in first released version of the Referral Invitation MOD:
Referral Features:
Field on registration page that allows a user registering to enter the username of a current user
Every time a referral is added for a user, their referral count increases
The board will keep track of who referred who
A widget can be displayed anywhere showing the top 10 users with the most successful referrals
A widget can be displayed anywhere showing who last referred who and a link to invite YOUR friends
Option to allow referred users to become friends upon successful referral


Invitation Features:
User can enter the emails of users they wish to invite
The board will keep track of the status of every invitation
Invitation Sent Status - with an option to send a reminder.
User Joined
User is active (made at least 1 post)
User visited (but did not join) - with an option to send a reminder.
User can have a limited number of invitations or unlimited
If the user has more than one invitation remaining, they can enter more friends emails to invite.
Invitations can expire after a set amount of time, and the invitation will be awarded back to the user.
Administrator can set the limit for invitations and assign additional invitations to groups or users manually
Administrator can revoke the permission for a user to use the invitation system -- useful if a user abuses it.
Ability to disable board registration, in which case an invitation key would be required to register. -- for private boards
Administrator can set the format of the invitation e-mail, or use a default template provided in multiple languages.
Memberlist in ACP will show how users with the most invitations left, and the users who have depleted their invitation count. This is useful if an Admin needs to assign users more invitations to pass out.
Users can donate invitations to other users
If a user is inside of a group, and they have permission to invite others to that group, the user invited will be automatically added to the group upon successful invitation. -- useful to provide group or forum specific invitations.
Option to set number of additional invitations awarded to users based on number of successful invitations
Option to set number of additional invitations awarded to users based on post count
Administration options will be included for all of these features, so you can set the invitation to be extremely simple, or utilize ALL of the features at your option.
MOD History
2007-11-21- Version 0.1.0c

Added prosilver theme files and edit instructions

Added constant for invitations table

2007-11-20- Version 0.1.0

First Beta Release

License
This MOD has been licensed under the following license:

http://opensource.org/licenses/gpl-license.php GNU General Public License v2

Other Notes
Before adding this MOD to your forum, you should back up all files related to this MOD

This MOD was designed for phpBB3.0.RC7and may not function as stated on other phpBB versions. MODs for phpBB3.0 will not work on phpBB2.0 and vice versa.

This MOD is development quality. It is not recommended that you install it on a live forum.

English Support
English support can be obtained at http://www.phpbb.com/mods/ for released MODs.


--------------------------------------------------------------------------------
File Copy

Copy: root/language/en/mods/referral_mod.php
To: language/en/mods/referral_mod.php

Copy: root/referral.php
To: referral.php

Copy: root/scripts/auto_complete.js
To: scripts/auto_complete.js

Copy: root/styles/prosilver/theme/autocomplete.css
To: styles/prosilver/theme/autocomplete.css

Copy: root/styles/prosilver/theme/images/as_pointer.gif
To: styles/prosilver/theme/images/as_pointer.gif

Copy: root/styles/prosilver/theme/images/ul_corner_tr.gif
To: styles/prosilver/theme/images/ul_corner_tr.gif

Copy: root/styles/prosilver/theme/images/ul_corner_br.gif
To: styles/prosilver/theme/images/ul_corner_br.gif

Copy: root/styles/prosilver/theme/images/ul_corner_tl.gif
To: styles/prosilver/theme/images/ul_corner_tl.gif

Copy: root/styles/prosilver/theme/images/ul_corner_bl.gif
To: styles/prosilver/theme/images/ul_corner_bl.gif

Copy: root/styles/prosilver/theme/images/hl_corner_br.gif
To: styles/prosilver/theme/images/hl_corner_br.gif

Copy: root/styles/prosilver/theme/images/hl_corner_bl.gif
To: styles/prosilver/theme/images/hl_corner_bl.gif

Copy: root/styles/prosilver/theme/images/hl_corner_tl.gif
To: styles/prosilver/theme/images/hl_corner_tl.gif

Copy: root/styles/prosilver/theme/images/hl_corner_tr.gif
To: styles/prosilver/theme/images/hl_corner_tr.gif


I dont see my scripts/auto_complete.js installed in my PHPbb3. I did not saw a folder calleds scripts.
wowforum
Registered User
Posts: 17
Joined: Tue Jan 22, 2008 5:36 am

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by wowforum »

Im getting an error after installing Highway Referral Invitation MOD - 0.1.0c for PHPBB3

When I click register, it gives me a error on line 467: Parse error: syntax error, unexpected ';' in D:\home\mysite.com\wwwroot\phpbb\includes\ucp\ucp_register.php on line 467



// Highway of Life Referral MOD
add_referral($user_id, $referral_username);
// End Referral MOD
ghettowboy
Registered User
Posts: 216
Joined: Tue Jun 12, 2007 3:53 pm

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by ghettowboy »

hows the move goin HOL... and any good news on this??
CASSIOPEA
Registered User
Posts: 12
Joined: Sun Aug 29, 2004 7:44 pm

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by CASSIOPEA »

any news on this project? I found the beta pretty useless, but i think the final version may rule.
User avatar
Highway of Life
Former Team Member
Posts: 6048
Joined: Wed Feb 02, 2005 5:41 pm
Location: Seattle, WA
Name: David Lewis
Contact:

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by Highway of Life »

CASSIOPEA wrote:any news on this project? I found the beta pretty useless, but i think the final version may rule.
Its waiting for me to get settled in the new house before I continue development. ;)
ghettowboy wrote:hows the move goin HOL... and any good news on this??
Move went well... trying to catch up on lost hours from work and unpack, along with all the snow we’ve gotten: (details)
wowforum wrote:Im getting an error after installing Highway Referral Invitation MOD - 0.1.0c for PHPBB3

When I click register, it gives me a error on line 467: Parse error: syntax error, unexpected ';' in D:\home\mysite.com\wwwroot\phpbb\includes\ucp\ucp_register.php on line 467
Sounds like you made an incorrect edit during installation, lets see lines 450-480 of that file. :)
wowforum wrote:I dont see my scripts/auto_complete.js installed in my PHPbb3. I did not saw a folder calleds scripts.
First, no need to paste all that info in your post. ;)
Simply create the /scripts/ directory. :P
ian wrote:From what I can tell, this mod probably supplies a lot of that functionality. Correct me if I'm wrong though. Thanks.
It would not do that exactly though. -- It’s an invitation system to invite users to your board/forum.
DJ Jonny wrote:Is this mod going to be compatable for subsilver ?
In a later Beta, yes.
elazard wrote:i ve seen the mod should be working on phpbb3 gold well thats great but does the option for registering only with invitation is already up? and the one for group invitation? is the last one activable in the acp or always working?
Not yet. The features are in place, but invitations are not yet activated. -- That will come in a later Beta. :)
tinkerbell1 wrote:Hi, I am having trouble figuring out where the users send email invitations
Again, that feature is not activated yet... later beta. ;)
bulldogg wrote:is there an admin panel module or anything for this?
Not yet. -- Coming in a later beta.
Panaflakin wrote:How can i keep track of who users refer an user?
It keeps track already in the database. Later there will be “widgets” or pages of stats that you can review for more detail.
wingnut144 wrote:So, has this mod progressed to the point where I can actually invite users to a forum yet?

Or are we still waiting for some functionality to be added??
Mostly waiting for me to finish programming that part and activating it, those features are not yet active.
yoursforum.com wrote:Hi,
after mod installation whenever trying to register,following error coming, how could i solve it!?

SQL ERROR [ mysql4 ]
Column 'user_id' cannot be null [1048]

An SQL error occurred while fetching this page. Please contact the Board Administrator if this problem persists.

waiting for your kind reply.
thanks
This is fixed in the next Beta -- All will function normally, despite the error. -- It’s mostly just annoying to users who don't have a referral.
UnitedWeFall wrote:Ah.. just noticed there's no files or instructions included for subsilver2.. Is that planned for future versions?
That is correct. These instructions will be included in the next Beta. :)

Did I miss anyone? :P
The phpBB Weekly Podcast - Discussing the developments of phpBB4 and beyond.

New to phpBB3? Want to learn about programing?
Visit phpBB Academy at StarTrekGuide to learn how.
okcorp
Registered User
Posts: 11
Joined: Sat May 20, 2006 8:02 am

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by okcorp »

Column 'user_id' cannot be null
annoing mistake

When it will be fixed?
Maybe no nead to wait to next beta, maybe it will be a patch?
00christian00
Registered User
Posts: 6
Joined: Sat Dec 29, 2007 2:35 pm

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by 00christian00 »

okcorp wrote:
Column 'user_id' cannot be null
annoing mistake

When it will be fixed?
Maybe no nead to wait to next beta, maybe it will be a patch?
I remember i fixed that but i don't remember where i did modify.
Try using this function,it should be that the problem:

Code: Select all

function add_referral($user_id, $referral_username = '', $invite_key = false)
{
	global $db;

	if ($invite_key)
	{
		$sql = 'SELECT invite_id, user_id, invite_key, invite_user_id, invite_session_id
				FROM ' . INVITATIONS_TABLE . "
				WHERE invite_key = '" . $db->sql_escape($invite_key) . '"';
		$result = $db->sql_query($sql);
	}
	else if ($referral_username)
	{
		$sql = 'SELECT user_id, user_invitations, user_referrals
				FROM ' . USERS_TABLE . "
				WHERE username_clean = '" . $db->sql_escape(utf8_clean_string($referral_username)) . "'";
		$result = $db->sql_query($sql);
		$rowset = $db->sql_fetchrowset($result);
		$row = $rowset[0];
		$db->sql_freeresult($result);
		unset($rowset);

		if ($row)
		{
			$row['user_referrals']++;
			$sql = 'UPDATE ' . USERS_TABLE . '
					SET user_referrals = ' . $row['user_referrals'] . '
					WHERE user_id = ' . $row['user_id'];
			$db->sql_query($sql);
		}
	}

	$sql_ary = array(
		'user_id'			=> $row['user_id'],
		'invite_user_id'	=> $user_id,
		'invite_status'		=> INVITED_USER_JOINED,
	);

	if (!$invite_key && $referral_username)
	{
		$db->sql_query('INSERT INTO ' . INVITATIONS_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary));
	}
	else
	{
		// not in use yet.
	}
}
Replace the one in referral.php with this one.
Onion Club official english website :
http://www.onion-club.net/
gi2m0
Registered User
Posts: 14
Joined: Sat Feb 02, 2008 3:31 pm

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by gi2m0 »

i've installed this mod successfully without any errors or issues....

i assume that thee will be some time before people can actually invite others......when will that be???

thanks,
gizmo
dunv007
Registered User
Posts: 31
Joined: Mon Feb 11, 2008 8:44 am

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by dunv007 »

hi bro,, seems a vey nice mod and one of the finest mod i have ever seen,,bro can u plzz complete the rest of mod and make it a stable one,, so that we users can usse it,,this is a reqest from my side,,, i need this mod very urgent,, but as its in a beta stage ,, whatt can we do,,,plzz bro can u make a final release for this sooon,,,

thnks anyways for such a nice mod
User avatar
Highway of Life
Former Team Member
Posts: 6048
Joined: Wed Feb 02, 2005 5:41 pm
Location: Seattle, WA
Name: David Lewis
Contact:

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by Highway of Life »

Sure thing, but can you use whole words and a few less commas please. ;)
The phpBB Weekly Podcast - Discussing the developments of phpBB4 and beyond.

New to phpBB3? Want to learn about programing?
Visit phpBB Academy at StarTrekGuide to learn how.
campod
Registered User
Posts: 18
Joined: Fri Nov 24, 2006 10:50 pm

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by campod »

Yeah, there is a whole world of phpBB3 users waiting for this mod. Please see if you can find the time to finish it ;)
User avatar
wingnut144
Registered User
Posts: 595
Joined: Thu Jan 20, 2005 4:52 pm
Location: Boise, ID
Contact:

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by wingnut144 »

campod wrote:Please see if you can find the time to finish it ;)
Gee, give the guy a break........ :roll:
User avatar
geeklife
Registered User
Posts: 172
Joined: Tue Jan 29, 2008 1:13 am

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by geeklife »

I have installed this mod. However I noticed on the first image in this thread when you enter a letter of a username a auto-pop-up should appear listing possible usernames as the referrer. I am NOT seeing that with our install.

The memberlist page does have the referral column with listings of referral numbers. On the registration screen the field does show to enter the username of who referred such person. In the User profile page you can see how many referrals someone has. So far so good.

I have a few questions as well.
A widget can be displayed anywhere showing the top 10 users with the most successful referrals
A widget can be displayed anywhere showing who last referred who and a link to invite YOUR friends
Option to allow referred users to become friends upon successful referral
Is this active now?
Invitation Features:
User can enter the emails of users they wish to invite
The board will keep track of the status of every invitation
Invitation Sent Status - with an option to send a reminder.
User Joined
User is active (made at least 1 post)
User visited (but did not join) - with an option to send a reminder.
User can have a limited number of invitations or unlimited
If the user has more than one invitation remaining, they can enter more friends emails to invite.
Invitations can expire after a set amount of time, and the invitation will be awarded back to the user.
Administrator can set the limit for invitations and assign additional invitations to groups or users manually
Administrator can revoke the permission for a user to use the invitation system -- useful if a user abuses it.
Ability to disable board registration, in which case an invitation key would be required to register. -- for private boards
Administrator can set the format of the invitation e-mail, or use a default template provided in multiple languages.
Memberlist in ACP will show how users with the most invitations left, and the users who have depleted their invitation count. This is useful if an Admin needs to assign users more invitations to pass out.
Users can donate invitations to other users
If a user is inside of a group, and they have permission to invite others to that group, the user invited will be automatically added to the group upon successful invitation. -- useful to provide group or forum specific invitations.
Option to set number of additional invitations awarded to users based on number of successful invitations
Option to set number of additional invitations awarded to users based on post count
Administration options will be included for all of these features, so you can set the invitation to be extremely simple, or utilize ALL of the features at your option.
Are any of the above active in the current release I installed? I am not seeing anything in the ACP to update, etc.

Thanks in advance for the help. You are making some great mods.
User avatar
geeklife
Registered User
Posts: 172
Joined: Tue Jan 29, 2008 1:13 am

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by geeklife »

I have installed this mod. However I noticed on the first image in this thread when you enter a letter of a username a auto-pop-up should appear listing possible usernames as the referrer. I am NOT seeing that with our install.
Okay this works in Firefox 2.0 but not in IE 7. Is there a fix for that. That IS AN AWESOME FEATURE.
User avatar
Highway of Life
Former Team Member
Posts: 6048
Joined: Wed Feb 02, 2005 5:41 pm
Location: Seattle, WA
Name: David Lewis
Contact:

Re: [BETA] Highway Referral Invitation MOD - 0.1.0c

Post by Highway of Life »

IE is nubbed. I don’t know why it’s not working in IE. But will fix it in the next version, thanks for the report.

And no, the invitation features and widgets are not active yet.
The phpBB Weekly Podcast - Discussing the developments of phpBB4 and beyond.

New to phpBB3? Want to learn about programing?
Visit phpBB Academy at StarTrekGuide to learn how.
Locked

Return to “[3.0.x] Abandoned MODs”