Trying to add php file and have no idea how!

I just joined an affiliate program that allows you to use an affiliate link guard by using a php or html file to hide your affiliate ID. I have no idea how any of this works. I downloaded a file in both php and html form but have no idea how to use them!

These were the instructions I was given:

I’m assuming that this is why I am getting a broken image and no hyperlink from the affiliate provided banner? (see pic below)

or is there something wrong with the code?

Please tell me how I can do this! Thanks!

I should add, I figured out how to edit css for the child theme is this where I add the php file? It looks like this:

<?php header("Location: http://planetbox.com#oid=affiliateID"); exit(); ?>

**affiliateID numbers were removed)

but it says I have multiple errors with the code

Hi There,

Thank you for writing in, can you link the full documentation of your affiliate program?



That instruction simply means when you want to link a user to your affiliate link, then you should link them to that file instead. That is if your file is named my-affiliate.html and you upload that to the root directory of your WordPress site, then your affiliate link would http://yoursite.com/my-affiliate.html, at least that is how I understand it. I could be wrong please contact your affiliate program support and clarify to them the instruction.

Regarding this:


I don’t see any wrong with that code, but since I can not test the src URL. Please copy the src="URL" URL and paste it directly on your browser address bar and see if the image shows up, if not, then that means your URL is wrong, and you need to get the correct URL of the image.

Cheers!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.