PDA

View Full Version : Secret Admirer


buro9
08 Jul 2003, 19:41
This was requested over here:
http://www.vbulletin.org/forum/showthread.php?s=&threadid=53880&perpage=15&display=&pagenumber=1

Essentially it is a hack to allow users to have crushes on each other and to declare them secretly. If two users declare that they fancy each other, then a match occurs and both are notified.

This is a great way of virally encouraging users back to the board and to inject a bit of fun into a forum.

We ran a manual one of these on our boards called 'secret crush', but that proved too controversial, so this is slightly watered down to be 'secret admirer', such that more people can participate and admiring someone doesn't commit you to them... so it's less imposing.

Anyhow... on with the hack.

The hack is comprised of:
1 new database table.
1 new php file.
Edit to member.php to include new "if" statement.
Edit to getinfo template for 'admire' link.
6 new templates.

All of the code and instructions can be found in the attached zip file.

I've tested this on my own board, and have installed it in my live environment. I don't know if it is rock solid though, so would appreciate feedback and bug reporting. I'm not a PHP coder by trade, so point out any errors if you see them.

Cheers

David K

UPDATED: 2003-SEP-12

Major update, adds reporting functionality for users and puts us on the verge of a gold release. Could a few other people please install this and let me know how you go... I want to know for sure that others are comfortable with this as it stands before I turn it gold.

I personally think it's there now... but just want the community to give me that peace of mind (as my board is hacked heavily and I want to find issues BEFORE it goes gold).

UPDATED: 2003-SEP-13

Now included screen shots within the zip file.

Dean C
09 Jul 2003, 10:44
I must admit this is a fantastic idea. My forum are mainly men so it wouldn't suit my site but i tell you if i had a completely mixed-gender site it would be so much fun to have.

Excellent idea and excellent hack :)

Well done!

- miSt

buro9
09 Jul 2003, 11:19
Well, it's working very well, in the first 24 hours some 150 'crushes/admirations' were registered and 15 users matched up.

The threads are buzzing away, and there's just this really exicted sort of vibe over it.

And because it's 'admiration' rather than 'crush' it seems quite embracing and innocent.

And the best thing... haven't found one bug yet :)

But I have realised the amount I hardcoded my forum details in the templates... If you're installing this please amend these with your details, I'll correct this in the Gold version.

Oh... and it's designed as a seperate file so that only the minimum changes are required to vBulletin code... thus it should be effortless to port to vb3.

Cheers

David K

PixelFx
14 Jul 2003, 16:21
kewl idea, great job

DaveRobbo
16 Jul 2003, 10:50
Any screenshots?

kaotic
16 Jul 2003, 11:00
This does seem like it would be cool; however, screenies or a demo site would be appreciated. :)

jamoss
26 Jul 2003, 08:12
Hey mist- my forum is mainly women. And not preggo or married, either! Maybe we should get our forums together ;)

insanctus
26 Jul 2003, 08:31
I wish I could use this on vb3 :(

buro any plans on doing it for vb3 (would love it since my idea I would not mind testing on my forums, and sounds like you did a great job on it)

jamoss I think I should sigh up for your site (wait are you sure they not preggo or married :) )

Hobbes
09 Aug 2003, 05:23
great hack!

this is super cool man I like it!

Except, one thing you could includein the gold version is an admin-side where Admins can see who clicked who, who matched etc....

it'd be really cool :D..

and i'll beta test for vb3 if u want hehe

NuclioN
09 Aug 2003, 23:18
Very nice :) No bugs so far. Clicks install.

pokesph
20 Aug 2003, 16:15
Yes, this hack would really work out well on our boards.. too bad it's not done for vB 3 yet.. any ideas when/if it will be done for vB3??

Zachery
21 Aug 2003, 06:36
08-09-03 at 06:23 AM Hobbes said this in Post #9 (http://www.vbulletin.org/forum/showthread.php?postid=424503#post424503)
great hack!

this is super cool man I like it!

Except, one thing you could includein the gold version is an admin-side where Admins can see who clicked who, who matched etc....

it'd be really cool :D..

and i'll beta test for vb3 if u want hehe
no you wont hobbies :P


nice idea :) at our site i think we need more members, if i hadnt just upgraded to vb3 i might use this :)

Hobbes
08 Sep 2003, 03:09
08-08-03 at 10:23 PM Hobbes said this in Post #9 (http://www.vbulletin.org/forum/showthread.php?postid=424503#post424503)
great hack!

this is super cool man I like it!

Except, one thing you could includein the gold version is an admin-side where Admins can see who clicked who, who matched etc....



still wondering :(

buro9
08 Sep 2003, 05:13
I've been lazy. I apologise.

I left it wallow in Beta as no bugs have been found.

I'll polish it this week and release it as soon as I can.

I won't include an admin option to view who has voted though. I have no doubt some of you want this, but I value the trust of my users very highly and respect their confidentiality.

If you want such a thing for specific cases, then you can just take a peek at the database table 'secret_admirer'... it's very easy to figure out. But it's not my style to have things like this, or the PM reader hack*, etc.

Cheers

David K

* I actually go one further and obfuscate the storage of PMs on my site to assure the users that private means private.

buro9
08 Sep 2003, 05:19
07-16-03 at 12:00 PM kaotic said this in Post #6 (http://www.vbulletin.org/forum/showthread.php?postid=418138#post418138)
This does seem like it would be cool; however, screenies or a demo site would be appreciated. :)

Screenies will follow when it goes Gold... which will only be a week or so :)

Catch-22|BL
12 Sep 2003, 19:47
buro9: Very nice! We have a message board of 17000 posts/week and we will definitely give this a shot if you can get this to final release. I think it will be popular and a fun thing to build sense of community.

I agree with your thoughts of keeping the information secret from administrators. Besides privacy (which is a good enough reason by itself) think about it this way: how many administrators would want people bombarding them begging for hints or clues? ;)

buro9
12 Sep 2003, 21:31
buro9: Very nice! We have a message board of 17000 posts/week and we will definitely give this a shot if you can get this to final release. I think it will be popular and a fun thing to build sense of community.

I agree with your thoughts of keeping the information secret from administrators. Besides privacy (which is a good enough reason by itself) think about it this way: how many administrators would want people bombarding them begging for hints or clues? ;)
Just done most of the updates... refreshed the zip file for you all... it should now be ready for gold... I'll set about getting some screenshots for you all.

BTW... the bombarding admins and mods is a very valid point... they do do this, and it was only my continual assurance that I couldn't and wouldn't tell them anything that got them off my back.

You can see this all in action over at http://www.bowlie.com/forum/

Cheers

David K

buro9
12 Sep 2003, 21:35
Just thought I'd re-iterate... as regards VB3... I've designed this mod to be VERY portable.

All of the code is pretty much in one file... and only a small slice of logic will need to be ported.

As soon as I have VB3 running I will port this mod to it... because obviously I need it too!!!!

buro9
13 Sep 2003, 08:32
Screenies will follow when it goes Gold... which will only be a week or so :)
Screen shots are now in the zip file too... 6 of them I think... they show all of the additions, etc.

They don't quite do the system justice though, I have over 2,000 rows in the database table... it's proving very effective :)

ButchGal
01 Feb 2004, 00:32
* I actually go one further and obfuscate the storage of PMs on my site to assure the users that private means private.

Thanks for this hack, i love it and so will my users.

How do you obfuscate the storage of PMs? I'd like to do that also.

Koutaru
01 Feb 2004, 03:59
a vB3 version would be cool ;)

buro9
01 Feb 2004, 09:48
Thanks for this hack, i love it and so will my users.

How do you obfuscate the storage of PMs? I'd like to do that also.
I used blowfish encryption to encrypt the PM contents, seeded with the username... but that was on VB2, and I'm not yet doing anything like this on VB3 because the storage of PMs has changed... PMs are now only stored once, whereas in VB2 a seperate copy was stored for sent and received, etc.

I may find a way to re-do this... but it's not a high priority for me at the moment... PMs are secure anyway, it just gives additional peace of mind to some members. I was also unsure how much I ever actually needed it, especially when you consider the processing overhead it produced as a result.

Anyhow... I'll think about doing this in VB3, and this time I might release it (I released only a fraction of what I ever hacked for my own board).

buro9
01 Feb 2004, 09:50
a vB3 version would be cool ;)
A VB3 version will be done... and since it will be based on the code I've had running on my site for months, it will go straight to full release. I hope to get this done in the next two weeks.

aezs
02 Feb 2004, 18:54
NICE NICE! Please port this to VB3 !!

buro9
02 Feb 2004, 22:02
NICE NICE! Please port this to VB3 !!
OK, I'll start it tomorrow :)

I hadn't actually realised that anyone had installed it! I just thought it was me running it on my own! Now I realise there's an audience I'll get off my backside ;)

Koutaru
03 Feb 2004, 01:17
I'm sure a lot of other people installed it. Sadly, some people don't hit the install :p but I'll definately be looking forward to the vb3 version ;)

msimplay
03 Feb 2004, 01:54
yeh i'd like this too :D

buro9
16 Feb 2004, 10:40
Just to let you all know what is happening.

I've completed a VB3 version of this and am currently testing it on my board.

In a few days I'll clean it up a little and release it under the VB3 finished hacks section... when I do that I'll post a link in here to it.

If one or two of you wishes to help testing, then please PM me and I'll mail you the preliminary code.

For VB3, most of it is chunked off into two functions files as before (one to handle all the secret admirer stuff, and one to handle PM sending), and only a few lines needs to be added to one file (./profile.php). Aside from that there are a couple minor template changes, and some new phrases.

I haven't concentrated on making it fully phrase friendly, anyone who wishes to do this can do so once I've released it.

Cheers

David K

Catch-22|BL
16 Feb 2004, 14:16
Sorry I abandoned you before. :(

My home forums had lots of server problems. We become overloaded and actually were disabling so many features. There was no chance to add new things unless they were essential to our continued operations.

But...the good news is that some of us are starting a few experimental forums. This would be great. I can help finish testing for vb3 version so I will send you a PM if you still want to trust me. ;)

buro9
16 Feb 2004, 18:49
Sorry I abandoned you before. :(

My home forums had lots of server problems. We become overloaded and actually were disabling so many features. There was no chance to add new things unless they were essential to our continued operations.

But...the good news is that some of us are starting a few experimental forums. This would be great. I can help finish testing for vb3 version so I will send you a PM if you still want to trust me. ;)
A couple of you asked to test it, so you can now find it in the beta forum:

http://www.vbulletin.org/forum/showthread.php?p=477551

This time if I receive enough feedback I'll move it to the release forum in a fortnight ;)

Splinteroid
24 Oct 2004, 21:58
Hi, I installed this perfectly and it seems to work fine, exept it won't allow a certain usergroup use it, it gives them the 'you do not have permission to view this' page. I tried messing with the options for that usergroup but I just can't get it to work. its driving me nuts. Anyone have a solution?

buro9
24 Oct 2004, 23:31
Wow, a 2.3.x install?

Erm, check the secret_admirer.php file and find the following:


//
// This is a standard array, seperate the USERGROUP id's with commas... this
// is NOT user id's... these are the id's of the usergroups who you wish to
// exclude from participating in the secret admirer hack.
//
$EXCLUDED_USERGROUPS = array(1,3,4,9);


Remove the ones you want to be able to use it ;)

Note that you should always exclude anonymous users as these would confuse the hell out of the system.

The other groups above were on my board Coppa, Unactivated and Banned.

Kassandra
29 Oct 2004, 08:05
Wow, a 2.3.x install?

Erm, check the secret_admirer.php file and find the following:


//
// This is a standard array, seperate the USERGROUP id's with commas... this
// is NOT user id's... these are the id's of the usergroups who you wish to
// exclude from participating in the secret admirer hack.
//
$EXCLUDED_USERGROUPS = array(1,3,4,9);


Remove the ones you want to be able to use it ;)

Note that you should always exclude anonymous users as these would confuse the hell out of the system.

The other groups above were on my board Coppa, Unactivated and Banned.Thank you for the help. Was just what we need. Appreciated greatly. :)

wolfyman
22 Jul 2005, 15:20
doesthis work for vb3?

buro9
22 Jul 2005, 15:26
doesthis work for vb3?
http://www.vbulletin.org/forum/showthread.php?t=61632&highlight=secret+admirer