Solved

Best practices in project design

Posted on 2008-10-07
7
213 Views
Last Modified: 2013-11-26
I have a project called CS that I am considering, for simplicity and maintenance purposes, rearranging all the images, .js files, includes etc. I am considering placing them all in the root directory under the project. Other pages with these items in folders underneath this project folder would then point to the root for images, includes etc.
Is this a good way of doing things or should I create image, include folders in these folders underneath the root? I can refer to the root folder by http://localhost/CS/images or by using "/images for example but when I publish the project, CS will be the URL and in my development environment, I can see the images so how do I set up my project to not display the CS and just have http://localhost/images be displayed in my development environment. This should then transfer once in production right? Thanks for any guidance.
0
Comment
Question by:wilcor14
  • 4
  • 3
7 Comments
 
LVL 18

Expert Comment

by:David Robitaille
ID: 22661218
should I create image, include folders in these folders underneath the root?
absolutely
instead of using "http://localhost/images" you could use "~/images" for server control...
also take a look at this
http://www.asp101.com/resources/paths.asp 
 
0
 

Author Comment

by:wilcor14
ID: 22662503
davrob60, thanks. That article was helpful. My project is set up a bit differently. Someone else set it up for me. The physcal location of the files are under C:\Source2005.Net\CS How would you suggest I proceed?
0
 
LVL 18

Expert Comment

by:David Robitaille
ID: 22662753
thats the magic of the ~ . You dont have to bother with the  "http://localhost/CS/" part, it will aways be Corrected according to the "root" of your virtual directory.
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 
LVL 18

Expert Comment

by:David Robitaille
ID: 22662774
0
 

Author Comment

by:wilcor14
ID: 22662890
Thanks again. It works great within the image tag but does it work within the Body tag for Background? I tried it but not having success with that one.
0
 
LVL 18

Accepted Solution

by:
David Robitaille earned 500 total points
ID: 22662925
0
 

Author Closing Comment

by:wilcor14
ID: 31503868
Thanks for the help. Some good info.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
VB.Net WebRequest Code from JSON curl 7 54
C#.net split string and then check appropriate checkboxlist 4 27
Easy filter aspnet 2 27
Visual Studio npm 1 12
ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

820 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