1

I am looking for a good approach on how to do the below

I have a file server where i store all of images.

I need to display these images onto my webpage using jquery and ajax.

Can someone please advise on how to do the above i can do the reading of the image from file server using a web service hosted on the file server which will return a byte array of the image, but once i read the byte array then how do i display it on the web page using jquery and ajax.

Please adivse

Thanks

1 Answer 1

1

Have a look at doing this with an HttpHandler. HttpHandler Example: http://www.wrox.com/WileyCDA/Section/id-291916.html

If your're using MVC have a look at: http://dotnet.dzone.com/news/goodbye-http-handler-hello?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+zones%2Fcss+(CSS+Zone)

Sign up to request clarification or add additional context in comments.

2 Comments

Mark, appreciate your reply but i already know how i can get teh image using ahandler but the thing which i could not figure out is how i can first make a ajax call using jquery to my handler and then once the response ia back how can i display it on the screen using jquery
Using jquery you can create/modify an <img> tag and set the src attribute to your HttpHandler/WebService/View URL.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.