Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Location of files in IIS . Where pic folders should go

Posted on 2013-11-06
5
Medium Priority
?
228 Views
Last Modified: 2013-11-20
I have IIS 7.5 and when I go to InetMgr, I right click on the default website and then choose Explore,I see:

C:\inetpub\wwwroot

So far so good and as expected.

Now I created a C# web application and created a virtual directory under the default website I right click and explore I see :

C:\CSharpTest\WebApplication8\WebApplication8

This is also can be expected. However When I Run the Application picture are not loaded since WebApplication8 folder is not created in C:\inetpub\wwwroot.

I know .NET 2.0 VS 2005 does creates the folder in inetpub\wwwroot. So under Vs 2010 Do I need to copy files manually to the Inetpub/wwwroot?
0
Comment
Question by:unknown_routine
  • 3
5 Comments
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 39628091
What is the URL that you are using for pictures? Using relative paths for pictures makes it easy to show pictures from any location from within the website folder.
0
 
LVL 15

Author Comment

by:unknown_routine
ID: 39628130
I found more interesting Info:

When page loads I see empty picture place holder. If I right click on it and then choose properties I see:

http://localhost/WebApplication8/pics/a.jpg

Then If I put this directly into the IE: http://localhost/WebApplication8/pics/a.jpg

I get an empty page!
0
 

Expert Comment

by:jonjojr
ID: 39628219
Just for kicks,  try to put this into the browser and let me know what you get.

http://localhost/WebApplication8/WebApplication8/pics/a.jpg

This is based on your recent post that says you have a virtual directory in this location:

C:\CSharpTest\WebApplication8\WebApplication8

Now usually this is the name of the the application "CSharpTest" along with the actual directory that it is under "WebApplication8"  but you seem to have an additional folder called "WebApplication8"
0
 
LVL 15

Accepted Solution

by:
unknown_routine earned 0 total points
ID: 39651635
I had to enable static contents to be able to see the pictures!
0
 
LVL 15

Author Closing Comment

by:unknown_routine
ID: 39662038
Found the answer!
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…

916 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