Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> z pliku do tablicy
Dan
post 14.06.2003, 22:12:16
Post #1





Grupa: Zarejestrowani
Postów: 16
Pomógł: 0
Dołączył: 16.06.2002

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


Jak zrobić aby dane z pliku o treści "Element0","Element1","Element2" umieścić w tablicy tak, że $Tablica[0]="Element0", $Tablica[1]="Element1", $Tablica[2]="Element2" ?
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 2)
DeyV
post 14.06.2003, 22:14:02
Post #2





Grupa: Zarząd
Postów: 2 277
Pomógł: 6
Dołączył: 27.12.2002
Skąd: Wołów/Wrocław




zapisać je każdy w nowej lini, a następnie skorzystać z file()


--------------------
"Niezależnie od tego, jakie masz osiągnięcia, ktoś Ci pomaga..."
Go to the top of the page
+Quote Post
Cudi
post 14.06.2003, 22:14:58
Post #3


Administrator planeta/IRC


Grupa: Przyjaciele php.pl
Postów: 385
Pomógł: 0
Dołączył: 19.04.2003
Skąd: Zabrze

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


Jeśli dobrze zrozumiałem masz tam dane które są rozdzielone jakimś znakiem... Jeśli tak to:
a) file();
cool.gif explode();
c) http://forum.php.pl/search.php
d) http://forum.php.pl/search.php
e) http://forum.php.pl/search.php

A jeśli źle zrozumiałem to napisz dokładniej, daj jakiś kod lub strukture pliku txt..


--------------------
"Programmers are in a race with the Universe to create bigger and better idiot-proof programs, while the Universe is trying to create bigger and better idiots. So far the Universe is winning."
Cudi's devBlog
Go to the top of the page
+Quote Post

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: 24.07.2025 - 16:34