Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7434949
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T09:58:35+00:00 2026-05-29T09:58:35+00:00

I am using this example to display images, stored in my File-Stream Enabled database

  • 0

I am using this example to display images, stored in my File-Stream Enabled database in a blob format.

http://support.microsoft.com/kb/173308

This is working perfect, but I am very bad in classic asp and have problem when try to display this images mix with HTML elements.

From my test and tries, I have concluded that this is because the Response.ContentType.

In the example above, to display the image they are using a content type of the image. Perfect. I have this in my database, too. But when I read it from there and change it in the asp file, the whole HTML in the asp file is not displayed.

What should I do in order to display my images mixed with HTML tags. This is part of my poor asp code, which will display only one picture form the database and no other HTML.

SQL = "SELECT RecordID FROM InfoTable"

Set Recordset = Server.CreateObject("ADODB.Recordset")

Recordset.Open SQL,AdapterDataBaseActiveConnection

If Recordset.EOF Then

    Response.Write("No records returned.")

Else

    Do While NOT Recordset.Eof  

        Set CurrentNumber=Recordset("RecordID") 

        'Response.write CurrentNumber
        'Response.write "<br>" 
        Set rs = AdapterDataBaseActiveConnection.Execute("SELECT ContentType FROM InfoTable WHERE RecordID="&CurrentNumber)
        Set CurrentContentType=rs("ContentType")

        'Response.write CurrentContentType
        Response.Expires = 0
        Response.Buffer = TRUE
        Response.Clear
        Response.ContentType = CurrentContentType

        Set rsa = AdapterDataBaseActiveConnection.Execute("SELECT RecordBLOB FROM ImageTable  WHERE RecordID="&CurrentNumber)
        'Response.write "<div>"
        Response.BinaryWrite rsa("RecordBLOB")
        'Response.write "</div>" 

        Recordset.MoveNext 

    Loop

End If      

My final goal is to put the blob data into “” tags. Is this possible?Maybe I should use some type of conversion? I have thought about this, and given up. I have just try to display the images in “” tags but not succeeded too.

Please, give me some advice about how should I approach in this situation.

Thank you in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T09:58:37+00:00Added an answer on May 29, 2026 at 9:58 am

    Typically it works this way:

    This is the image in the page <img src="imageServer.asp?ID=1234">

    The server answers the ONE request, sets the MIME header and streams the image data for this particular image. You are not outputting HTML, the html is in the page already. You need to tell the img tag where to get its data.

    See: Display JPEG using Response.BinaryWrite

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i'm using this example implementation found at http://tangentsoft.net/wskfaq/examples/basics/select-server.html This is doing most of what
I'm using this plugin: http://www.jeremymartin.name/projects.php?project=kwicks And my code follows this example: http://www.jeremymartin.name/examples/kwicks.php?example=7 I'm using
I'm trying to digitally sign a PDF file using THIS project as an example.
Just using this as an example... Here are the columns in my UserProfile table:
I have looked at this example using php and GD to piecewise-render a spiral
Using this question as the base is there an alogrithm or coding example to
(I'm using the pyprocessing module in this example, but replacing processing with multiprocessing should
For example, your application is using this way for passing vars into your application
Please take a look at this example: #include <iostream> #include <vector> #include <string> using
I'm using this dialog: http://docs.jquery.com/UI/Dialog To open dialog I do it this way: $('a.openModal').live(click,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.