Revision 42
Added by stefan about 20 years ago
| class.wb.php | ||
|---|---|---|
| 71 | 71 |
|
| 72 | 72 |
// Modified addslashes function which takes into account magic_quotes |
| 73 | 73 |
function add_slashes($input) {
|
| 74 |
return addslashes($input); |
|
| 75 | 74 |
if ( get_magic_quotes_gpc() || ( !is_string($input) ) ) {
|
| 76 | 75 |
return $input; |
| 77 | 76 |
} |
| ... | ... | |
| 88 | 87 |
return $output; |
| 89 | 88 |
} |
| 90 | 89 |
|
| 90 |
function strip_slashes_dummy($input) {
|
|
| 91 |
return $input; |
|
| 92 |
} |
|
| 93 |
|
|
| 91 | 94 |
// Escape backslashes for use with mySQL LIKE strings |
| 92 | 95 |
function escape_backslashes($input) {
|
| 93 |
return str_replace("\\","\\\\",$output);
|
|
| 96 |
return str_replace("\\","\\\\",$input);
|
|
| 94 | 97 |
} |
| 95 | 98 |
|
| 96 | 99 |
// Get POST data |
| ... | ... | |
| 151 | 154 |
|
| 152 | 155 |
// Get the current users display name |
| 153 | 156 |
function get_display_name() {
|
| 154 |
return $this->strip_slashes($_SESSION['DISPLAY_NAME']); |
|
| 157 |
return $this->strip_slashes_dummy($_SESSION['DISPLAY_NAME']);
|
|
| 155 | 158 |
} |
| 156 | 159 |
|
| 157 | 160 |
// Get the current users email address |
Also available in: Unified diff
Changed most occurrences of strip_slashes to new dummy method strip_slashes_dummy.