[prev in list] [next in list] [prev in thread] [next in thread]
List: pecl-cvs
Subject: [PECL-CVS] cvs: pecl /uploadprogress/examples index.php
From: "Christian Stocker" <chregu () php ! net>
Date: 2009-05-26 14:48:11
Message-ID: cvschregu1243349291 () cvsserver
[Download RAW message or body]
chregu Tue May 26 14:48:11 2009 UTC
Modified files:
/pecl/uploadprogress/examples index.php
Log:
added a check in the example if
uploadprogress.file.filename_template
is writable
http://cvs.php.net/viewvc.cgi/pecl/uploadprogress/examples/index.php?r1=1.4&r2=1.5&diff_format=u
Index: pecl/uploadprogress/examples/index.php
diff -u pecl/uploadprogress/examples/index.php:1.4 \
pecl/uploadprogress/examples/index.php:1.5
--- pecl/uploadprogress/examples/index.php:1.4 Mon Mar 16 13:52:59 2009
+++ pecl/uploadprogress/examples/index.php Tue May 26 14:48:11 2009
@@ -148,16 +148,24 @@
('post_max_size' is <?php echo ini_get('post_max_size');?> per submit)
</form>
- <div id="status" style="border: 1px black solid;
- <?php if (function_exists("uploadprogress_get_info")) { ?>
- background-color: green;">The uploadprogress extension is installed.
-<?php } else { ?>
- background-color: red;">The uploadprogress extension is not installed.
-
-<?php } ?>
-
-
-</div>
+ <div id="status" style="border: 1px black solid;<?php
+ $template = ini_get("uploadprogress.file.filename_template");
+ if (@touch ($template)) {
+ print '">Good. '.$template.' is writable. The realpath is ' . \
realpath($template); + unlink($template);
+ } else {
+ print 'background-color: red;"';
+ print ">Problem. $template is NOT writable. <br/>Please make sure the \
directory exists and is writable for the webserver. <br/> + Or adjust the ini \
setting 'uploadprogress.file.filename_template' to a correct path."; + }
+
+ ?>
+
+
+ </div>
+
+
+
<div>The info during the upload will be displayed here:</div>
<iframe id="ifr" src="info.php?ID=<?php echo $id;?>" width="500px" height="350px" \
name="ifr"></iframe>
--
PECL CVS Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic