if (isset($_POST['rep'])) { $reputation = $_SESSION['cc']->getReputationByName($_POST['rep']); if (isset($reputation)) { $return['desc'] = $reputation->description; } else { treatCreatorErrors($return, $_SESSION['cc']->getLastError()); } } //GET SKILL DECRIPTION if (isset($_POST['skill'])) { $skill = $_SESSION['cc']->getSkillByAtomUid($_POST['skill']); //error_log("Getting skill id: " . $_POST['skill']. " -> " . $skill->name); if ($skill->description == null || $skill->description == "") { $prefix = $skill->prefix; if ($prefix != null || $prefix != "") { $return['desc'] = $provider->getPrefixDescription($prefix); } else { $return['desc'] = "No description available, sorry ..."; } } else { $return['desc'] = $skill->description; } } //ADD TMP ACTIVE SKILL if (isset($_POST['newTmpActSkill'])) { //error_log("adding active skill \"" . $_POST['newTmpSkillPrefix'] . "\": \"" . $_POST['newTmpActSkill']."\""); if (!$_SESSION['cc']->addSkill($_POST['newTmpActSkill'], $provider->getAptForPrefix($_POST['newTmpSkillPrefix']), EPSkill::$ACTIVE_SKILL_TYPE, EPSkill::$NO_DEFAULTABLE, $_POST['newTmpSkillPrefix'])) { treatCreatorErrors($return, $_SESSION['cc']->getLastError()); } } //ADD TMP KNOWLEDGE SKILL
<br> <br> <input type="submit" value="Insert"> </form> <p>Skill Prefix on database</p> <table border = "1"> <tr> <th>Name</th> <th>Description</th> <th>Linked Apt</th> <th>Type</th> <th>DELETE FROM DATABASE</th> </tr> <?php foreach ($_SESSION['prefixList'] as $m) { echo "<tr>"; echo "<td>" . $m . "</td>"; echo "<td>" . $epListP->getPrefixDescription($m) . "</td>"; echo "<td>" . $epListP->getAptForPrefix($m) . "</td>"; echo "<td>" . $epListP->getTypeForPrefix($m) . "</td>"; echo "<td><form action='./skillPrefix.php' method='post'><input type='hidden' name='deletePrefix' value='" . $m . "'><input type='submit' value='Delete this line'></form></td>"; echo "</tr>"; } ?> </table> </body> </html>