<?php
/*
  Some Common/Global Variables for publicexambd.com (Global Variables)
*/

global $global_created_at;
$global_created_at=date("Y-m-d H:i:s");

global $global_language;
if(isset($_SESSION['language']) && $_SESSION['language']!="")
  $global_language=$_SESSION['language'];
else
{
  $global_language="en";
  $_SESSION['language']="en";
}

/*
  This function will return member information based on $id
  @input:
    $id: member id
  @output:
    return an array of member information from member_info table.
*/
function get_member_info_by_id($member_id, $show_query=false)
{
  $sql="SELECT member.* FROM member_info member WHERE member.id='$member_id'";
  if($show_query)
    echo $sql;
  return get_single_row($sql);
}
?>