diff options
| author | Zach DeCook <zachdecook@librem.one> | 2022-06-06 20:07:54 +0000 |
|---|---|---|
| committer | Zach DeCook <zachdecook@librem.one> | 2022-06-06 20:07:54 +0000 |
| commit | 385004df10d706fca1323763e84da6fd11968603 (patch) | |
| tree | 8f6c2de1438bba269c7b1d16a9e20c59e2b7f208 /index.php | |
| parent | dd106c063b84060dd158cd5d3b79f4ac3a15eecc (diff) | |
| download | php-xmpp-invitation-385004df10d706fca1323763e84da6fd11968603.tar.gz | |
URIs: Add Contact Invitation with IBR
Diffstat (limited to 'index.php')
| -rw-r--r-- | index.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/index.php b/index.php index 6b37a18..a8d9195 100644 --- a/index.php +++ b/index.php @@ -19,6 +19,7 @@ $uri = "xmpp:" . $uri; } // TODO: Better invitation type detection. + $parsed = parse_url($uri); $action = $lang->chat; if ( str_contains($uri, '?join') ) { $action = $lang->muc; @@ -27,8 +28,9 @@ if ( str_contains($uri, "@") ) { $action = $lang->register_name; } + } elseif ( str_contains($parsed['query'], 'ibr=y') ) { + $action = $lang->ibr; } - $parsed = parse_url($uri); $name = explode("@", $parsed['path'])[0]; $server = explode("@", $parsed['path'])[1] ?? $name; function t($template) { |
