Commit 6c7e5e46e44ace1cdcfc85c0e5632b6b41cb447e

Authored by Jarrett Jordaan
2 parents 1ddc3644 e5442650

Merge branch 'edge' of git@github.com:ktgit/knowledgetree into edge

setup/wizard/steps/registration.php
@@ -50,7 +50,7 @@ class registration extends Step @@ -50,7 +50,7 @@ class registration extends Step
50 * @var array 50 * @var array
51 */ 51 */
52 public $storeInSession = true; 52 public $storeInSession = true;
53 - 53 +
54 /** 54 /**
55 * Controller function for determining the position within the step 55 * Controller function for determining the position within the step
56 * 56 *
@@ -75,10 +75,10 @@ class registration extends Step @@ -75,10 +75,10 @@ class registration extends Step
75 75
76 return 'previous'; 76 return 'previous';
77 }else if($this->confirm()) { 77 }else if($this->confirm()) {
78 - 78 +
79 return 'next'; 79 return 'next';
80 } 80 }
81 - 81 +
82 return 'landing'; 82 return 'landing';
83 } 83 }
84 84
@@ -91,7 +91,7 @@ class registration extends Step @@ -91,7 +91,7 @@ class registration extends Step
91 $this->temp_variables['sel_industry'] = $this->getPostSafe($reg['sel_industry']); 91 $this->temp_variables['sel_industry'] = $this->getPostSafe($reg['sel_industry']);
92 $this->temp_variables['sel_organization_size'] = $this->getPostSafe($reg['sel_organization_size']); 92 $this->temp_variables['sel_organization_size'] = $this->getPostSafe($reg['sel_organization_size']);
93 } 93 }
94 - 94 +
95 /** 95 /**
96 * Safer way to return post data 96 * Safer way to return post data
97 * 97 *
@@ -104,7 +104,7 @@ class registration extends Step @@ -104,7 +104,7 @@ class registration extends Step
104 $value = isset($key) ? $key : ""; 104 $value = isset($key) ? $key : "";
105 return $value; 105 return $value;
106 } 106 }
107 - 107 +
108 public function setInSession() { 108 public function setInSession() {
109 $this->temp_variables['first_name'] = $_POST['submitted']['first_name']; 109 $this->temp_variables['first_name'] = $_POST['submitted']['first_name'];
110 $this->temp_variables['last_name'] = $_POST['submitted']['last_name']; 110 $this->temp_variables['last_name'] = $_POST['submitted']['last_name'];
@@ -113,7 +113,7 @@ class registration extends Step @@ -113,7 +113,7 @@ class registration extends Step
113 $this->temp_variables['sel_industry'] = $_POST['submitted']['industry']; 113 $this->temp_variables['sel_industry'] = $_POST['submitted']['industry'];
114 $this->temp_variables['sel_organization_size'] = $_POST['submitted']['organization_size']; 114 $this->temp_variables['sel_organization_size'] = $_POST['submitted']['organization_size'];
115 } 115 }
116 - 116 +
117 /** 117 /**
118 * Execute the step action to register the user. If the user has already registered then the step will return. 118 * Execute the step action to register the user. If the user has already registered then the step will return.
119 * 119 *
@@ -127,13 +127,10 @@ class registration extends Step @@ -127,13 +127,10 @@ class registration extends Step
127 return true; 127 return true;
128 } 128 }
129 $this->setInSession(); 129 $this->setInSession();
130 -// return true;  
131 - //$this->postForm($_POST);  
132 - //$this->sendToHost($_POST);  
133 130
134 // Post the form using curl 131 // Post the form using curl
135 -// $this->curlForm($_POST);  
136 - 132 + $this->curlForm($_POST);
  133 +
137 // Prevent the form being reposted. 134 // Prevent the form being reposted.
138 $_POST['registered'] = 'yes'; 135 $_POST['registered'] = 'yes';
139 return true; 136 return true;
@@ -536,10 +533,10 @@ class registration extends Step @@ -536,10 +533,10 @@ class registration extends Step
536 $this->temp_variables['industries'] = $industries; 533 $this->temp_variables['industries'] = $industries;
537 $this->temp_variables['org_size'] = $sizes; 534 $this->temp_variables['org_size'] = $sizes;
538 } 535 }
539 - 536 +
540 /** 537 /**
541 * Return whether or not to store a step information in session 538 * Return whether or not to store a step information in session
542 - * 539 + *
543 * @author KnowledgeTree Team 540 * @author KnowledgeTree Team
544 * @param none 541 * @param none
545 * @access public 542 * @access public