title: passing session to a hidden field in a iframe on the same domain
body: <p>I am using this code </p>
  
  <blockquote>
    <p>
  
  <pre><code>  session_start();
  
    if (!isset($_SESSION["origURL"]))
      $_SESSION["origURL"] = $_SERVER["HTTP_REFERER"];
  
  $referrer = $_SESSION["origURL"];
  if(preg_match("/[\.\/](google|yahoo|bing|geegain|mywebsearch|ask|alltheweb)\.[a-z\.]{2,5}[\/]/i",$referrer,$search_engine)){
  $referrer_query = parse_url($referrer);
  $referrer_query = $referrer_query["query"];
  $q = "[q|p]"; //Yahoo uses both query strings, I am using switch() for each search engine
  preg_match("/".$q."=(.*?)&amp;/",$referrer,$keyword);
  $_SESSION["SEKW"]  = urldecode($keyword[1]);
  }
  ?&gt;
  </code></pre>
  </blockquote>
  
  <p>to track referral keywords and  I call this in to a hidden field of my forms which works great. </p>
  
  <p>My problem is I have had to change my form to an iframe and I can no longer call the session now as the form is in a iframe.</p>
  
  <p>so i had </p>
  
  <p>domain.com/myform.php ( every thing worked )</p>
  
  <p>I am now using an iframe from</p>
  
  <p>domain.com/forms/form.php</p>
  
  <p>to place my form into</p>
  
  <p>domain.com/myform.php</p>
  
  <p>I hope I have explained my self correctly </p>