Support » Plugin: WordPress CRM Plugin - WP-CRM System » Debugging Error When Address is Omitted from Organization

  • Resolved chenryahts

    (@chenryahts)



    When I added a new Organization to the plugin without including an address, I get the following error code:

    Warning: file_get_contents(): php_network_getaddresses: getaddrinfo failed: No such host is known. in C:\xampp\htdocs\wordpress2\wp-content\plugins\wp-crm-system\includes\wcs-fields.php on line 371
    
    Warning: file_get_contents(http://maps.google.com/maps/api/geocode/json?address=+++++): failed to open stream: php_network_getaddresses: getaddrinfo failed: No such host is known. in C:\xampp\htdocs\wordpress2\wp-content\plugins\wp-crm-system\includes\wcs-fields.php on line 371

    This is a local installation, but it would seem that it’s trying to parse a field that it should know is empty.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Scott DeLuzio

    (@scottdeluzio)

    I can’t seem to reproduce that error on my localhost install.

    Could you open the file wp-crm-system\includes\wcs-fields.php in a text editor (Notepad, etc.) and replace the two lines around line 417-418 and 457-458 that look like this:

    // get latitude, longitude and formatted address
    $data_arr = geocode( $addressString );

    …with this:

    $data_arr = false;
    if ( $addressString ){
        // get latitude, longitude and formatted address
        $data_arr = geocode( $addressString );
    }

    If that corrects the error for you, please let me know and I’ll put out an update to address this.

    • This reply was modified 1 year, 11 months ago by  Scott DeLuzio.
    Plugin Author Scott DeLuzio

    (@scottdeluzio)

    The fix I suggested above was released in version 2.0.23 of the plugin.

    I’m marking this resolved, but if the issue persists, please open a new support thread.

    Cool, sorry, I haven’t had a chance to test it. But it seems like it’ll fix the problem

    Thanks

    Plugin Author Scott DeLuzio

    (@scottdeluzio)

    Great, if it doesn’t fix it, please let me know and I’ll dig into it a bit more.

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Debugging Error When Address is Omitted from Organization’ is closed to new replies.