Mercurial > hg > rc2
comparison program/include/rcmail.php @ 17:dd5ed6ef69c9
Slowly cleaning up more php8 Warnings/deprecations
| author | Charlie Root |
|---|---|
| date | Mon, 06 Oct 2025 12:20:32 -0400 |
| parents | 85a746e95663 |
| children | b6a96bdd6b29 |
comparison
equal
deleted
inserted
replaced
| 16:1866b439e6d3 | 17:dd5ed6ef69c9 |
|---|---|
| 821 | 821 |
| 822 $p = array('_action' => @func_get_arg(0)); | 822 $p = array('_action' => @func_get_arg(0)); |
| 823 } | 823 } |
| 824 | 824 |
| 825 $pre = array(); | 825 $pre = array(); |
| 826 $task = $p['_task'] ?: ($p['task'] ?: $this->task); | 826 $task = ($p['_task']??null) ?: ($p['task'] ?: $this->task); |
| 827 $pre['_task'] = $task; | 827 $pre['_task'] = $task; |
| 828 unset($p['task'], $p['_task']); | 828 unset($p['task'], $p['_task']); |
| 829 | 829 |
| 830 $url = $this->filename; | 830 $url = $this->filename; |
| 831 $delm = '?'; | 831 $delm = '?'; |
| 836 $url .= $delm.urlencode($par).'='.urlencode($val); | 836 $url .= $delm.urlencode($par).'='.urlencode($val); |
| 837 $delm = '&'; | 837 $delm = '&'; |
| 838 } | 838 } |
| 839 } | 839 } |
| 840 | 840 |
| 841 $base_path = strval($_SERVER['REDIRECT_SCRIPT_URL'] ?: $_SERVER['SCRIPT_NAME']); | 841 $base_path = strval(($_SERVER['REDIRECT_SCRIPT_URL']??null) ?: $_SERVER['SCRIPT_NAME']); |
| 842 $base_path = preg_replace('![^/]+$!', '', $base_path); | 842 $base_path = preg_replace('![^/]+$!', '', $base_path); |
| 843 | 843 |
| 844 if ($secure && ($token = $this->get_secure_url_token(true))) { | 844 if ($secure && ($token = $this->get_secure_url_token(true))) { |
| 845 // add token to the url | 845 // add token to the url |
| 846 $url = $token . '/' . $url; | 846 $url = $token . '/' . $url; |
