| 1 | <?php |
|---|
| 2 | /*
|
|---|
| 3 |
|
|---|
| 4 | This file is part of omCollab.
|
|---|
| 5 |
|
|---|
| 6 | Copyright (c) 2008 omCollab (Openmethodology Project)
|
|---|
| 7 | http://www.openmethodology.org
|
|---|
| 8 | http://mike2.openmethodology.org/wiki/OmCollab
|
|---|
| 9 |
|
|---|
| 10 | And parts copyright of Scuttle project
|
|---|
| 11 | (http://sourceforge.net/projects/scuttle/, http://scuttle.org/)
|
|---|
| 12 |
|
|---|
| 13 | omCollab is free software: you can redistribute it and/or modify
|
|---|
| 14 | it under the terms of the GNU General Public License as published by
|
|---|
| 15 | the Free Software Foundation, either version 3 of the License, or
|
|---|
| 16 | (at your option) any later version.
|
|---|
| 17 |
|
|---|
| 18 | omCollab is distributed in the hope that it will be useful,
|
|---|
| 19 | but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 20 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|---|
| 21 | GNU General Public License for more details.
|
|---|
| 22 |
|
|---|
| 23 | */
|
|---|
| 24 |
|
|---|
| 25 | header('Content-Type: text/xml; charset=UTF-8'); |
|---|
| 26 | header("Last-Modified: ". gmdate("D, d M Y H:i:s") ." GMT"); |
|---|
| 27 | header("Cache-Control: no-cache, must-revalidate"); |
|---|
| 28 | |
|---|
| 29 | require_once('header.inc.php'); |
|---|
| 30 | $userservice = & ServiceFactory :: getServiceInstance('UserService'); |
|---|
| 31 | if ($userservice->isReserved($_GET['username'])) { |
|---|
| 32 | $result = 'false'; |
|---|
| 33 | } else { |
|---|
| 34 | $result = $userservice->getUserByUsername($_GET['username']) ? 'false' : 'true'; |
|---|
| 35 | } |
|---|
| 36 | ?> |
|---|
| 37 | <response> |
|---|
| 38 | <method>isAvailable</method> |
|---|
| 39 | <result><?php echo $result; ?></result> |
|---|
| 40 | </response> |
|---|