<aspseek_errnoaspseek_fetch_cached_page>
 Last updated: Fri, 09 May 2003

aspseek_error

(PHP 4 >= 4.1.0)

aspseek_error --  Returns the text of the error message from previous ASPseek operation

Description

string aspseek_error ( [resource link_identifier])

Returns the error text from the last ASPseek function, or '' (the empty string) if no error occurred.

Note that this function only returns the error text from the most recently executed ASPseek function (not including aspseek_error() and aspseek_errno()), so if you want to use it, make sure you check the value before calling another ASPseek function.

Example 1. aspseek_error Example

<?php
    aspseek_connect("nonexistenthost");
    echo aspseek_errno() . ": " . aspseek_error(). "\n";

    aspseek_connect("localhost");
    aspseek_query("unmatchedquote\"");
    echo aspseek_errno() . ": " . aspseek_error() . "\n";
?>

The above example would produce the following output:

1001: Unknown server host 'nonexistenthost'
1016: Unmatched string quote

Note

If the optional argument is specified the given link is used to retrieve the error message. If not, the last opened link is used.

See also: aspseek_errno()


<aspseek_errnoaspseek_fetch_cached_page>
 Last updated: Fri, 09 May 2003