I have the following HTML in use on my web page. I need it to show a graphic
image on the page but do not know what to use in the codebehind to make the
graphic appear. If I load the source url in a browser by itself, the graphic
appears, but when I use the tag in a web page it does not. Anyone have a
suggestion for VB?
<img
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413'
border=0 alt> 11 2882
I'm under the impression that the src element of the <img tab needs to point
to either a .gif file or a .jpg file, not to the httpresponse of a aspx
page.
"tma" <tm*@allisconfu sing.net> wrote in message
news:eT******** ******@TK2MSFTN GP12.phx.gbl... I have the following HTML in use on my web page. I need it to show a
graphic image on the page but do not know what to use in the codebehind to make
the graphic appear. If I load the source url in a browser by itself, the
graphic appears, but when I use the tag in a web page it does not. Anyone have a suggestion for VB?
<img
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' border=0 alt>
Hi,
The img control loads a graphic, you are loading an ASPX page. To do what
you are doing create a user control and then use that in your page.
Creating a user control: http://msdn.microsoft.com/library/de...ercontrols.asp
Adding a user control: http://msdn.microsoft.com/library/de...bformspage.asp
Good luck! Ken.
--
Ken Dopierala Jr.
For great ASP.Net web hosting try: http://www.webhost4life.com/default.asp?refid=Spinlight
If you sign up under me and need help, email me.
"tma" <tm*@allisconfu sing.net> wrote in message
news:eT******** ******@TK2MSFTN GP12.phx.gbl... I have the following HTML in use on my web page. I need it to show a
graphic image on the page but do not know what to use in the codebehind to make
the graphic appear. If I load the source url in a browser by itself, the
graphic appears, but when I use the tag in a web page it does not. Anyone have a suggestion for VB?
<img
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' border=0 alt>
> I'm under the impression that the src element of the <img tab needs to
point to either a .gif file or a .jpg file, not to the httpresponse of a aspx page.
Well, you're under the wrong impression. An ASPX page can indeed serve an
image, and can indeed be used in an image tag.
--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living
"i. Wiin" <ii****@yagoo.c om> wrote in message
news:eZ******** ******@TK2MSFTN GP14.phx.gbl... I'm under the impression that the src element of the <img tab needs to
point to either a .gif file or a .jpg file, not to the httpresponse of a aspx page. "tma" <tm*@allisconfu sing.net> wrote in message news:eT******** ******@TK2MSFTN GP12.phx.gbl... I have the following HTML in use on my web page. I need it to show a graphic image on the page but do not know what to use in the codebehind to make the graphic appear. If I load the source url in a browser by itself, the graphic appears, but when I use the tag in a web page it does not. Anyone have a suggestion for VB?
<img
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' border=0 alt>
I check out the URL you posted: no image. Did you swap out the real URL for
a fake one? It's kind of hard to help in that case. Can you post the real
URL? The first thing I want to make sure of is that the page is really
returning an image. It may be returning HTML that contains an image tag,
wich would be wrong. Can't tell without the URL.
--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living
"tma" <tm*@allisconfu sing.net> wrote in message
news:eT******** ******@TK2MSFTN GP12.phx.gbl... I have the following HTML in use on my web page. I need it to show a
graphic image on the page but do not know what to use in the codebehind to make
the graphic appear. If I load the source url in a browser by itself, the
graphic appears, but when I use the tag in a web page it does not. Anyone have a suggestion for VB?
<img
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' border=0 alt>
tma wrote: I have the following HTML in use on my web page. I need it to show a graphic image on the page but do not know what to use in the codebehind to make the graphic appear. If I load the source url in a browser by itself, the graphic appears, but when I use the tag in a web page it does not. Anyone have a suggestion for VB?
<img src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' border=0 alt>
This method should work. It's not required to use the "correct" extension
as others suggested, as long as you set the correct contenttype
(image/gif, image/jpeg, ..). See Response.Conten tType.
Did something go wrong with the post? I noticed that you seemed to have
no space before "border" and no value for "alt".
Hans Kesting
Hi Kevin,
This is good to know. How do you return an image or maybe other type of
file from an ASPX page? The reason I'm asking is that Forms Authentication
seems to only protect ASPX pages and using this it could be used to force
people to log in who are trying to go directly to something other than an
ASPX page. Thanks! Ken.
"Kevin Spencer" <ks******@takem pis.com> wrote in message
news:O2******** ******@TK2MSFTN GP11.phx.gbl... I'm under the impression that the src element of the <img tab needs to point to either a .gif file or a .jpg file, not to the httpresponse of a aspx page.
Well, you're under the wrong impression. An ASPX page can indeed serve an image, and can indeed be used in an image tag.
-- HTH, Kevin Spencer .Net Developer Microsoft MVP I get paid good money to solve puzzles for a living
"i. Wiin" <ii****@yagoo.c om> wrote in message news:eZ******** ******@TK2MSFTN GP14.phx.gbl... I'm under the impression that the src element of the <img tab needs to point to either a .gif file or a .jpg file, not to the httpresponse of a aspx page. "tma" <tm*@allisconfu sing.net> wrote in message news:eT******** ******@TK2MSFTN GP12.phx.gbl... I have the following HTML in use on my web page. I need it to show a graphic image on the page but do not know what to use in the codebehind to
make the graphic appear. If I load the source url in a browser by itself, the graphic appears, but when I use the tag in a web page it does not. Anyone have
a suggestion for VB?
<img
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' border=0 alt>
Hi Ken, This is good to know. How do you return an image or maybe other type of file from an ASPX page?
An ASPX Page class is an HttpHandler. It handles HTTP requests. It can
therefore handle a request for an image. The page gets the image in one of a
large variety of ways (builds it, fetches it, etc), sets the
Response.Conten tType to "image/jpg" (or whatever MIME type you are working
with), and then saves the image to the Response.Output Stream. You can then
reference the page in an image tag. Example:
<img src="image.aspx ?modificationPa rameter=value">
Note that, since it is an ASPX page, you can pass additional data to it via
the QueryString, for modifying the image, or whatever you need.
The reason I'm asking is that Forms Authentication seems to only protect ASPX pages and using this it could be used to force people to log in who are trying to go directly to something other than an ASPX page.
Having a hard time figuring this one out, but if I understand you correctly,
yes, it could.
--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living
"Ken Dopierala Jr." <kd*********@wi .rr.com> wrote in message
news:eK******** ******@tk2msftn gp13.phx.gbl... Hi Kevin,
This is good to know. How do you return an image or maybe other type of file from an ASPX page? The reason I'm asking is that Forms
Authentication seems to only protect ASPX pages and using this it could be used to force people to log in who are trying to go directly to something other than an ASPX page. Thanks! Ken.
"Kevin Spencer" <ks******@takem pis.com> wrote in message news:O2******** ******@TK2MSFTN GP11.phx.gbl... I'm under the impression that the src element of the <img tab needs to point to either a .gif file or a .jpg file, not to the httpresponse of a
aspx page.
Well, you're under the wrong impression. An ASPX page can indeed serve
an image, and can indeed be used in an image tag.
-- HTH, Kevin Spencer .Net Developer Microsoft MVP I get paid good money to solve puzzles for a living
"i. Wiin" <ii****@yagoo.c om> wrote in message news:eZ******** ******@TK2MSFTN GP14.phx.gbl... I'm under the impression that the src element of the <img tab needs to point to either a .gif file or a .jpg file, not to the httpresponse of a
aspx page. "tma" <tm*@allisconfu sing.net> wrote in message news:eT******** ******@TK2MSFTN GP12.phx.gbl... > I have the following HTML in use on my web page. I need it to show a graphic > image on the page but do not know what to use in the codebehind to make the > graphic appear. If I load the source url in a browser by itself, the graphic > appears, but when I use the tag in a web page it does not. Anyone
have a > suggestion for VB? > > <img >
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' > border=0 alt> > > >
Ken Dopierala Jr. wrote: Hi Kevin,
This is good to know. How do you return an image or maybe other type of file from an ASPX page?
Technically, what you need to do is set the appropriate Content-Type header,
ideally Content-Length as well, and write your binary content to the
response's output stream.
In real world applications, I'd rather use a dedicated HttpHandler for
delivering images and such, because you hardly want all the Page processing
overhead for these specialized "content providers".
Cheers,
--
Joerg Jooss jo*********@gmx .net
Hi Kevin,
I did a search to see if people are already using this and they are...so
much for a novel idea, hey? Here is a link, it explains it better than I
did and now I don't have to re-invent the wheel. Thanks again! Ken. http://www.codeproject.com/aspnet/imagehandler.asp
"Kevin Spencer" <ks******@takem pis.com> wrote in message
news:OG******** *****@TK2MSFTNG P11.phx.gbl... Hi Ken,
This is good to know. How do you return an image or maybe other type of file from an ASPX page? An ASPX Page class is an HttpHandler. It handles HTTP requests. It can therefore handle a request for an image. The page gets the image in one of
a large variety of ways (builds it, fetches it, etc), sets the Response.Conten tType to "image/jpg" (or whatever MIME type you are working with), and then saves the image to the Response.Output Stream. You can then reference the page in an image tag. Example:
<img src="image.aspx ?modificationPa rameter=value">
Note that, since it is an ASPX page, you can pass additional data to it
via the QueryString, for modifying the image, or whatever you need.
The reason I'm asking is that Forms Authentication seems to only protect ASPX pages and using this it could be used to
force people to log in who are trying to go directly to something other than
an ASPX page. Having a hard time figuring this one out, but if I understand you
correctly, yes, it could.
-- HTH, Kevin Spencer .Net Developer Microsoft MVP I get paid good money to solve puzzles for a living
"Ken Dopierala Jr." <kd*********@wi .rr.com> wrote in message news:eK******** ******@tk2msftn gp13.phx.gbl... Hi Kevin,
This is good to know. How do you return an image or maybe other type of file from an ASPX page? The reason I'm asking is that Forms Authentication seems to only protect ASPX pages and using this it could be used to
force people to log in who are trying to go directly to something other than
an ASPX page. Thanks! Ken.
"Kevin Spencer" <ks******@takem pis.com> wrote in message news:O2******** ******@TK2MSFTN GP11.phx.gbl... > I'm under the impression that the src element of the <img tab needs
to point > to either a .gif file or a .jpg file, not to the httpresponse of a aspx > page.
Well, you're under the wrong impression. An ASPX page can indeed serve an image, and can indeed be used in an image tag.
-- HTH, Kevin Spencer .Net Developer Microsoft MVP I get paid good money to solve puzzles for a living
"i. Wiin" <ii****@yagoo.c om> wrote in message news:eZ******** ******@TK2MSFTN GP14.phx.gbl... > I'm under the impression that the src element of the <img tab needs
to point > to either a .gif file or a .jpg file, not to the httpresponse of a aspx > page. > > > > "tma" <tm*@allisconfu sing.net> wrote in message > news:eT******** ******@TK2MSFTN GP12.phx.gbl... > > I have the following HTML in use on my web page. I need it to show
a > graphic > > image on the page but do not know what to use in the codebehind to
make > the > > graphic appear. If I load the source url in a browser by itself,
the > graphic > > appears, but when I use the tag in a web page it does not. Anyone have a > > suggestion for VB? > > > > <img > > >
src='http://www.domain.com/MohawkWS/MohawkHitCounte r.aspx?ItemID=7 103830413' > > border=0 alt> > > > > > > > >
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Lukasz Indyk |
last post by:
i want to convert html to image (format of the image does not matter).
is it possible in python? or mayby it is possible to convert html first
to the postscript, and then postscript to image?
|
by: shay |
last post by:
if anyone have a good idea about how to creat an html to
image component
i tried :
A.
capture a web browser controll
prob
1. a win form app , we need to put the web controll inside
A dll file. and that a little messy ...
2.when u capture it will only get what u c ...
and not the whole page.
|
by: EMW |
last post by:
Hi,
I use the following to start my ASPX:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>index</title>
<meta name="vs_defaultClientScript" content="JavaScript">
<meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
|
by: Zhao Sheng |
last post by:
http://www.guangmingsoft.com/htmltoimage/help.htm
Html To Image
Html To Image 2.0 Released!
Html To Image help you convert html page from any URL to image or
thumbnails easily and quickly.
Directly save the webpage at a given URL into image in bmp, jpeg, tiff,
gif or png format.
Create thumbnail images from large images.
Batch conversion is supported.
|
by: PenguinPig |
last post by:
Dear All Experts
I would like to know how to convert a HTML into Image using C#. Or allow me
contains HTML code (parsed) in Image? I also tried this way but it just
display the character "<" & ">" directly....
I have done googling, but all return shareware. I would like to know how to
programming...but not using shareware...
Thanks all.
| |
by: Neil.Smith |
last post by:
I can't seem to find any references to this, but here goes:
In there anyway to parse an html/aspx file within an asp.net
application to gather a collection of controls in the file. For
instance what I'm trying to do is upload a html file onto the web
server, convert it to aspx file and then parse it for input
tags/controls, which in turn will become fields in a newly created
database table.
Clearly when the aspx file is called the...
|
by: pop |
last post by:
Microsoft says that
------------
ASP.NET version 2.0 on Windows Server 2003 protects all files in a
given directory, even those not mapped to ASP.NET, such
as .html, .gif, and .jpg files.
-------------
I have a ASP.NET 2.0 webapp on a 2003 server with the following
Web.Config file
|
by: ksrashmi |
last post by:
is it possible to covert html to image . with java code ? like using 2dGraphics or some other thing ?
|
by: amritpalpathak |
last post by:
I have made the html+javascript code.According to which when the page loaded the image size gets reduced to 50,50 and onclicking on it ,size increases to 500,500,but i done it with the one copy of image
But i want the click at thumnail of photos and display the full resolution of thumnail.
<html>
<body>
<body onload="changeIt();">
<head>
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |