PageRenderTime 33ms CodeModel.GetById 10ms RepoModel.GetById 0ms app.codeStats 0ms

/trunk/rucrm/7631154694d7ce8e43427a8.79178660install/welcome.php

https://code.google.com/p/vtiger-ru-fork/
PHP | 146 lines | 129 code | 8 blank | 9 comment | 6 complexity | bc2addaab08b9fa6a40745123f6faaa0 MD5 | raw file
Possible License(s): LGPL-2.1, MPL-2.0-no-copyleft-exception, GPL-2.0, LGPL-3.0
  1. <?php
  2. /*+**********************************************************************************
  3. * The contents of this file are subject to the vtiger CRM Public License Version 1.0
  4. * ("License"); You may not use this file except in compliance with the License
  5. * The Original Code is: vtiger CRM Open Source
  6. * The Initial Developer of the Original Code is vtiger.
  7. * Portions created by vtiger are Copyright (C) vtiger.
  8. * All Rights Reserved.
  9. ************************************************************************************/
  10. //get php configuration settings. requires elaborate parsing of phpinfo() output
  11. ob_start();
  12. phpinfo(INFO_GENERAL);
  13. $string = ob_get_contents();
  14. ob_end_clean();
  15. $pieces = explode("<h2", $string);
  16. $settings = array();
  17. require_once('config.inc.php');
  18. $install_permitted = false;
  19. if(!isset($dbconfig['db_hostname']) || $dbconfig['db_status']=='_DB_STAT_') {
  20. $install_permitted = true;
  21. }
  22. foreach($pieces as $val)
  23. {
  24. preg_match("/<a name=\"module_([^<>]*)\">/", $val, $sub_key);
  25. preg_match_all("/<tr[^>]*>
  26. <td[^>]*>(.*)<\/td>
  27. <td[^>]*>(.*)<\/td>/Ux", $val, $sub);
  28. preg_match_all("/<tr[^>]*>
  29. <td[^>]*>(.*)<\/td>
  30. <td[^>]*>(.*)<\/td>
  31. <td[^>]*>(.*)<\/td>/Ux", $val, $sub_ext);
  32. foreach($sub[0] as $key => $val) {
  33. if (preg_match("/Configuration File \(php.ini\) Path /", $val)) {
  34. $val = preg_replace("/Configuration File \(php.ini\) Path /", '', $val);
  35. $phpini = strip_tags($val);
  36. }
  37. }
  38. }
  39. ?>
  40. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  41. <html>
  42. <head>
  43. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  44. <title><?php echo $installationStrings['LBL_VTIGER_CRM_5']. ' - ' . $installationStrings['LBL_CONFIG_WIZARD']. ' - ' . $installationStrings['LBL_WELCOME']?></title>
  45. <link href="include/install/install.css" rel="stylesheet" type="text/css">
  46. </head>
  47. <body class="small cwPageBg" topmargin="0" leftmargin="0" marginheight="0" marginwidth="0">
  48. <br>
  49. <!-- Table for cfgwiz starts -->
  50. <table border=0 cellspacing=0 cellpadding=0 width=80% align=center>
  51. <tr>
  52. <td class="cwHeadBg" align=left><img src="include/install/images/configwizard.gif" alt="<?php echo $installationStrings['LBL_CONFIG_WIZARD']; ?>" hspace="20" title="<?php echo $installationStrings['LBL_CONFIG_WIZARD']; ?>"></td>
  53. <td class="cwHeadBg1" align=right><img src="include/install/images/vtigercrm5.gif" alt="<?php echo $installationStrings['LBL_VTIGER_CRM_5']; ?>" title="<?php echo $installationStrings['LBL_VTIGER_CRM_5']; ?>"></td>
  54. <td class="cwHeadBg1" width=2%></td>
  55. </tr>
  56. </table>
  57. <table border=0 cellspacing=0 cellpadding=0 width=80% align=center>
  58. <tr>
  59. <td background="include/install/images/topInnerShadow.gif" align=left><img height="10" src="include/install/images/topInnerShadow.gif" ></td>
  60. </tr>
  61. </table>
  62. <table border=0 cellspacing=0 cellpadding=10 width=80% align=center>
  63. <tr>
  64. <td class="small" bgcolor="#4572BE" align=center>
  65. <!-- Master display -->
  66. <table border=0 cellspacing=0 cellpadding=0 width=97%>
  67. <tr>
  68. <td width=100% valign=top class="cwContentDisplay" align=left>
  69. <!-- Right side tabs -->
  70. <table border=0 cellspacing=0 cellpadding=10 width=70% align=center>
  71. <tr>
  72. <td class=small align=left colspan=2><img src="include/install/images/welcome.gif" alt="<?php echo $installationStrings['LBL_WELCOME_CONFIG_WIZARD']; ?>" title="<?php echo $installationStrings['LBL_WELCOME_CONFIG_WIZARD']; ?>">
  73. <br><hr noshade size=1>
  74. </td>
  75. </tr>
  76. <tr class='level3'>
  77. <td valign=top align=left class="small contentDisplay fixedSmallHeight" style="padding-left:20px;" colspan=2>
  78. <p style='text-align:center;font-weight:bold;'><?php echo $installationStrings['LBL_ABOUT_CONFIG_WIZARD'] . $vtiger_current_version; ?>.</p>
  79. <p><br><?php echo $installationStrings['LBL_ABOUT_VTIGER']; ?></p>
  80. </td>
  81. </tr>
  82. <tr>
  83. <td colspan=2></span></td>
  84. </tr>
  85. <tr>
  86. <?php
  87. if($install_permitted == true){
  88. ?>
  89. <td align=right>
  90. <form action="install.php" method="post" name="installform" id="form">
  91. <input type="hidden" name="file" value="LicenceAgreement.php" />
  92. <input type="hidden" name="install" value="true" />
  93. <input type="button" class="button" value='<?php echo $installationStrings['LBL_INSTALL']; ?>' alt="<?php echo $installationStrings['LBL_INSTALL']; ?>" title="<?php echo $installationStrings['LBL_INSTALL']; ?>" onClick="window.document.installform.submit();">
  94. </form>
  95. </td>
  96. <td align=left>
  97. <?php
  98. }
  99. else{
  100. ?>
  101. <td align=center colspan=2>
  102. <?php
  103. }
  104. ?>
  105. <form action="install.php" method="post" name="Migrateform" id="form">
  106. <input type="hidden" name="filename" value="SetMigrationConfig.php" />
  107. <input type="hidden" name="file" value="CheckSystem.php" />
  108. <input type="hidden" name="migrate" value="true" />
  109. <input type="button" class="button" value='<?php echo $installationStrings['LBL_MIGRATE']; ?>' alt="<?php echo $installationStrings['LBL_MIGRATE']; ?>" title="<?php echo $installationStrings['LBL_MIGRATE']; ?>" onClick="window.document.Migrateform.submit();">
  110. </form>
  111. </td>
  112. </tr>
  113. </table>
  114. </td>
  115. </tr>
  116. </table>
  117. <!-- Master display stops -->
  118. <br>
  119. </td>
  120. </tr>
  121. </table>
  122. <table border=0 cellspacing=0 cellpadding=0 width=80% align=center>
  123. <tr>
  124. <td class='cwfooterBg' background="include/install/images/bottomGradient.gif"><br></td>
  125. </tr>
  126. </table>
  127. <table border=0 cellspacing=0 cellpadding=0 width=80% align=center>
  128. <tr>
  129. <td align=center><img src="include/install/images/bottomShadow.jpg"></td>
  130. </tr>
  131. </table>
  132. <table border=0 cellspacing=0 cellpadding=0 width=80% align=center>
  133. <tr>
  134. <td class=small align=center> <a href="http://code.google.com/p/vtiger-ru-fork/" target="_blank">Russian VtigerCRM Fork</a></td>
  135. </tr>
  136. </table>
  137. </body>
  138. </html>