Wow. Inserting Javascript in a CGI Script!!

Discussion in 'Programming' started by jacobbannier, Sep 30, 2006.

  1. #1
    Hi, i want to add this piece of javascript :
    <!-- Begin Publisher Code -->
    <script src="http://www.adversal.com/cg.jsp"></script>
    <script src="http://www.adversal.com/publisherJS.jsp"></script>
    <script type="text/javascript" language="javascript">
    initAdversal("8708bb9d80806013c99bb1910fb0a7cc", true);
    </script>
    <!-- End Publisher Code -->
    Code (markup):
    to a cgi script.
    How do i do this? (the script cannot be posted as it's too long)
     
    jacobbannier, Sep 30, 2006 IP
  2. jacobbannier

    jacobbannier Active Member

    Messages:
    1,155
    Likes Received:
    30
    Best Answers:
    0
    Trophy Points:
    90
    #2
    Also, when i upload the script and then try and use it, it just returns a blank page untill i upload the script as it was when i downloaded it, even if i didnt change anything!
     
    jacobbannier, Sep 30, 2006 IP
  3. jimrthy

    jimrthy Guest

    Messages:
    283
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I'm feeling a little slow this morning (I'm behind on my coffee). So please bear with me if I seem stupid.

    The script you originally posted references some [presumably] off-site JavaScript. It sounds to me as though you want to (instead) include that JavaScript directly in your page.

    Oh, and whoever wrote the script originally included some sort of copy control to keep you from doing this.

    Does that pretty much sum it up?
     
    jimrthy, Sep 30, 2006 IP
  4. jacobbannier

    jacobbannier Active Member

    Messages:
    1,155
    Likes Received:
    30
    Best Answers:
    0
    Trophy Points:
    90
    #4
    No, i don't think so. A lot of other sites with this script have popups from adversal.
     
    jacobbannier, Sep 30, 2006 IP
  5. jacobbannier

    jacobbannier Active Member

    Messages:
    1,155
    Likes Received:
    30
    Best Answers:
    0
    Trophy Points:
    90
    #5
    No help? :(
     
    jacobbannier, Oct 1, 2006 IP
  6. DrMalloc

    DrMalloc Peon

    Messages:
    130
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #6
    do you have access to your error logs? outputting a blank page usually means there's an issue with headers for CGI scripts, it's possible you're putting the code somewhere it's not meant to go, or something in the CGI code is causing an error based on it. Hard to really diagnose without knowing more
     
    DrMalloc, Oct 2, 2006 IP
  7. jacobbannier

    jacobbannier Active Member

    Messages:
    1,155
    Likes Received:
    30
    Best Answers:
    0
    Trophy Points:
    90
    #7
    Mmm.. ill have a look
     
    jacobbannier, Oct 3, 2006 IP
  8. TomN

    TomN Peon

    Messages:
    493
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    0
    #8
    If you're trying to put this on a proxy that uses JMarshall's cgi script, simply insert the javascript into the $INCLUDE_FILE html file that is in the directory. You don't need to add it to the CGI proxy script.
     
    TomN, Oct 3, 2006 IP
  9. jvm222

    jvm222 Active Member

    Messages:
    75
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    98
    #9
    there is no $INCLUDE_FILE html file.
     
    jvm222, Oct 7, 2006 IP
  10. jacobbannier

    jacobbannier Active Member

    Messages:
    1,155
    Likes Received:
    30
    Best Answers:
    0
    Trophy Points:
    90
    #10
    Yeah. Atleast i can't find it.
     
    jacobbannier, Oct 7, 2006 IP
  11. jacobbannier

    jacobbannier Active Member

    Messages:
    1,155
    Likes Received:
    30
    Best Answers:
    0
    Trophy Points:
    90
    #11
    Ah i get it.
     
    jacobbannier, Oct 7, 2006 IP
  12. jacobbannier

    jacobbannier Active Member

    Messages:
    1,155
    Likes Received:
    30
    Best Answers:
    0
    Trophy Points:
    90
    #12
    I keep getting the WSOD (white screen of death)
     
    jacobbannier, Oct 7, 2006 IP