Solved

Urgent: Important:  Image as responseText or responseXML in Ajax response

Posted on 2009-04-08
2
521 Views
Last Modified: 2013-12-13
How to get image as responseText or responseXML in Ajax response?

I am using PHP to display image (using echo).

I need to get this image as a responseText or responseXML in the Ajax. How to display the image in the browser using Ajax?

Are there any approaches to have image payload in Ajax responseXML?

Ajax experts, please help me.
0
Comment
Question by:parumuga
2 Comments
 
LVL 10

Accepted Solution

by:
Phatzer earned 500 total points
Comment Utility
I think you'd need to open the contents of the file, base64 decode it and send that to javascript, but im not sure about base64 decoding on the javascript end. I think that could be a solution though.
0
 

Author Closing Comment

by:parumuga
Comment Utility
Solution was useful
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer …
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now