Jump to content

Extract an ID passed through a variable with the link


RON_ron

Recommended Posts

I need help to write the PHP code to extract an ID passed through a variable with the link and match it to an ID on the PHP page, then pass the email address (into Flash).

 

<PARAM NAME=FlashVars VALUE="markbass=permadi&score=124560">

 

FlashVars="markbass=permadi&score=124560"

 

A sample script would be helpful.

PLEASE COULD ANUONE HELP ME ON THIS...

 

I need help to write the PHP code to extract an ID (a variable) passed through the link and to match it to an email on the PHP page, then send the email address back.

 

A sample script would be helpful.

The purpose of doing this is my website is been linked to many of our DISTRIBUTORS. I need a system to know from which DISTRIBUTOR did the request come from. I'm developing the website in FLASH.

 

How I'm planning to do this is

 

By adding the PINK text on the HTML - This will pass a variable with the link.

 

<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
  codebase="http://macromedia.com/cabs/swflash.cab#version=6,0,0,0"   
  ID=flaMovie WIDTH=250 HEIGHT=250>
  <PARAM NAME=movie VALUE="flaMovie.swf">
  [color=red]<PARAM NAME=FlashVars VALUE="userName=permadi&score=80">[/color]  <PARAM NAME=quality VALUE=medium>
  <PARAM NAME=bgcolor VALUE=#99CC33>
  <EMBED src="flaMovie.swf" 
[color=red]    FlashVars="userName=permadi&score=80"[/color]
    bgcolor=#99CC33 WIDTH=250 HEIGHT=250 
    TYPE="application/x-shockwave-flash">
  </EMBED>
</OBJECT>

 

Then I need a PHP script which would extract that ID and match it to an ID on the PHP page, then pass the email address into Flash.

 

SO I'M ASKING HELP IN WRITING THE PHP WHICH INCLUDES THE LIST OF EMAIL ADDRESS.

Still, Im completely lost. You mention a link, I see none.

 

Then I need a PHP script which would extract that ID and match it to an ID on the PHP page

 

So, you want php to scan a file for an id, then match it against another id somewhere else in the same file?

OK. I try to explain once more in a easier way. I've developed a website in FLASH. I own a company and my distributors link my website to theirs. I want to give a commsion to the distributor based on where the user come in to my website.

 

I'm getting each Distributor to add code to their site to pass a variable with the link when they link to my site. 

 

Basically, the link on their site would include a variable in the querystring (http://www.mysite.com/targetpage.php?DistributorID=1234). Each Distirbutor ID is unique.

 

I need to write a PHP script that would extract that ID and match it to an ID on the PHP page, then pass the email address (which matches to that ID) back to my Flash website.

You will find the DistributorID (as passed via a link) within the $_GET[] array. eg $_GET['DistributorID']

 

As for matching it to an ID on the page? We need to see what that page looks like exactly. I'm still not sure your description is correct here.

Let me give it a try. Something like this where it gets the ID and matches with the email address.

 

<?PHP

$_GET['DistributorID']

 

$headers = "[email protected]" .$ID125;

$headers = "[email protected]" .$ID126;

$headers = "[email protected]" .$ID127;

?>

OK. could you tell me how to write the PHP code to send a email address to a PHP file on a specific location (www.myweb.com/myphp.php).

 

No. Again, your not exactly making sense.

 

You can send a http request via either POST or GET to a php file at a specific uri, you can even send extra data along with that request. Still though, is this what your looking for?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.