473,397 Members | 2,116 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

.NET 2.0: <img...> not displayed

Hello,
(sorry for my English...)
Could you help me please with one asp.net problem? I am beginner...

I am writting simple Demo .NET application. On start page I have:

<h1>Demo .NET</h1>
<br />
<p style="vertical-align: middle;">
<img src="App_Data/DotNet_360x280.jpeg" alt="Microsoft .NET
version 2.0" width="360" height="280"
onclick="location.href='Login.aspx'"/>
<br />
...
</p>

I don't understand why when I run the application image
DotNet_360x280.jpeg is not shown (frame only).
When I have written URL of the picture
(.../App_Data/DotNet_360x280.jpeg) in the browser I receive HTTP error
403 - Forbidden.
JPEG file exists in App_Data folder.
How to solve the problem? The HTML text is displayed correctly.

Thank you very much for your answers.
/RAM
Mar 15 '06 #1
2 1675
APP_Data folder is sacred folder which framework does not allow direct
access to. You need to move the image to some other place.

--
Netomatix
http://www.netomatix.com
"R.A.M." <r_********@poczta.onet.pl> wrote in message
news:en********************************@4ax.com...
Hello,
(sorry for my English...)
Could you help me please with one asp.net problem? I am beginner...

I am writting simple Demo .NET application. On start page I have:

<h1>Demo .NET</h1>
<br />
<p style="vertical-align: middle;">
<img src="App_Data/DotNet_360x280.jpeg" alt="Microsoft .NET
version 2.0" width="360" height="280"
onclick="location.href='Login.aspx'"/>
<br />
...
</p>

I don't understand why when I run the application image
DotNet_360x280.jpeg is not shown (frame only).
When I have written URL of the picture
(.../App_Data/DotNet_360x280.jpeg) in the browser I receive HTTP error
403 - Forbidden.
JPEG file exists in App_Data folder.
How to solve the problem? The HTML text is displayed correctly.

Thank you very much for your answers.
/RAM

Mar 15 '06 #2
why do you have an image in the app_data folder? I don't know if you
can browse to the app_data folder. if you have the image as an
embedded resource, you will load the image from the assembly using the
full name of the resource. Here's a link on how to use embedded
resources in asp.net

http://weblogs.asp.net/asmith/articles/25465.aspx

HTH,
Darren Kopp
http://blog.secudocs.com/

Mar 15 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

14
by: Gregory | last post by:
Hello, I'm trying to do the above in order to process an image and return the result to an html image control. It fails and my key suspects are either the variable that I'm passing in -...
15
by: Philipp Lenssen | last post by:
My friend has the following problem (background: we want to transform XML to XHTML via XSLT): "We copy XHTML fragments into an output by using the following template: <xsl:template match="*"...
5
by: MyndPhlyp | last post by:
I've been busting my head trying to figure this out for quite some time. With IE6 and NS7, no problems. I can simply code the HTML <img height="100%"> and be done with it. But NS4 and NS6 (and...
8
by: KS | last post by:
Just to show some code to show the consept. <img id="date" onclick="javascript:show_calendar();" src="/PlexSysWeb/images/show-calendar.gif" width=20 height=18 border=0> What i want the...
15
by: Gérard Talbot | last post by:
Hello all, I'd like to know and understand the difference between, say, <img src="/ImageFilename.png" width="123" height="456" alt=""> and <img src="/ImageFilename.png" style="width:...
3
by: Henry Johnson | last post by:
Okay - I'm spinning my wheels on this one... can someone help me figure out how to programmatically populate a table cell as follows (from C# code-behind)? I've tried using a Literal control in the...
2
by: McKirahan | last post by:
If I have a Web page invoked via http://myDomain.com/What.htm that references an ASP page via the <img> tag's "src=" like this: <html> <head> <title>Page.htm</title> </head> <body> <img...
1
by: Carl | last post by:
Hi all I have a javascript function that drags and drops an element (ie img) into a container (ie bordered div). The function works and returns the element and and container. My next step is to...
3
by: ajay2552 | last post by:
Hi, I have a query. All html tags start with < and end with >. Suppose i want to display either '<' or '>' or say some text like '<Company>' in html how do i do it? One method is to use &lt,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.