943,741 Members | Top Members by Rank

Ad:
  • PHP Discussion Thread
  • Unsolved
  • Views: 386
  • PHP RSS
Dec 12th, 2008
0

download, install & redirect

Expand Post »
Hi,

N00b in need for some help

I would like to do this: our affiliate inputs an url of his choice and submits. The script gives him our app with his affID embeded in it. When his visitor installs this app, he is redirected to url, which was submitted before.
Here is my Js code so far, but I am not good in php, so how to create that (download.php) code to pass affID and url redir? Pls, help!

PHP Syntax (Toggle Plain Text)
  1. <TABLE cellPadding=10 width='555' border=0 style='border-collapse: collapse' bordercolor='#111111' cellspacing='0' align=center>
  2. <TR>
  3. <TD width='635'>
  4.  
  5. <script>
  6. function update(){
  7. var yourcontent = document.getElementById('yourcontentid').value;
  8. if(!yourcontent) {
  9. alert('you have to enter a valid content url');
  10. return false;
  11. }
  12. var url = 'http://sub.domain.com/download.php?affID=<?php echo urlencode($_POST['affID']); ?>">&content='+yourcontent;
  13. var dl = document.getElementById('downloadid');
  14. dl.src = url;
  15. }
  16. </script>
  17. <iframe src='' id='downloadid' width=0 height=0></iframe>
  18. <TABLE cellSpacing=0 cellPadding=5 width='622' border=1 height='137'>
  19. <TBODY>
  20. <TR bgColor=#cccccc>
  21. <TD height='1' width='608'>
  22.  
  23. Protect your own content<BR>
  24. <span class='text'><b>
  25. <span lang='bg'>Type </span>: </b>YourContent<b></TD></TR>
  26. <TR>
  27. <TD height='120' width='608'>
  28. Your content url:<input id='yourcontentid' type='test' name='yourcontent'><br><Br>
  29.  
  30. <input type='button' value='Download Your Content exe' onclick='javascript:update();'> <BR><BR>
  31.  
  32. You can fill in any url you like to protect like a movie or a website, for example 'http://www.yoursite.com/content/' or 'http://www.yoursite.com/movies/movie.mpg'<BR><BR>
  33. The exe will install Xposio and redirect to the url of your choice.<br>
  34. You can make as many content executables as you wish.
  35. <BR></TD></TR></TBODY></TABLE>
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
elbuhleini is offline Offline
17 posts
since Apr 2008

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in PHP Forum Timeline: defining sql query as function
Next Thread in PHP Forum Timeline: query executes and return correct value but cudnt save one value into db





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC