* published by the Free Software Foundation; either version 2.1 of * the License, or (at your option) any later version. * * This software is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this software; if not, write to the Free * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA * 02110-1301 USA, or see the FSF site: http://www.fsf.org. ******************************************************************************/ class RingsideApiClientsConfig { public static $webUrl = ""; public static $serverUrl = ""; public static $socialUrl = ""; } if (isset($_SERVER['SERVER_NAME'])) { if (isset($_SERVER['HTTP_HOST'])) { $host = $_SERVER['HTTP_HOST']; $port = ''; } else { $host = $_SERVER['SERVER_NAME']; $port = isset($_SERVER['SERVER_PORT']) && $_SERVER['SERVER_PORT'] != 80 ? ':' . $_SERVER['SERVER_PORT'] : ''; } RingsideApiClientsConfig::$webUrl = "http://{$host}{$port}/"; RingsideApiClientsConfig::$socialUrl = "http://{$host}{$port}/trust.php"; RingsideApiClientsConfig::$serverUrl = "http://{$host}{$port}/restserver.php"; }
# # $webUrl = The Web page url to return to an application $webUrl = "http://{$_SERVER['SERVER_NAME']}:{$_SERVER['SERVER_PORT']}/web"; ### Configuration for social ### # RingsideSocial needs a connection the API server, even though they might be local # their must be a Key/Secret required by Social to talk to the API engine. # If the social layer gets deployed separately, also to make sure remote apps do not # impersonate the RingsideSocial layer. # We suggest adding in some random text right 6 to 8 characters long, such as 'sjd2jds'; # $socialApiKey = 'Jkinner'; $socialSecretKey = 'Jkinner'; $socialRoot = '/social'; $socialUrl = "http://{$_SERVER['SERVER_NAME']}:{$_SERVER['SERVER_PORT']}/social"; ### Configuration for web ### # Every WEB/ThirdParty connecting must maintain a NETWORK key indicating which WEB is connecting. # This is the default/internal web community packaged with Ringside $networkKey = 'ringside-web'; # Web apps need to do redirects and other URL related activities, however it does not know how the # calling web front end is setup. This setting tells it how to construct absolute urls. $webRoot = '/web'; ### Configuration for web-apps ### # Set the support email address to be used during installation. $supportEmail = 'admin@localhost'; ### Configuration for demo-apps ### ### Configuration for API client ### require_once 'ringside/api/clients/RingsideApiClientsConfig.php'; RingsideApiClientsConfig::$serverUrl = $serverUrl; RingsideApiClientsConfig::$webUrl = $webUrl; RingsideApiClientsConfig::$socialUrl = $socialUrl;
<?php ### Configuration for api ### echo "USING TESTSETTINGS.PHP\n"; require_once 'ringside/api/clients/RingsideApiClientsConfig.php'; include dirname(__FILE__) . "/../../../LocalSettings.php"; # Database configuration setttings. $db_type = 'mysql'; $db_username = '******'; $db_password = '******'; $db_server = 'entourage:3306'; $db_name = 'ringfb_test'; $host = 'localhost'; $port = ':8888'; RingsideApiClientsConfig::$webUrl = "http://{$host}{$port}/web/"; RingsideApiClientsConfig::$socialUrl = "http://{$host}{$port}/social/"; RingsideApiClientsConfig::$serverUrl = "http://{$host}{$port}/api/restserver.php";