mirror of
				https://github.com/uklans/cache-domains
				synced 2025-11-04 13:28:51 +01:00 
			
		
		
		
	Beginning of arguments
This commit is contained in:
		
							parent
							
								
									97b6f97f04
								
							
						
					
					
						commit
						6534c8fc48
					
				@ -7,9 +7,26 @@ class cli_mode
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
	
 | 
						
 | 
				
			||||||
	function __construct()
 | 
						function __construct()
 | 
				
			||||||
 | 
						{
 | 
				
			||||||
 | 
							if (isset($_SERVER['argv'][1]) && isset($_SERVER['argv'][2]) && isset($_SERVER['argv'][3]) && isset($_SERVER['argv'][4])) 
 | 
				
			||||||
 | 
							{
 | 
				
			||||||
 | 
								$server = $_SERVER['argv'][1];
 | 
				
			||||||
 | 
								$dns_service = array('dns_service' => $_SERVER['argv'][2]);
 | 
				
			||||||
 | 
								$output_mode = array('filetype' => $_SERVER['argv'][3]);
 | 
				
			||||||
 | 
								$services = explode(" ", $_SERVER['argv'][4l]);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
								foreach ($services as $key => $service) 
 | 
				
			||||||
 | 
								{
 | 
				
			||||||
 | 
									$services[$key] = trim($service, " \t\n\r\0\x0B");
 | 
				
			||||||
 | 
								}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
								$this->make_conf($dns_service, $output_mode, $services, $server);
 | 
				
			||||||
 | 
							}
 | 
				
			||||||
 | 
							else
 | 
				
			||||||
		{
 | 
							{
 | 
				
			||||||
			$this->run();
 | 
								$this->run();
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	function run()
 | 
						function run()
 | 
				
			||||||
	{
 | 
						{
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user