|
Hi,
i want to monitor how often some external images are loaded. So what my idea was instead of giving a uri directly like this:
www.site.com/image1.jpg
i create a php script which reads the image, so i build a php file and my html would look like this...
Started by Michel on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
Sending images through a scriptYou must set the content....
Like this, your script will need to :
send the right headers, which depend on the type of the image all images through php might put a bit of load on your server.
|
|
If I put this tag in my HTML:
<img src="http://server/imageHandler.php?image=someImage.jpg" />
instead of
<img src="http://server/images/someImage.jpg" />
and use the imageHandler.php script to read the image file, output expire headers and...
Started by Discodancer on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
Instead, you can set I think it does) copies the file directly from disk to the network interface, so it sends the image itself about as fast as....
Htaccess Caching
Yes, running any PHP script is slower than serving a static file.
|
|
This was working a few moments ago, not sure what changed. error log reads
[08-Aug-2009 02:09:20] PHP Warning: readfile(/images/32321249694312.JPG) [<a href='function.readfile'>function.readfile</a>]: failed to open stream: No such file or...
Started by Patrick on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Hence at some point where it's supposed ....
This is okay until you try to divide some number by null :
PHP Warning: Division stream: No such file or directory
The image couldn't be opened, for whatever reason.
Of the image is null .
|
Ask your Facebook Friends
|
Okay I'm really new to PHP I found the following script below. But i dont know how to use it I was wondering where do I put the link to the image for example images/photo.jpg inorder to get me started in learning this script thanks.
Here is the code.
...
Started by PeAk on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
I use the following script for this: function getRoot(){ $cwd('Content-type: image/jpeg'); imagejpeg($imageResized);
Or check http://www.php.net/manual/en/function.imagejpeg.php and the Example....
To the image so that it can be read.
|
|
I need to create an ImageIcon from an image on a remote server. When I loaded it with a URL like http://www.server.com/1.png it worked fine.
But recently the server was changed so that the images are stored outside of web root and must be accessed with...
Answer Snippets (Read the full thread at stackoverflow):
To play a bit....
You used id in URL, but the PHP script expects uid .
Also ensure that the request parameter name is correct.
One of the reasons that ImageIcon(URL) may fail 301/302) or so .
Type header to image/png on the response.
|
|
I have seen a lot of examples, but I am not sure how it can tie into the upload script i currently have. Could someone please explain how I might be able to use ImageMagick or something of the like to resize an uploaded image to a fixed width while keeping...
Started by Chris B. on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
ETA2:
I have seen a lot of suggestionsInstead of move_uploaded_file(), you'd load the file into the image processing library, resize() or imagecreatefrompng() (depending on what....
More discussion of PHP file upload script risks here .
|
|
Hello,
When sending a message on Facebook, if you include a URL it generally grabs a picture from the webpage and adds it at the bottom as a thumbnail. You then have the ability to select through a number of pictures featured on the site.
I can see how...
Started by Pete on
, 4 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Environment (5.3.1):
<?php /** * Sample CURL Image Extractor * * Prepared for stackoverflow.com('You need at least PHP 5.2 to use this script.'); } // // JSON & No-Cache Headers // Uncoment when I believe -- from there ....
|
|
Anything like this exist in the open source world? I can roll my own, but im looking to save time if possible.
Looking for something that will allow users to upload files and recieve a shortened URL to share. Possible have an api to allow other services...
Started by Patrick on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Solutions which are open source and GPL licensed:
script for imagepng.com Chevereto EDIT 2009-12-19.
|
|
I am trying to use the adylevy image upload script and have a problem passing a variable from it to the php upload script.
Started by Travelfrog on
, 3 posts
by 1 people.
Answer Snippets (Read the full thread at flashkit):
I am able to statically change the $target_path so that the uploadsCode: <?php $info....
Lt;script type="text/javascript"> var flashvars = {}; flashvars.path = "<?php echo $path;?>/html> PHP upload script.
|
|
I want to create several images with PHP on my webpage. Is there a way to do this without creating each image in its own PHP file and then placing the URLs to these files in img tags?
Started by Brian on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
<?php $im = imagecreatefrompng($_GET['img://yoursite.com/img-generator....
A neat approach is to have a specific image creation script you reference use the header() approach and output the image bytes.
There is no other way.
|