![]() |
Amazon Associates Hack for VB3
This hack converts any US amazon link posted on your board to use your affilliate id and is based of some work Logician did for me in Vbulletin 2, but is an improved rewrite. The old version did not track well with Amazon because it did not strip out Amazon session ids.
Please note that you need to change my affilliate id to use yours. Also note that the chunk of code you are looking for in edit.php may not be an exact match in your file. You are looking for the query that updates the post table with the edited post. Regarding Update.zip Update.zip contains a new functions_amazon.php that I would like some people to try out before I add to the regular zip file. The new function handles Amazon's new link format, and I believe, works better than the original function. Please LET ME KNOW if you try it and it works for you. ------------- This hack will always be free, however your donations are kindly accepted and will help towards further development. If you donate, please leave me some info (either your forum site or username at vB.org) so that I can thank you. :) https://vborg.vbsupport.ru/external/2010/02/12.gif |
What does this hack do?
|
Quote:
|
This is a really good idea. I will install for sure when complete!
|
I'm really glad to see this released. How does this work with your non-us members?
|
Quote:
|
For the record, I installed this hack 3 days ago and have already sold 22 items. Given that I have an off-topic site that normally sells 2 or so items a quarter without the hack, I think this has the potential to make serious money for forums with a true focus.
Amy |
Nice, I just put a full amazon shop on my site instead though since it only took about 5 minutes.
|
AWESOME.
This is sheer genius. /me clicks install. |
Thanks you soooo much!!!!!!!
|
Good tool, thanks.
|
Is anybody actively using it? Found any link rendering problems? I know that it's tracking items very well and I am getting credit for purchases - even direct links to products. My one concern is that with people using different editors (WYSIWYG, enhanced, and guided, etc.) that some of the urls might get botched.
If no problems have been reported in a couple of weeks, I'll move on to getting this working in the PM system as well. Amy |
This hack is now out of beta. Enjoy.
|
Quote:
|
Quote:
|
Awesome modification - thank you very much!!!
Only problem is that for some reason it is working fine for me if I use the Enhanced editor, but if I use the Standard editor it is not working at all it seems. I cannot figure out how to get it to work with the standard editor... |
Quote:
|
Quote:
In the file includes/functions_newpost.php Find: Code:
$urlReplaceArray = array( For some reason, vbulletin developers decided to put urls in the database differently depending on the editor used. This just makes the standard editor urls the same format as the WYSIWYG. I'll add this to the text file. Amy |
Great idea!! I love this!!
|
Fantastic!!! Thanks very very much Amy :)
(and I'm sorry I didn't say thank you earlier - because of the way vbulletin doesn't leave the url statements in the code, they looked exactly the same to me when I first saw the reply, but if you hit quote you can see the difference. Thanks again so much - works great! |
I have updated the code so it now works in private messages as well. In addition, I tweaked things so you only have to change the affilliate id in one place, and have made the code a bit easier to install.
If you have the old version installed, you will need to remove the changes you made in functions_newpost.php and editpost.php. |
getting double //ref=nosim with latest code. Not that it matters really I think it still tracks ok.
Great hack! |
I am sure this will sound stupid...
I am trying to edit the functions_amazon.php file and I am very confused as to where my associates ID goes.... It asks for it in a few places... I don't want to mess up... help please.. |
Quote:
Code:
// enter your associate id here |
Quote:
|
Cool, That is exactly what I did but I wanted to be sure....
Thanks :) |
Don't hold me to this one, gang, cause I haven't tested it. But I THINK you can make this work for international Amazon sites simply by changing the .com to the extension you desire whereever it occurs in the Amazon functions file. (Please don't try to do this if you can't code. Wait until somebody with experience tests it first)
For example, if you use the Canadian Amazon, you would change .com to .ca everywhere it occurs. If you use more than one Amazon because you are a multicultural site, you would just have to repleat the code blocks - once for each country. AGAIN DON'T TRY THIS IF YOU AREN'T A CODER. LET SOMEBODY ELSE PAVE THE WAY. I'm not going to support the internationalization aspect because I don't use it. Try it at your own risk. |
Just looking at this .. and a question comes to mind ..
What's the point/need for the "/ref=nosim/"? (This is for co.uk Amazon btw .. not .com) |
Quote:
Cheers. |
Thanks for putting this together!
It's great that it deletes other associate id's from the direct links, however if someone links to the main page using: http://www.amazon.com/exec/obidos/redirect-home/someid-20 the link turns into: http://www.amazon.com/exec/obidos/redirect-home/someid-20/ref=nosim/myid-20 Who gets the credit then? |
I don't know. But, if I get time in the next day or so, I'll work on knocking other people's referrals out of other links as well.
Amy |
I recently visited a message board that had a "Shop with Amazon" drop down menu on the top of their forum (navigation bar area). When users click on this link, a small search box (similar to the Search Forum box) with an amazon logo and design appears, in where users would enter their query in the search-like box. For example, a member would type in a product name and it would automatically take them to the corresponding amazon.com page.
I was wondering how I would be able to install this feature onto my message board. Please try to be very thorough and detailed when describing the steps and the coding involved. |
Quote:
In your navbar template, find: Code:
<tr> Code:
<!-- Amazon.com Search Start --> |
Cteselle, thank you so very much!
I was wondering, will it show the amazon.com graphics on the search box display? I want it to look somewhat professional and official. EDIT: Also, will guests be able to view it? |
Quote:
Guests will be able to see it, if you have search turned on for guests. |
Another question.
This only creates another table for the pre-existing search box. I wanted to make a separate drop-down menu altogether on the navbar. Is it possible for you to provide me with the code that does this? |
So is there any way to get this to work with the GAL auto linker hack?
Greg Installed |
It's two separate things that you should be able to use together. This hack modifies links, not text. The other hack modifies text, not links.
|
Quote:
Greg |
Sorry this may be kind of off topic, but how does the Amazon associates thing work? Do you place ads? Explain this to stupid old me. :)
|
All times are GMT. The time now is 03:13 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|