Source for file bug_report.php

Documentation is available at bug_report.php

  1. <?php
  2. /**
  3.  * bug_report.php
  4.  *
  5.  * This generates the bug report data, gives information about where
  6.  * it will be sent to and what people will do with it, and provides
  7.  * a button to show the bug report mail message in order to actually
  8.  * send it.
  9.  *
  10.  * @copyright 1999-2020 The SquirrelMail Project Team
  11.  * @license http://opensource.org/licenses/gpl-license.php GNU Public License
  12.  * @version $Id: bug_report.php 14845 2020-01-07 08:09:34Z pdontthink $
  13.  * @package plugins
  14.  * @subpackage bug_report
  15.  */
  16.  
  17.  
  18. // This is the bug_report options page
  19. //
  20. define('PAGE_NAME''bug_report_options');
  21.  
  22.  
  23. // Include the SquirrelMail initialization file.
  24. //
  25. require('../../include/init.php');
  26.  
  27.  
  28. // load plugin functions
  29. //
  30. require_once(SM_PATH 'plugins/bug_report/functions.php');
  31.  
  32.  
  33.  
  34.  
  35. // error out when bug_report plugin is disabled 
  36. // or is called by the wrong user
  37. //
  38. if (is_plugin_enabled('bug_report'|| bug_report_check_user()) {
  39.     error_box(_("Plugin is disabled."));
  40.     $oTemplate->display('footer.tpl');
  41.     exit();
  42. }
  43.  
  44.  
  45. // get system specs
  46. //
  47. require_once(SM_PATH 'plugins/bug_report/system_specs.php');
  48. list($body$warnings$correctionsget_system_specs();
  49.  
  50. $body_top "I am subscribed to the this mailing list.\n" .
  51.             " (applies when you are sending email to SquirrelMail mailing list)\n".
  52.             "  [ ]  True - No need to CC me when replying\n" .
  53.             "  [ ]  False - Please CC me when replying\n" .
  54.             "\n" .
  55.             "This bug occurs when I ...\n" .
  56.             "  ... view a particular message\n" .
  57.             "  ... use a specific plugin/function\n" .
  58.             "  ... try to do/view/use ....\n" .
  59.             "\n\n\n" .
  60.             "The description of the bug:\n\n\n" .
  61.             "I can reproduce the bug by:\n\n\n" .
  62.             "(Optional) I got bored and found the bug occurs in:\n\n\n" .
  63.             "(Optional) I got really bored and here's a fix:\n\n\n" .
  64.             "----------------------------------------------\n\n";
  65.  
  66. $body $body_top $body;
  67.  
  68. global $oTemplate$bug_report_admin_email;
  69. if (!empty($bug_report_admin_email)) {
  70.     $oTemplate->assign('admin_email'$bug_report_admin_email);
  71. }
  72. $oTemplate->assign('message_body'$body);
  73. $oTemplate->assign('title_bg_color'$color[0]);
  74. $oTemplate->assign('warning_messages'$warnings);
  75. $oTemplate->assign('correction_messages'$corrections);
  76. $oTemplate->assign('warning_count'sizeof($warnings));
  77. $oTemplate->assign('version'SM_VERSION);
  78. $oTemplate->display('plugins/bug_report/usage.tpl');
  79. $oTemplate->display('footer.tpl');

Documentation generated on Mon, 13 Jan 2020 04:22:02 +0100 by phpDocumentor 1.4.3