dns_zone_get_id PHP Code error
loading.......
File: /usr/local/ispconfig/interface/lib/classes/remoting.inc.php
a-z0-9+$/i', $origin)) { 2141 $this->server->fault('no_domain_found', 'Invalid domain name.'); 2142 return false; 2143 } 2144 2145 $rec = $app->db->queryOneRecord("SELECT id FROM dns_soa WHERE origin like '".$origin.'%');
2140 if (preg_match('/^[a-z0-9][a-z0-9-]+The code is returning FALSE all the time.
The code should be:
a-z0-9+$/i', $origin)) { 2141 $this->server->fault('no_domain_found', 'Invalid domain name.'); 2142 return false; 2143 } 2144 M-2145 $rec = $app->db->queryOneRecord("SELECT id FROM dns_soa WHERE origin like '".$origin."%'");
M-2140 if (!preg_match('/^[a-z0-9][a-z0-9-]+M=Modified
- The preg_match code is returning FALSE when the origin is correct and CORRECT when is incorrect
- The queryoneRecord is fetching always FALSE because the SQL code syntax is Invalid, there is missing -> ' <-
Thanks
connection closed.