mirror of
				https://github.com/ShaYmez/xlxd.git
				synced 2025-10-26 02:20:20 -04:00 
			
		
		
		
	Merge pull request #182 from yo3cat/master
XLX Alphanumeric names for reflector ...
This commit is contained in:
		
						commit
						bed3cf164b
					
				| @ -42,12 +42,19 @@ class xReflector { | ||||
|          $this->XMLContent = fread($handle, filesize($this->XMLFile)); | ||||
|          fclose($handle); | ||||
| 
 | ||||
|  # XLX alphanumeric naming...
 | ||||
|          $this->ServiceName = substr($this->XMLContent, strpos($this->XMLContent, "<XLX")+4, 3); | ||||
|          if (!is_numeric($this->ServiceName)) { | ||||
|          if (preg_match('/[^a-zA-Z0-9]/', $this->ServiceName) == 1) { | ||||
|             $this->ServiceName = null; | ||||
|             return false; | ||||
|          } | ||||
| 
 | ||||
| #         $this->ServiceName = substr($this->XMLContent, strpos($this->XMLContent, "<XLX")+4, 3);
 | ||||
| #         if (!is_numeric($this->ServiceName)) {
 | ||||
| #            $this->ServiceName = null;
 | ||||
| #            return false;
 | ||||
| #         }
 | ||||
|           | ||||
|          $this->ReflectorName = "XLX".$this->ServiceName; | ||||
|           | ||||
|          $LinkedPeersName = "XLX".$this->ServiceName."  linked peers"; | ||||
|  | ||||
| @ -42,12 +42,19 @@ class xReflector { | ||||
|          $this->XMLContent = fread($handle, filesize($this->XMLFile)); | ||||
|          fclose($handle); | ||||
| 
 | ||||
| # XLX alphanumeric naming...
 | ||||
|          $this->ServiceName = substr($this->XMLContent, strpos($this->XMLContent, "<XLX")+4, 3); | ||||
|          if (!is_numeric($this->ServiceName)) { | ||||
|          if (preg_match('/[^a-zA-Z0-9]/', $this->ServiceName) == 1) { | ||||
|             $this->ServiceName = null; | ||||
|             return false; | ||||
|          } | ||||
|           | ||||
| #         $this->ServiceName = substr($this->XMLContent, strpos($this->XMLContent, "<XLX")+4, 3);        
 | ||||
| #         if (!is_numeric($this->ServiceName)) {
 | ||||
| #            $this->ServiceName = null;
 | ||||
| #            return false;
 | ||||
| #         }  
 | ||||
| #         
 | ||||
|          $this->ReflectorName = "XLX".$this->ServiceName; | ||||
|           | ||||
|          $LinkedPeersName = "XLX".$this->ServiceName."  linked peers"; | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user