summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--application/modules/fbgui/controllers/IndexController.php12
-rw-r--r--application/modules/fbgui/views/scripts/index/start.phtml10
2 files changed, 12 insertions, 10 deletions
diff --git a/application/modules/fbgui/controllers/IndexController.php b/application/modules/fbgui/controllers/IndexController.php
index c874d97..23471a2 100644
--- a/application/modules/fbgui/controllers/IndexController.php
+++ b/application/modules/fbgui/controllers/IndexController.php
@@ -103,16 +103,8 @@ class Fbgui_IndexController extends Zend_Controller_Action
$session->setBootmenuentryID($bootmenuntryID);
$session->setBootosID($bootmenuentry->getBootosID());
$sessionMapper->save($session);
- echo "<h1>Downloading</h1>";
- echo "<script>\n";
- echo "fbgui.setCallbackOnFinished('foo();');\n";
- echo "fbgui.startDownload('http://132.230.4.27/resource/getkernel/alpha/".$_SESSION['alphasessionID']."/file/kernel');\n";
- echo "fbgui.startDownload('http://132.230.4.27/resource/getinitramfs/alpha/".$_SESSION['alphasessionID']."/file/initramfs');\n";
- echo "fbgui.startDownload('http://132.230.4.27/resource/getkcl/alpha/".$_SESSION['alphasessionID']."/file/kcl');\n";
- echo "function foo(){
- fbgui.quit();
- }";
- echo "</script>";
+
+ $this->view->alphaid = $_SESSION['alphasessionID'];
}
diff --git a/application/modules/fbgui/views/scripts/index/start.phtml b/application/modules/fbgui/views/scripts/index/start.phtml
index a59dd3e..94e8d97 100644
--- a/application/modules/fbgui/views/scripts/index/start.phtml
+++ b/application/modules/fbgui/views/scripts/index/start.phtml
@@ -112,3 +112,13 @@ function updateProgress(p, s, u){
<a href='/fbgui'>back</a>
<div id="progressbar" style="height: 15px;"></div>
+<h1>Downloading</h1>
+<script>
+fbgui.setCallbackOnFinished('foo();');
+fbgui.startDownload('http://<?php echo $this->host; ?>/resource/getkernel/alpha/<?php echo $this->alphaid; ?>/file/kernel');
+fbgui.startDownload('http://<?php echo $this->host; ?>/resource/getinitramfs/alpha/<?php echo $this->alphaid; ?>/file/initramfs');
+fbgui.startDownload('http://<?php echo $this->host; ?>/resource/getkcl/alpha/<?php echo $this->alphaid; ?>/file/kcl');
+function foo(){
+ fbgui.quit();
+}
+</script>";