A tumblelog CMS built on AJAX, PHP and MySQL.

update.php 1.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. /* ===========================
  3. gelato CMS - A PHP based tumblelog CMS
  4. development version
  5. http://www.gelatocms.com/
  6. gelato CMS is a free software licensed under the GPL 2.0
  7. Copyright (C) 2007 by Pedro Santana <pecesama at gmail dot com>
  8. =========================== */
  9. ?>
  10. <?php
  11. $configFile = dirname(__FILE__).DIRECTORY_SEPARATOR."config.php";
  12. if (!file_exists($configFile)) {
  13. $mensaje = "
  14. <h3 class=\"important\">Error reading configuration file</h3>
  15. <p>There doesn't seem to be a <code>config.php</code> file. I need this before we can get started.</p>
  16. <p>This either means that you did not rename the <code>config-sample.php</code> file to <code>config.php</code>.</p>";
  17. die($mensaje);
  18. } else {
  19. require($configFile);
  20. }
  21. $db = new Conexion_Mysql(DB_name, DB_Server, DB_User, DB_Password);
  22. $sqlStr = "INSERT INTO `".Table_prefix."options` VALUES ('allow_comments', '0');";
  23. $db->ejecutarConsulta($sqlStr);
  24. $sqlStr = "INSERT INTO `".Table_prefix."options` VALUES ('offset_city', 'Mexico/General');";
  25. $db->ejecutarConsulta($sqlStr);
  26. $sqlStr = "INSERT INTO `".Table_prefix."options` VALUES ('offset_time', '-6');";
  27. $db->ejecutarConsulta($sqlStr);
  28. echo "<p><em>Finished!</em></p>";
  29. echo "<p>Now you are running on the new <strong>0.90</strong> version!!!</p>";
  30. ?>