By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,348 Members | 1,397 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,348 IT Pros & Developers. It's quick & easy.

show picture

P: n/a
hi,
i wrote a code that open a picture and store it in a string.
then its save the base_64 of this string in a jpeg file and then i can
show this picture.
but i want to show this picture without save it.
how can i do this??*
Sep 27 '08 #1
Share this Question
Share on Google+
5 Replies


P: n/a
hareldo schreef:
hi,
i wrote a code that open a picture and store it in a string.
then its save the base_64 of this string in a jpeg file and then i can
show this picture.
but i want to show this picture without save it.
how can i do this??
http://www.phpjabbers.com/ask15-disp...-a-script.html

(i whish to express my thanks to Google..)

--
Luuk
Sep 27 '08 #2

P: n/a
hareldo wrote:
hi,
i wrote a code that open a picture and store it in a string.
then its save the base_64 of this string in a jpeg file and then i can
show this picture.
but i want to show this picture without save it.
how can i do this??
First of all, a jpeg is not base_64 encoded. You may give the file a
..jpeg extension, but it is not a jpeg file.

You need to have an <img...statement in your HTML, and instead of
loading the image directly you need to call a PHP script. The script
will then create the image and display it, (with the correct content
type set in the header).

http://www.google.com/search?q=php+image&btnG=Search

Should get you started on some tutorials on how to use the gd functions.
See especially the third one down (from zend). A little verbose with
too few examples, imho, but quite detailed and accurate.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Sep 27 '08 #3

P: n/a
First of all, a jpeg is not base_64 encoded. *You may give the file a
.jpeg extension, but it is not a jpeg file.

You need to have an <img...statement in your HTML, and instead of
loading the image directly you need to call a PHP script. The script
will then create the image and display it, (with the correct content
type set in the header).

http://www.google.com/search?q=php+image&btnG=Search

Should get you started on some tutorials on how to use the gd functions.
* See especially the third one down (from zend). *A little verbose with
too few examples, imho, but quite detailed and accurate.
i think its base_64 because when i do base_64 and save it in a jpeg
file in the server,its save it successful and after this i can see it.
Sep 27 '08 #4

P: n/a
when i use the imageJpeg function,like this:

imageJpeg($im,"aa.jpg",100;
the im var is store the image,its save it successful with the name
aa.jpg in my server.but when i use when the second parameter is
null,it suppose to show it,but instead of its just write it and i dont
see any picture.*
Sep 27 '08 #5

P: n/a
hareldo wrote:
when i use the imageJpeg function,like this:

imageJpeg($im,"aa.jpg",100;
the im var is store the image,its save it successful with the name
aa.jpg in my server.but when i use when the second parameter is
null,it suppose to show it,but instead of its just write it and i dont
see any picture.
Please see the links I pointed you to.

You cannot just output an image in the middle of an html page, and the
links explain all how to do it.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Sep 27 '08 #6

This discussion thread is closed

Replies have been disabled for this discussion.