Welcome to Geeklog, Anonymous Saturday, November 23 2024 @ 11:00 pm EST
Geeklog Forums
PHP Block: Refer a Friend
Tony
That's it! This function does keep track of the number of referrals made. If you would like that statistic to show up on stats.php you can add it yourself. The number of referals is stored in the vars table where the name is 'num_site_referrals'
e.g.
SELECT value FROM vars WHERE name = 'num_site_referrals';
For those interested, this code emails the following text:
This message was sent to you by Tony at tony@iowaoutdoors.org because they thought you would be interested in learning more about a great Hunting & Fishing website called Iowa Outdoors! Iowa Outdoors is a not-for-profit website with the only focus being to make you and others better at their outdoor pursuits. Get a wide variety of information, tips, tactics on fishing, hunting, trapping and much more by visiting Iowa Outdoors at http://www.iowaoutdoors.org today!
------------------------------------------------------------
NOTE: This is not unsolicited mail. You received this message because someone specifically requested that you do. Your email address was not saved and will not be given out under any circumstance.
Hope that helps!
The reason people blame things on previous generations is that there's only one other choice.
austad
After the first if statement in the patch, add:
if (!$_USER['uid']) {
$msg = 'You must be a member to use this feature. Please log in, or create a free account.';
} else {
And then at the end, make sure to close out the "else" right after the section that updates the count for the number of referrals. You can see how it works at Brewtus.com.
squatty
In a world without walls and fences, who needs Windows and Gates?
Anonymous
racooper
I have made some modifications to the original referral block, and am releasing them for whoever finds it useful.
[QUOTE=readme.txt]
UPDATES/CHANGES:
-- 10 Nov 2005
* Moved customization variables to plugins/referral/conf.php
* modified location of files
* corrected spelling errors in all files (including function names)
* updated email validation to use Geeklog's COM_isEmail function
* moved block function to it's own file plugins/referral/functions.php
* removed COM_refresh from error messages so they can be read
* Changed outgoing mailer to use Geeklog's COM_mail
[/QUOTE]
Download Link
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content