<?php

  print_r("1");
  exit;

//判断序列号是否过期
if( isset($_GET['key']) )
{ 
  $licensekey = $_GET['key'];    
}
else
{
 print_r("参数错误!");
  exit;
}

//连接MySQL
$conn = @mysql_connect("localhost", "gili0512", "nIJ9qatVBLKS");

if($conn == FALSE)
{	
  print_r("连接数据失败!");
  exit;
}

//选择数据库
mysql_select_db("gili0512_livecheck");

//执行SQL
$result = @mysql_query("SELECT * FROM gslicenseinfo where RegKey='$licensekey'");


//显示查询结果
 

if(mysql_num_rows($result) > 0)
{
  While($row = mysql_fetch_array($result))
  {
      $IsExpired=$row["IsExpired"];

      if ($IsExpired)
      {
        print_r("Expired");
      }
      else
      {
        print_r("Live");
      }
     //print_r("<br />");
     // print_r($row["id"].",".$row["RegCode"].",".$row["Activations"].",".$row["IsExpired"]);
     // print_r("<br />");
  }
}
else
{
  print_r("没有该注册码！");

}

//释放结果集
mysql_free_result($result);

//关闭连接
mysql_close();


?> 