Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Połączenie ciągów z tablicy
winiar789
post
Post #1





Grupa: Zarejestrowani
Postów: 130
Pomógł: 0
Dołączył: 15.11.2011

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


Mam coś takiego:

Array
(
[0] => Array
(
[link] => http://domena1.pl/abc-p523
)

[1] => Array
(
[link] => http://domena2.pl/abc-p523/4197
)

[2] => Array
(
[link] => http://domena1.pl/abc-p2323
)

[3] => Array
(
[link] => http://domena2.pl/abc-p523/2323
)

[4] => Array
(
[link] => http://domena1.pl/abc-p44444
)

[5] => Array
(
[link] => http://domena2.pl/abc-p523/44444
)


)



a chciałbym uzyskać:


Array
(
[0] => Array
(
[link_1] => http://domena1.pl/abc-p523
[link_2] => http://domena2.pl/abc-p523/4197
)

[1] => Array
(
[link_1] => http://domena1.pl/abc-p2323
[link_2] => http://domena2.pl/abc-p523/2323
)

[2] => Array
(
[link_1] => http://domena1.pl/abc-p44444
[link_2] => http://domena2.pl/abc-p523/44444
)

)



Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 2)
viking
post
Post #2





Grupa: Zarejestrowani
Postów: 6 380
Pomógł: 1116
Dołączył: 30.08.2006

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


http://php.net/manual/en/function.array-chunk.php
Go to the top of the page
+Quote Post
winiar789
post
Post #3





Grupa: Zarejestrowani
Postów: 130
Pomógł: 0
Dołączył: 15.11.2011

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


Piątka dla Ciebie ! to się ceni ... Dzięki (IMG:style_emoticons/default/smile.gif)
Go to the top of the page
+Quote Post

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

 



RSS Aktualny czas: 23.08.2025 - 16:06