<?

/*
FlexCMS (http://www.flexcms.com)
Flexible, Powerful, Affordable.

Contents of this file are protected by the copyright
notice found at http://www.flexcms.com/flex/pages/copyright.html,
and its usage is subject to the terms of the licensing agreement 
available at http://www.flexcms.com/flex/pages/license.html
*/



	// ========================================================================================
	
	$PageTitle = '<img src="'.$ImagesURL.'/admin/admincp_settings.gif" width="23" height="20"> '.$MsgText[0][674];
	$BrowserTitle = $MsgText[0][674];
	$LocationBar = '<a href="'.$IndexURL.'">'.$MsgText[0][1].'</a> > <a href="'.$MainURL.'/options.html">'.$MsgText[0][4].'</a> > <a href="'.$MainURL.'/admin/settings.html">'.$MsgText[0][64].'</a> > '.$MsgText[0][674];
	
	if ($LoggedIn == 'y') {
		
		ReadPermissions();
		Global $Permissions;
		
		if ($Permissions[8] == 'y') {
	
			ReadFormArguments();
			Global $FormArguments;
			
			if ($FormArguments['BaseURL'] == '') {
				$FormArguments['BaseURL'] = $Settings['BaseURL'];
			}
			
						
			// remove slash from the end of the url values
			if (substr($FormArguments['BaseURL'],strlen($FormArguments['BaseURL'])-1,1) == '/') {
				$FormArguments['BaseURL'] = substr($FormArguments['BaseURL'],0,strlen($FormArguments['BaseURL'])-1);
			}
			
			if (substr($FormArguments['BaseURL'],0,7) != 'http://' && substr($FormArguments['BaseURL'],0,8) != 'https://') {
				$FormArguments['BaseURL'] = 'http://'.$FormArguments['BaseURL'];
			}
			
			
			if (@include_once('./'.rc('696E632D6663622E706870',3))) {
				//
			}
			else {
				$NLK = '<br><input type="checkbox" name="NLK" value="y"> '.$MsgText[0][669];
			}
									
			
			$PageContents = '<script>
function AutoLK() {

	var WindowProperties = "width=420,height=300,left=" + (screen.width-420)/2 + ",top=" + (screen.height-300)/2 + ",location=no,menubar=no,directories=no,toolbar=no,status=no,scrollbars=no,resizable=yes";

	var WindowCode = window.open("'.$MainURL.'/admin/settings-baseurl3/'.str_replace('/','+++',$FormArguments['BaseURL']).'","AttemptAutoLK",WindowProperties);

}
</script>


<br><font color="#ff0000"><b>'.$MsgText[0][470].'</b></font><br><br>
<form name="PostForm" action="'.$MainURL.'/admin/settings-baseurl4" method="post">

<br><b>'.$MsgText[0][664].':</b><br>'.$Settings['BaseURL'].'<br><br>
<b>'.$MsgText[0][665].':</b><br>'.$FormArguments['BaseURL'].'<br><br><br>

<b>'.$MsgText[0][667].':</b><br>
<input type="text" name="NewLK" size="50" value=""> <input type="button" name="AttemptAutoLK" value="'.$MsgText[0][666].'" onClick="AutoLK();"><br>
<font size="1">'.$MsgText[0][668].'<br></font>

<input type="hidden" name="NewBaseURL" value="'.$FormArguments['BaseURL'].'">

'.$NLK.'

<br><br><br><input type="submit" value="'.$MsgText[0][564].'">


</form>';
			
			
			

		}
		else {
		
			$PageContents = $MsgText[0][97];
		
		}

	}
	else {
	
		RedirectToLogin();
	
	}

	// ========================================================================================




?>
