Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [PHP][OOP][PDO] Błąd podczas zapytania
Dominator
post
Post #1





Grupa: Zarejestrowani
Postów: 565
Pomógł: 15
Dołączył: 11.10.2010

Ostrzeżenie: (20%)
X----


Nie wiem czemu to się pojawia, pomoże ktoś? Fatal error: Call to undefined method DB::prepare() in index.php on line 5

index.php
  1. <?php
  2.  
  3. include "DBConnection.php";
  4.  
  5. $stmt = $db->prepare("");
  6. $stmt->execute();


DBConnection.php
  1. <?php
  2.  
  3. require 'DB.class.php';
  4.  
  5. try
  6. {
  7. $db = new DB("","","","","");
  8. }
  9. catch(PDOException $e)
  10. {
  11. echo "Error! Code ->".$e->getMessage();
  12. }


Ten post edytował Dominator 29.05.2013, 19:05:55
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 20.08.2025 - 06:36