|
Posted by Jerry Stuckle on March 31, 2009, 8:15 pm
Please log in for more thread options
Luk wrote:
show/hide quoted text
> On 30 Mar, 21:56, Iván Sánchez Ortega <ivansanchez-...@rroba-
> escomposlinux.-.punto.-.org> wrote:
>> Luk wrote:
>>> I used trim. But without results. Other hints?
>> $userfile holds the *contents* and not the *name* of the file, right?
>> Right??
>> You are writing the trimmed stuff back to the file, right?
>
> Yes, should be. This is the code used:
>
> if (move_uploaded_file($_FILES['uploaded_file']['tmp_name'],
> $userfile)) {
> echo 'OK';
> }
>
> then after the checks about the spaces and other chars, there's the
> foreach cicle that works:
>
> $lines = file($userfile);
> foreach ($lines as $line_num => $line) {
> //stuff
> }
>
> Luk
What is in the //stuff?
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
|
> escomposlinux.-.punto.-.org> wrote:
>> Luk wrote:
>>> I used trim. But without results. Other hints?
>> $userfile holds the *contents* and not the *name* of the file, right?
>> Right??
>> You are writing the trimmed stuff back to the file, right?
>
> Yes, should be. This is the code used:
>
> if (move_uploaded_file($_FILES['uploaded_file']['tmp_name'],
> $userfile)) {
> echo 'OK';
> }
>
> then after the checks about the spaces and other chars, there's the
> foreach cicle that works:
>
> $lines = file($userfile);
> foreach ($lines as $line_num => $line) {
> //stuff
> }
>
> Luk