Index: Dev/trunk/classes/Step.php
===================================================================
--- Dev/trunk/classes/Step.php	(revision 149)
+++ Dev/trunk/classes/Step.php	(revision 150)
@@ -1,4 +1,3 @@
 <?php
-
 /*
  * To change this template, choose Tools | Templates
@@ -16,20 +15,22 @@
     public $type;
     public $name;
-    public $id;
+    public $uid;
     // merging step and displayStep
 
     public $imageURL;
 
-    public function __construct($t, $n, $i) {
+    public function __construct($type, $name, $uid) {
 
-        if (strtolower($t) == "application" || strtolower($t) == "dashboard" || strtolower($t) == "questionnaire") {
-            $this->type = $t;
-            $this->name = $n;
-            $this->id = $i;
+        // check if type given is valid, set internal variables
+        if (strtolower($type) == "application" || strtolower($type) == "dashboard" || strtolower($type) == "questionnaire") {
+            $this->type = strtolower($type);
+            $this->name = strtolower($name);
+            $this->id = strtolower($uid);
         } else {
-            die("Invalid type given: " . $t . "\n $n $i");
+            die("Invalid type given: " . $type . "\n $name $uid");
         }
 
-        switch (strtolower($this->type)) {
+        // assign relevant icon
+        switch ($this->type) {
             case "questionnaire":
                 $this->imageURL = "images/icons/questionnaire.png";
@@ -47,17 +48,16 @@
     }
 
+    public function init() {
+        if (isset($this->type) && isset($this->imageURL) && isset($this->name)) {
+            ?>
+            <div class="displayStep" onClick="checkSelectedStep('<?php echo $this->id; ?>');"><div class="displayStepIcon"><img src="<?php echo $this->imageURL; ?>" /></div><?php echo $this->name; ?></div>
+            <?php
+        }
+    }
+
     public function AdjustID($offset) {
         $this->id += $offset;
     }
 
-    public function DrawStep() {
-        if (isset($this->type) && isset($this->imageURL) && isset($this->name)) {
-            ?>
-<div class="displayStep" onClick="checkSelectedStep('<?php echo $this->id; ?>');"><div class="displayStepIcon"><img src="<?php echo $this->imageURL; ?>" /></div><?php echo $this->name; ?></div>
-<?php        
 }
-    }
-
-}
-
 ?>
Index: Dev/trunk/classes/pipelineSequencer.php
===================================================================
--- Dev/trunk/classes/pipelineSequencer.php	(revision 149)
+++ Dev/trunk/classes/pipelineSequencer.php	(revision 150)
@@ -13,19 +13,19 @@
 
     // properties
-    private $pipeline = array();
-    private $name = "testSequencer";
+    private $pipeline;
+    private $name = "empty";
     private $numStepsInArray = 0;
     private $maxNumStepsInArray = 10;
     private $selectedStep;
 
-    public function __construct($pipeline, $name, $id) {
-        $this->pipeline = $pipeline;
-        $this->name = $name;
+    public function __construct($uid) {
+        $dbi = new DatabaseInterface();
+        $this->pipeline = $dbi->get("pipeline", array("uid"=>$uid));
     }
 
-    public function DrawSequencer() {
+    public function init() {
         ?>
         <br /><form name="sequencer" action="pipelineEditor.php" method="post"><fieldset id="sequencer">
-                <div class="title">Name: <?php echo $this->name; ?> </div>
+                <div class="title">Name: <?php echo $this->pipeline->name; ?> </div>
 
                 <div class="seqContent">
@@ -91,5 +91,5 @@
                 if ($this->numStepsInArray < $this->maxNumStepsInArray) {
                     //var_dump($step);
-                    $step->DrawStep();
+                    $step->init();
                     $this->numStepsInArray++;
                     if ($this->numStepsInArray < $this->maxNumStepsInArray && $this->numStepsInArray < count($this->pipeline)) {
@@ -133,6 +133,10 @@
     }
 
-    public function GetFromDB() {
+    public function HandlePost() {
 
+        //this doesn't actually work, the sequencer doesn't know what the uid is yet. This data should be POSTed upon refresh!
+        
+        
+        
         if (isset($_POST['destroy'])) {
             unset($_POST['destroy']);
@@ -171,4 +175,22 @@
     }
 
+    private function Javascript() {
+        ?>
+        <!-- 
+        Add JS code for selecting steps, highlighting them, reordering, etc.
+        Is a refresh of the page (with subsequent querying of database really necessary?
+        
+        -->
+        <script type="text/javascript">
+            function selectStep(step) {
+                step.addClass("selected");
+                document.sequencer.controls.selectedStep.value = step.name;
+            }
+        </script>
+
+
+        <?php
+    }
+
 }
 ?>
Index: Dev/trunk/css/awesome.css
===================================================================
--- Dev/trunk/css/awesome.css	(revision 149)
+++ Dev/trunk/css/awesome.css	(revision 150)
@@ -658,5 +658,5 @@
 }
 
-.seqContent .displayStep {
+.displayStep {
     width: 52px;
     padding: 0;
@@ -667,5 +667,9 @@
 }
 
-.seqContent .displayStep .displayStepIcon {
+.displayStep.selected {
+    background-color: rgba(255, 255, 255, 0.5);
+}
+
+.displayStep .displayStepIcon {
     width: 50px;
     height: 50px;
@@ -675,5 +679,5 @@
 }
 
-.seqContent .displayStep p{
+.displayStep p{
     margin-top: 5px;
     font-weight: normal;
Index: Dev/trunk/js/sequencerScripts.js
===================================================================
--- Dev/trunk/js/sequencerScripts.js	(revision 149)
+++ Dev/trunk/js/sequencerScripts.js	(revision 150)
@@ -38,4 +38,5 @@
 function checkSelectedStep(number){
     document.sequencer.selectedStep.value = number;
+    var step = document.getElementById("seqContent")
     document.refresh();
 }
Index: Dev/trunk/pipelineEditor.php
===================================================================
--- Dev/trunk/pipelineEditor.php	(revision 149)
+++ Dev/trunk/pipelineEditor.php	(revision 150)
@@ -6,5 +6,5 @@
   } */
 
-//var_dump($_POST);
+
 
 if (isset($_SESSION['currentPipeline'])) {
@@ -14,8 +14,8 @@
 }
 
-$sequencer->GetFromDB();    // doesn't actually currently get from db, uses session/post as a temporary alternative.
+$sequencer->HandlePost();    // doesn't actually currently get from db, uses session/post as a temporary alternative.
 
 
-//$dbi = new DatabaseInterface();
+
 ?>
 
@@ -42,5 +42,5 @@
         <div id="wrapper">
             <div id="content">
-<?php $sequencer->DrawSequencer(); ?>
+<?php $sequencer->init(); ?>
                 <?php $toolbox = new Toolbox(); ?>
             </div>
