Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [uploadprogress] uploadprogress_get_info()
ja_fryta
post
Post #1





Grupa: Zarejestrowani
Postów: 5
Pomógł: 0
Dołączył: 25.07.2008

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


formularz

<form action="demo2.php" method="POST" id="uploadform" enctype="multipart/form-data" onsubmit="start_progres_bar()">
<input type="file" name="abc" maxlength="10" accept="gif|jpg"/>
<input name="UPLOAD_IDENTIFIER" id="uploadIdentifier" type="hidden" value="<?php echo $uuid ?>" />
<input type="submit" value="wyslij"/>
</form>

skrypt php

<?php
header("Cache-Control: no-cache, must-revalidate");
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");

echo json_encode(uploadprogress_get_info($_GET['id']));
?>

chcialem zrobic pasek postepu ladowania jednak funkcja uploadprogress_get_info() zawsze zwraca mi null (IMG:http://forum.php.pl/style_emoticons/default/questionmark.gif)
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
paziek
post
Post #2





Grupa: Zarejestrowani
Postów: 207
Pomógł: 25
Dołączył: 16.11.2006

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


uploadprogress_get_info($id), where $id is the UPLOAD_IDENTIFIER value. This will return false if there is no progress information, or an array of values about that upload.

Czyli nie
  1. <?php
  2. uploadprogress_get_info($_GET['id'])
  3. ?>
tylko
  1. <?php
  2. uploadprogress_get_info($_POST[$uuid])
  3. ?>
zakładając, że $uuid jest dostępne w demo2.php i jest stałe.
Go to the top of the page
+Quote Post

Posty w temacie


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: 11.10.2025 - 23:59