Browse Source

Fix update page

pull/189/head
Danang Probo Sayekti 10 years ago
parent
commit
d702e982de
4 changed files with 4 additions and 2 deletions
  1. +1
    -1
      system/admin/views/update.html.php
  2. +2
    -0
      system/htmly.php
  3. +0
    -1
      system/upgrade/index.php
  4. +1
    -0
      system/upgrade/run.php

+ 1
- 1
system/admin/views/update.html.php View File

@ -12,7 +12,7 @@ $updater = new HubUpdater(array(
if ($updater->able()) { if ($updater->able()) {
$info = $updater->getNewestInfo(); $info = $updater->getNewestInfo();
echo '<h3>Update Available</h3>'; echo '<h3>Update Available</h3>';
echo '<p><a href="' . $base . 'admin/update/now/' . $CSRF . '" alt="' . $info['name'] . '">Update to ' . $info['tag_name'] . '</a></p>';
echo '<p><a href="' . site_url() . 'admin/update/now/' . $CSRF . '" alt="' . $info['name'] . '">Update to ' . $info['tag_name'] . '</a></p>';
} else { } else {
echo '<h3>No Available Update</h3>'; echo '<h3>No Available Update</h3>';
echo '<p>You are using the latest HTMLy version.</p>'; echo '<p>You are using the latest HTMLy version.</p>';

+ 2
- 0
system/htmly.php View File

@ -1321,6 +1321,8 @@ get('/admin/update/now/:csrf', function ($CSRF) {
render('updated-to', array( render('updated-to', array(
'head_contents' => head_contents('Updated - ' . blog_title(), blog_description(), site_url()), 'head_contents' => head_contents('Updated - ' . blog_title(), blog_description(), site_url()),
'info' => $updater->getCurrentInfo(), 'info' => $updater->getCurrentInfo(),
'bodyclass' => 'updatepage',
'breadcrumb' => '<a href="' . site_url() . '">' . config('breadcrumb.home') . '</a> &#187; Update HTMLy'
)); ));
} else { } else {
$login = site_url() . 'login'; $login = site_url() . 'login';


+ 0
- 1
system/upgrade/index.php View File

@ -1,5 +1,4 @@
<?php <?php
$config_file = 'config/config.ini';
require 'system/vendor/autoload.php'; require 'system/vendor/autoload.php';
require 'system/htmly.php'; require 'system/htmly.php';

+ 1
- 0
system/upgrade/run.php View File

@ -1,5 +1,6 @@
<?php <?php
$config_file = 'config/config.ini';
config('source', $config_file); config('source', $config_file);
$updater = new Kanti\HubUpdater("danpros/htmly"); $updater = new Kanti\HubUpdater("danpros/htmly");


Loading…
Cancel
Save