Skip to content

Commit

Permalink
Fix privatemessages variable errors (#100)
Browse files Browse the repository at this point in the history
* Update pmfolder.php

* Update addfolder.php

* Update addfolder.php

* fix tabs

* fix tabs

* Update pmfolder.php

changed numericIDOnly to $numericIDOnly on line 37.

* Update addfolder.php

made requested changes to line 122.

---------

Co-authored-by: RedDragonWebDesign <[email protected]>
Co-authored-by: RedDragonWebDesign <[email protected]>
  • Loading branch information
3 people authored Jan 24, 2024
1 parent b5b8191 commit b790929
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/classes/pmfolder.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,15 @@ public function __construct($sqlConnection) {
}

public function select($intIDNum, $numericIDOnly = true) {
$returnVal = false;
$arrSpecialFolders = array("Inbox" => self::INBOX_ID, "Sent Messages" => self::SENTBOX_ID, "Trash" => self::TRASH_ID);
if(in_array($intIDNum, $arrSpecialFolders)) {
$this->arrObjInfo['name'] = array_search($intIDNum, $arrSpecialFolders);
$this->intTableKeyValue = $intIDNum;

}
else {
$returnVal = parent::select($intIDNum, numericIDOnly);
$returnVal = parent::select($intIDNum, $numericIDOnly);
}

return $returnVal;
Expand Down Expand Up @@ -118,4 +119,4 @@ function setFolder($folderID) {
}


}
}
4 changes: 2 additions & 2 deletions src/members/include/privatemessages/addfolder.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@
<table class='formTable'>
<tr>
<td class='formLabel'>Folder Name:</td>
<td class='main'><input type='text' name='foldername' value='".$_POST['foldername']."' class='textBox'></td>
<td class='main'><input type='text' name='foldername' value='".($_POST['foldername'] ?? '')."' class='textBox'></td>
</tr>
<tr>
<td class='formLabel' valign='top'>Display Order:</td>
Expand All @@ -138,4 +138,4 @@
</div>
</form>
";
}
}

0 comments on commit b790929

Please sign in to comment.