The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Comments |
#82
|
|||
|
|||
Well, mine installed just fine, with just one strange problem: the first time you click to send admiration, you get the duplicate phrase. I've double checked the code, and its all correct. Any ideas why this is happening?
You know, I think I may know what the problem is: I missed "NOTE: You must replace TABLE_PREFIX with the prefix that you use on your VB3 installation... OR remove it if you are not using a table_prefix." So . . . can somebody explain that to me? I'm new to the SQL queries. How do I know if I'm using a table prefix, and if I am, what it is? |
#83
|
|||
|
|||
Quote:
The hack cunningly uses MySql trickery to detect duplicates... the trickery is that when two identical rows get inserted it causes an error. I detect the error and that's how I know that an admiration already exists. However, it means I am basically masking MySql errors. Anyhow... table prefix. In your /includes/config.php file there is a bit that looks like this: Code:
// Prefix that your vBulletin tables have in the database. // For example: $tableprefix = 'vb3_'; $tableprefix = 'vb3_'; Code:
DATABASE WORK In phpMyAdmin or from the MySql command line, run the applicable piece of SQL. NOTE: You must replace TABLE_PREFIX with the prefix that you use on your VB3 installation... OR remove it if you are not using a table_prefix. FOR A FRESH INSTALL: CREATE TABLE TABLE_PREFIXsecretadmirer ( userid INT(10) NOT NULL, admiresuserid INT(10) NOT NULL, datecreated INT(10) NOT NULL, PRIMARY KEY (userid, admiresuserid), KEY admiresuserid_ix (admiresuserid), KEY userid_ix (userid) ) TYPE = MYISAM; FOR AN UPGRADE FROM A VB2 VERSION: RENAME TABLE secret_admirer TO TABLE_PREFIXsecretadmirer; Now, in that CREATE TABLE bit the first line says: Code:
CREATE TABLE TABLE_PREFIXsecretadmirer ( Code:
CREATE TABLE secretadmirer ( Code:
CREATE TABLE vb3_secretadmirer ( You only need to do this once, in that piece of SQL. The script can work it out when running, but because I didn't build an installer, I couldn't work out whether you have a table prefix. Oh, and you will also want to run this which will delete the table that you made by accident: Code:
DROP TABLE TABLE_PREFIXsecretadmirer; Hope that all makes sense to you |
#84
|
|||
|
|||
Perfectly clear, and now running perfectly! Many thanks!
|
#85
|
||||
|
||||
Buro, I've looked in my phpadmin, and found a table called "TABLE_PREFIXsecretadmirer". Now, I have no table prefixes in my config file, so I'm not sure how this got created. And, the hack is working fine.
Suggestions??? |
#86
|
|||
|
|||
Quote:
You must've run the SQL and then modified it to remove the TABLE_PREFIX bit and then ran it again. So just deleted the unused table |
#87
|
|||
|
|||
Would it be possible to make this feature accessible from the user's postbit? So if you wanted to register admiration, you wouldn't have to go to the profile.
|
#88
|
|||
|
|||
Okay here's my problem.
No longer have the blank page problem - for some reason when I FTPed the file it didn't come up with the entire code. Who knows. Anyhow, the PM's aren't sending like they're supposed to and neither are the e-mails. Any idea? |
#89
|
|||
|
|||
Quote:
Note these bits: Code:
PHRASE WORK: Under the phrase type: Front-End Redirect Messages Add these phrases: secretadmirer_acknowledged Your admiration for that user has been successfully registered. secretadmirer_duplicate You've already registered your admiration for that user.<br/> Maybe it's time to PM them and let them know you like them? secretadmirer_report_sent Your secret admirer report has been dispatched to your registered e-mail address. secretadmirer_limit Sorry! You may only admire a maximum of 5 people within the last month. |
#90
|
|||
|
|||
Quote:
Check that you created the templates: Code:
TEMPLATE WORK For each of the text files, you need to add it as a template of the same name. Change the values within them to match your forum and personal preference :) There are five in total: secret_admirer_alert_email secret_admirer_alert_pm secret_admirer_match_email secret_admirer_match_pm secret_admirer_report_email |
#91
|
|||
|
|||
Quote:
Code:
<a href="profile.php?$session[sessionurl]do=admire&userid=$userinfo[userid]">Register your admiration for $userinfo[username]</a> |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|