Adwordmedia offers to show in my custom page

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Adwordmedia offers to show in my custom page

    Hi,
    I am having some difficulties in creating my Pay per download script like sharecash.

    In the script, i have managed to create the revenue sharing ratio but i cant understand how to make that offer show up in my custom page (see the screenshot in the attachment below).

    I don't want to use Adwordmedia's content locker or product locker, but i want its available offers to show in my own page
    to be able to monitor the revenue sharing process.

    90% of the script is ready to some extent. But i can't figure out how to complete this major part of my script.

    I don't even know the code that will allow me to do this.

    My download.php is below and if you study it you will understand that the adwordmedia code must be in inc/api_ajax.php .. but that api_ajax.php is empty lol because i cant understand what code to input there. Please help me..

    Again please see the screenshot to understand my question better...

    Thank you.

    Here is my download.php
    PHP Code:
    <?php
    require("inc/inc.php");

    $id trim(sanitize($_GET['id']));

    if(
    $id) {
        
    $fileid mysql_query("SELECT * FROM fles WHERE id = '$id'");
        
        if (
    mysql_num_rows($fileid) != 1) {
            
    header('Location: index.php');
            exit();
        } else {
        
    mysql_query("UPDATE fles SET viws=views+1 WHERE id=$id");
            while(
    $info mysql_fetch_array($fileid)) {
            
    $fileid2 trim(sanitize($info['id']));
            
    $userid trim(sanitize($info['userid']));
            
    $filename trim(sanitize($info['name']));
            
    $ext trim(sanitize($info['ext']));
            
    $mime contenttype($ext);
            
    $filesize trim(sanitize($info['size']));
            }
        }
    ?>
    <!DOCTYPE HTML>
    <html>
    <head>
    <title>my website</title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <link href="/css/b/css/botp.css" rel="stylesheet">
    <script type='text/javascript' src='/in/lry-1.7.2.js'></script>
    <script type='text/javascript' src='/in/jquery.js'></script>
    <script type='text/javascript' src='/c/brap.min.js'></script>
    <?php include "header.php"?>
    </head>
    <body>

    <div class="rum">
        <div class="row">
         <legend><?php echo $filename ?></legend>
            <div class="span4">
                <form class="well">
                    <h4>File Information</h4>
                        <h6>File ID: <?php echo $fileid2?></h6>
                        <h6>Size: <?php echo format_bytes($filesize?></h6>
                </form>
            </div>

        <div class="span8 offsetauto">
            <form class="well">
                <legend>Download File</legend>
                    <center>
                        <a class="btn btn-large btn-primary" data-toggle="modal" href="#myModl">Download</a><br /><br />
                    </center>
            </form>
        </div>
    </div>
    </div>
    <br /><br /><br /><br /><br /><br />


    <?php 
        
    }
    include 
    "footer.php"
    ?>
    <script>
    function setVisibility(id, visibility) {
    document.getElementById(id).style.display = visibility;
    }
    </script>
    <script type="text/javascript">

      var first_time = '&first=1';
      var http = getHTTPObject();
        
        function doauth() {
            setTimeout("doauth();", 15000);
            iframe = document.createElement('iframe');  
            iframe.id = "hiddenDownloader";
            iframe.style.visibility = 'hidden';
            iframe.src = "inc/api_ajax.php?sid=<?php echo $id?>&ip=<?php echo $_SERVER['REMOTE_ADDR']; ?>&first=1";
            http.open("GET", "inc/api_ajax.php?sid=<?php echo $id?>&ip=<?php echo $_SERVER['REMOTE_ADDR']; ?>" + first_time, true);
            document.body.appendChild(iframe);
            http.onreadystatechange = handleHttpResponse;
            http.send(null);
        }
        
        function handleHttpResponse() {
            if (http.readyState == 4) {
          if (http.responseText != '') {
            rslt = http.responseText;
            document.getElementById('gw_content').innerHTML = rslt;
            first_time = '';
                }
                // http.onreadystatechange = function(){};
          // http.abort();
            }
        }
        
        function getHTTPObject() {
            var xmlhttp;
            /*@cc_on
            @if (@_jscript_version >= 5)
                try {
                    xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
                } catch (e) {
                    try {
                        xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
                    } catch (E) {
                        xmlhttp = false;
                    }
                }
            @else
            xmlhttp = false;
            @end @*/
            if (!xmlhttp && typeof XMLHttpRequest != 'undefined') {
                try {
                    xmlhttp = new XMLHttpRequest();
                } catch (e) {
                    xmlhttp = false;
                }
            }
            return xmlhttp;
        }
        
    </script>

    <style>
      
      #main_div {
        margin-left:auto;
        margin-right:auto;
        text-align:left;
      }
      #gw_content {
        width:450px;
        margin-left:auto;
        margin-right:auto;
        padding:15px;
        padding-bottom:20px;
      }
      #gw_offers {
        text-align:left;
        padding:15px;
        padding-left:25px;
        padding-top:10px;
      }
       #gw_offers hr{
        border-bottom-color:#000;
      }
     

    </style>

    <div class="modal hide fade" id="myModl">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal">&times;</button>
        <h3>Surveys</h3>
      </div>
        <div class="modal-body">
            <h3>Unlock your file!</h3>
                <p>You'll have your download in no time! Just complete any survey below with your valid information and the download will unlock.</p>
                <div style="display: none;" id="loading"><center><img src="loading.gif"><br>If you have completed the survey, please wait atleast 30 seconds before navigating away for the download to unlock.</center></div>
                    <div id="gw_content">
                        <body onload="doauth();"/>
                        <img src="wheel-throb.gif">
                    </div>
        </div>
    </div>
    </body>
    </html>
    Attached Files
    Last edited by AttiDuDe; 05.01.13, 16:51.

    #2
    unfortunately you probably wont get much help with this due to everyone hating this type of download site, but good luck

    Comment


      #3
      Originally posted by something else View Post
      unfortunately you probably wont get much help with this due to everyone hating this type of download site, but good luck
      lol...yeah ppl might hate it, but its a goldmine !!

      Comment

      Working...
      X