session.php 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <?php
  2. /*
  3. * Created on 28 juil. 2006 by Elixir Interactive http://www.elixir-interactive.com
  4. */
  5. $nameTools= 'Sessions';
  6. $langFile = array ('registration', 'index','trad4all','tracking');
  7. $cidReset=true;
  8. require ('../inc/global.inc.php');
  9. $this_section = "session_my_space";
  10. api_block_anonymous_users();
  11. $interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
  12. Display :: display_header($nameTools);
  13. $tbl_session = Database :: get_main_table(MAIN_SESSION_TABLE);
  14. /*
  15. ===============================================================================
  16. MAIN CODE
  17. ===============================================================================
  18. */
  19. $sqlSession = " SELECT name
  20. FROM $tbl_session
  21. ORDER BY name ASC
  22. ";
  23. $resultSession = api_sql_query($sqlSession);
  24. if(mysql_num_rows($resultSession)>0)
  25. {
  26. echo '<table class="data_table">
  27. <tr>
  28. <th>
  29. '.get_lang('Title').'
  30. </th>
  31. </tr>
  32. ';
  33. while($a_session = mysql_fetch_array($resultSession))
  34. {
  35. echo '<tr>
  36. <td>
  37. ';
  38. echo $a_session['name'];
  39. echo ' </td>
  40. </tr>
  41. ';
  42. }
  43. echo '</table>';
  44. }
  45. else
  46. {
  47. echo get_lang('NoSession');
  48. }
  49. ?>