/**
     * A statement class that implements DB_IStatement_1
     * NOTE: in most cases, you should be type-hinting for DB_IStatement_1
     * @author Andrew Minerd <andrew.minerd@sellingsource.com>
     */
    class DB_Statement_1 extends PDOStatement implements DB_IStatement_1
    {

    }

i am getting following error . 
Strict Standards: Declaration of DB_Statement_1::execute() should be compatible with PDOStatement::execute($bound_input_params = NULL) in /virtualhosts/libolution/DB/Statement.1.php on line 12

Strict Standards: Declaration of DB_Statement_1::fetch() should be compatible with PDOStatement::fetch($how = NULL, $orientation = NULL, $offset = NULL) in /virtualhosts/libolution/DB/Statement.1.php on line 12.

Line # 12 is mentioned above.
**

**

Hi,

change the DB_IStatement_1 signature for the execute() and fetch() methods and it should work fine. In practice you are implementing the PDOStatement interface into your class, so you must declare the same arguments:

public function execute($params = []);
public function fetch($how = NULL, $orientation = NULL, $offset = NULL);

Here's few examples with the same error and fixed:

More information:

Bye!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.