Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> json_encode($tablica) XmlHttpRequest w firebug zwraca mi zwykły html
uczeń php
post 2.01.2013, 13:28:41
Post #1





Grupa: Zarejestrowani
Postów: 159
Pomógł: 0
Dołączył: 8.01.2010

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


Za pomocą skryptu php generuję taką oto tablicę:
Array
(
[0] => Array
(
[slotId] => 5
[ruleId] => 42
[slogan] => Ta oferta
[refererType] => 0
[items] => Array
(
[0] => Array
(
[itemId] => 456677
[photoLink] => http://localhost/zdjecia/456677
)

[1] => Array
(
[itemId] => eegfr453
[photoLink] => http://localhost/zdjecia/eegfr453
)

[2] => Array
(
[itemId] => 168064
[photoLink] => http://localhost/zdjecia/05102008591
)

[3] => Array
(
[itemId] => 22092008536
[photoLink] => http://localhost/zdjecia/22092008536
)

[4] => Array
(
[itemId] => 18092008512
[photoLink] => http://localhost/zdjecia/18092008512
)

[5] => Array
(
[itemId] => 168064
[photoLink] => http://localhost/zdjecia/05102008590
)

[6] => Array
(
[itemId] => 22092008535
[photoLink] => http://localhost/zdjecia/22092008535
)

[7] => Array
(
[itemId] => 168064
[photoLink] => http://localhost/zdjecia/05102008589
)

[8] => Array
(
[itemId] => 777
[photoLink] => http://localhost/zdjecia/777
)

[9] => Array
(
[itemId] => 22092008538
[photoLink] => http://localhost/zdjecia/22092008538
)

)

)

)

następnie chciałbym to przekonwertować do json za pomocą funkcji json_encode($tablica), ale XmlHttpRequest w firebug zwraca mi zwykły html.
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: 19.07.2025 - 08:54