Search results

  1. D

    JS: referring page?

    (part of) the JS file: function subMsg(name, subj, cmt, ref) { //... (some code skipped) mTimer = setTimeout('udtCmt(\''+ref+'\');', 1); } function udtMsg(ref) { GetXmlHttpObject(); if (xmlHttp!=null) { url="getMsgs.php?q="+ref+"&sid="+Math.random()...
  2. D

    JS: referring page?

    Right now, what I have is: <div id="messages"></div> <hr> <div id="form_part1"></div> <?php echo "<input type='hidden' name='ref' id='ref' value='" . basename($_SERVER['PHP_SELF']) . "'>"; ?> <div id="form_part2"></div> with the </form> tag in part2; Is it possible to collapse the...
  3. D

    JS: referring page?

    Is there a (simple) way to get JavaScript to return the page that referred the code? I have some of code to add input to a MySQL database (through AJAX), and I want to make it use the same .js file to handle everything.
Top