Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> problem z pobraniem danych z BD z wordpress
eremen
post 13.03.2016, 15:37:10
Post #1





Grupa: Zarejestrowani
Postów: 69
Pomógł: 0
Dołączył: 15.02.2012
Skąd: Głogów - Opole

Ostrzeżenie: (0%)
-----


edit:(caly plugin)
function Wypisz(){
$db = new mysqli('localhost', 'root', '', 'trening');
$db->autocommit(TRUE);
$sql = 'select Imie from trening where Imie like "Roman"';
$wynik = $db->query($sql);
return $wynik;
}

function WypiszZTekstem ($content) {
return $content.Wypisz();
}

add_filter('the_content', 'WypiszZTekstem');


to jest polaczenie ktorego uzywam w pluginie do wordpressa
wordpress wypluwa komunikat bledu: Catchable fatal error: Object of class mysqli_result could not be converted to string

Ten post edytował eremen 13.03.2016, 15:41:18
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 Wersja Lo-Fi Aktualny czas: 14.08.2025 - 05:38