forked from friendica/friendica-addons
		
	Functions moved to Strings class
implement functions from Strings class
This commit is contained in:
		
					parent
					
						
							
								1746d0814d
							
						
					
				
			
			
				commit
				
					
						1ac32c622e
					
				
			
		
					 22 changed files with 80 additions and 58 deletions
				
			
		| 
						 | 
				
			
			@ -15,6 +15,7 @@ use Friendica\Core\Logger;
 | 
			
		|||
use Friendica\Core\Renderer;
 | 
			
		||||
use Friendica\Database\DBA;
 | 
			
		||||
use Friendica\Util\DateTimeFormat;
 | 
			
		||||
use Friendica\Util\Strings;
 | 
			
		||||
 | 
			
		||||
function public_server_install()
 | 
			
		||||
{
 | 
			
		||||
| 
						 | 
				
			
			@ -147,12 +148,12 @@ function public_server_login($a, $b)
 | 
			
		|||
function public_server_addon_admin_post(&$a)
 | 
			
		||||
{
 | 
			
		||||
	BaseModule::checkFormSecurityTokenRedirectOnError('/admin/addons/publicserver', 'publicserver');
 | 
			
		||||
	$expiredays = (x($_POST, 'expiredays') ? notags(trim($_POST['expiredays'])) : '');
 | 
			
		||||
	$expireposts = (x($_POST, 'expireposts') ? notags(trim($_POST['expireposts'])) : '');
 | 
			
		||||
	$nologin = (x($_POST, 'nologin') ? notags(trim($_POST['nologin'])) : '');
 | 
			
		||||
	$flagusers = (x($_POST, 'flagusers') ? notags(trim($_POST['flagusers'])) : '');
 | 
			
		||||
	$flagposts = (x($_POST, 'flagposts') ? notags(trim($_POST['flagposts'])) : '');
 | 
			
		||||
	$flagpostsexpire = (x($_POST, 'flagpostsexpire') ? notags(trim($_POST['flagpostsexpire'])) : '');
 | 
			
		||||
	$expiredays = (x($_POST, 'expiredays') ? Strings::removeTags(trim($_POST['expiredays'])) : '');
 | 
			
		||||
	$expireposts = (x($_POST, 'expireposts') ? Strings::removeTags(trim($_POST['expireposts'])) : '');
 | 
			
		||||
	$nologin = (x($_POST, 'nologin') ? Strings::removeTags(trim($_POST['nologin'])) : '');
 | 
			
		||||
	$flagusers = (x($_POST, 'flagusers') ? Strings::removeTags(trim($_POST['flagusers'])) : '');
 | 
			
		||||
	$flagposts = (x($_POST, 'flagposts') ? Strings::removeTags(trim($_POST['flagposts'])) : '');
 | 
			
		||||
	$flagpostsexpire = (x($_POST, 'flagpostsexpire') ? Strings::removeTags(trim($_POST['flagpostsexpire'])) : '');
 | 
			
		||||
	Config::set('public_server', 'expiredays', $expiredays);
 | 
			
		||||
	Config::set('public_server', 'expireposts', $expireposts);
 | 
			
		||||
	Config::set('public_server', 'nologin', $nologin);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue