Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [PHP] Problem z tablicą zwracaną przez webapi
xandersky
post
Post #1





Grupa: Zarejestrowani
Postów: 14
Pomógł: 0
Dołączył: 12.11.2011

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


Witam..

Robię sobie mały panel sprzedanych rzeczy na allegro.

Wszystko pieknie fajnie aczkolwiek utknąłem na tablicy do której nie mogę się dostać..

Print_r ciągle zwraca mi pusty wynik i po dwóch dniach musiałem się poddać i poprosić Was o wskazówki.

Chodzi o tablicę:

  1. (
  2. [item-list-info-ext] => stdClass Object
  3. (
  4. [it-id] =>
  5. [it-country] =>
  6. [it-name] =>
  7. [it-price] =>
  8. [it-bid-count] =>
  9. [it-ending-time] =>
  10. [it-seller-id] =>
  11. [it-seller-login] =>
  12. [it-seller-rating] =>
  13. [it-starting-time] =>
  14. [it-starting-price] => 0
  15. [it-quantity] => 0
  16. [it-foto-count] => 6
  17. [it-reserve-price] => 0
  18. [it-location] =>
  19. [it-buy-now-price] => 1299
  20. [it-buy-now-active] => 0
  21. [it-high-bidder] => 0
  22. [it-high-bidder-login] => H...2
  23. [it-description] => NULL
  24. [it-options] =>
  25. [it-state] => 7
  26. [it-wire-transfer] =>
  27. [it-post-delivery] => -1
  28. [it-post-info] =>
  29. [it-quantity-type] => 0
  30. [it-is-eco] => 0
  31. [it-hit-count] => 230
  32. [it-postcode] =>
  33. [it-vat-invoice] => 1
  34. [it-bank-account1] =>
  35. [it-bank-account2] =>
  36. [it-is-for-guests] => 0
  37. [it-has-product] => 0
  38. [it-order-fulfillment-time] => 48
  39. [it-ending-info] => 2
  40. [it-is-allegro-standard] => 1
  41. [it-is-new-used] => 1
  42. )
  43. [item-cat-path] => Array
  44. (
  45. [0] => stdClass Object
  46. (
  47. [cat-level] => 0
  48. [cat-id] => 4
  49. [cat-name] => Telefony i Akcesoria
  50. )
  51. [1] => stdClass Object
  52. (
  53. [cat-level] => 1
  54. [cat-id] => 165
  55. [cat-name] => Telefony komórkowe
  56. )
  57. [2] => stdClass Object
  58. (
  59. [cat-level] => 2
  60. [cat-id] => 16618
  61. [cat-name] => HTC
  62. )
  63. [3] => stdClass Object
  64. (
  65. [cat-level] => 3
  66. [cat-id] => 111612
  67. [cat-name] => HTC One S
  68. )
  69. )
  70. [item-img-list] => Array
  71. (
  72. [0] => stdClass Object
  73. (
  74. [image-type] => 1
  75. [image-url] => <a href="http://img01.allegroimg.pl/photos/128x96/27/95/79/20/" target="_blank">http://img01.allegroimg.pl/photos/128x96/27/95/79/20/</a>
  76. )
  77. [1] => stdClass Object
  78. (
  79. [image-type] => 1
  80. [image-url] => <a href="http://img01.allegroimg.pl/photos/128x96/27/95/79/20/2" target="_blank">http://img01.allegroimg.pl/photos/128x96/27/95/79/20/2</a>
  81. )
  82. [2] => stdClass Object
  83. (
  84. [image-type] => 1
  85. [image-url] => <a href="http://img01.allegroimg.pl/photos/128x96/27/95/79/20/" target="_blank">http://img01.allegroimg.pl/photos/128x96/27/95/79/20/</a>
  86. )
  87. [3] => stdClass Object
  88. (
  89. [image-type] => 1
  90. [image-url] => <a href="http://img01.allegroimg.pl/photos/128x96/27/95/79/20/" target="_blank">http://img01.allegroimg.pl/photos/128x96/27/95/79/20/</a>
  91. )
  92. [4] => stdClass Object
  93. (
  94. [image-type] => 1
  95. [image-url] => <a href="http://img01.allegroimg.pl/photos/128x96/27/95/79/20" target="_blank">http://img01.allegroimg.pl/photos/128x96/27/95/79/20</a>
  96. )
  97. [5] => stdClass Object
  98. (
  99. [image-type] => 1
  100. [image-url] => <a href="http://img01.allegroimg.pl/photos/128x96/27/95/79/2" target="_blank">http://img01.allegroimg.pl/photos/128x96/27/95/79/2</a>
  101. )
  102. [6] => stdClass Object
  103. (
  104. [image-type] => 2
  105. [image-url] => <a href="http://img01.allegroimg.pl/photos/400x300/27/95/79/" target="_blank">http://img01.allegroimg.pl/photos/400x300/27/95/79/</a>
  106. )
  107. [7] => stdClass Object
  108. (
  109. [image-type] => 2
  110. [image-url] => <a href="http://img01.allegroimg.pl/photos/400x300/27/95/79/" target="_blank">http://img01.allegroimg.pl/photos/400x300/27/95/79/</a>
  111. )
  112. )
  113. )


o ile do

  1. item-list-info-ext -> [it-name]


dostałem się bez problemu za pomocą

  1. $nazwa = $client->doShowItemInfoExt($session['session-handle-part'], $numer_aukcji);
  2. $nazwa = get_object_vars($nazwa['item-list-info-ext']);
  3. $nazwa_aukcji = $nazwa['it-name'];


o tyle do item-img-list czyli do url obrazka nie mogę się dostać sad.gif

Generalnie chciałbym wyciągnąć tylko jeden obrazek dokładnie -> [item-img-list] => [0] => [image-url] => http://img01.allegroimg.pl/photos/128x96/27/95/79/20/

Nie mam już pomysłów.. Prosiłbym o jakąś pomoc ewentualnie wskazówki..

Pozdrawiam
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 - 18:04