473,807 Members | 2,763 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

accessing graphic file in another directory

Hello,

An html authoring question:

What is the correct syntax to write into
a root directory "index file" (mainpage file)
so it will point to a graphic file located in another directory?
Right now, my graphic files are all in the root directory,
and I want to store them in another directory, therefore,
I will have to edit my index file if I move the graphic files.

Would this work:

<img src="/root/other_directory/img.jpg">

this:

<img src=".../other_directory/img.jpg">

or this:

<img src="/other_directory/img.jpg">

?

Thanks in advance,
Sandman


Jul 20 '05 #1
3 5843
Sandman wrote:
Hello,

An html authoring question:

What is the correct syntax to write into
a root directory "index file" (mainpage file)
so it will point to a graphic file located in another directory?
Right now, my graphic files are all in the root directory,
and I want to store them in another directory, therefore,
I will have to edit my index file if I move the graphic files.


You can write a relative link like this: "../bla/"
Which means go one up and look for "bla" folder.
Or "/bla/" which means go to the root and look for the "bla" folder. Or
you can write "bla/" which means go to the "bla" folder which is on the
same level as the HTML file containing the link.

--
Google Blogoscoped
http://blog.outer-court.com
Jul 20 '05 #2
"Philipp Lenssen" <in**@outer-court.com> wrote in message
news:bl******** ****@ID-203055.news.uni-berlin.de...
Sandman wrote:
Hello,

An html authoring question:

What is the correct syntax to write into
a root directory "index file" (mainpage file)
so it will point to a graphic file located in another directory?
Right now, my graphic files are all in the root directory,
and I want to store them in another directory, therefore,
I will have to edit my index file if I move the graphic files.


You can write a relative link like this: "../bla/"
Which means go one up and look for "bla" folder.
Or "/bla/" which means go to the root and look for the "bla" folder. Or
you can write "bla/" which means go to the "bla" folder which is on the
same level as the HTML file containing the link.

--
Google Blogoscoped
http://blog.outer-court.com


Thank you. that should sphix it..

-- sandman
Roy Santonil
Classic Headcovers
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
http://www.classicheadcovers.com
Jul 20 '05 #3
Sandman wrote:
What is the correct syntax to write into
a root directory "index file" (mainpage file)
so it will point to a graphic file located in another directory?


Some forms of relative and absolute URLs are described on this page:
http://webtips.dan.info/url.html

--
== Dan ==
Dan's Mail Format Site: http://mailformat.dan.info/
Dan's Web Tips: http://webtips.dan.info/
Dan's Domain Site: http://domains.dan.info/

Jul 20 '05 #4

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

Similar topics

1
2142
by: Brad Pears | last post by:
Our graphic designer is developing our new company website. We have switched providers and currently she is working on the new website which currently ressides on the new providers server as they support the ASP development environment. Their server is a Win2K3 server. She is writing an ASP module to connect to an MS Access 2000 database and is having problems connecting. In this database there is only one table. She has tried many...
3
12412
by: Peter | last post by:
Hello, Two newbie questions: 1) I have a javascript file with a function in it. From this function I want to access a variable in another javascript file -which is not inside a function. I have tried many combinations to do this, but has yet to try the right one. How is it done? 2) What kinds of file operations can be done in Javascript (save,
9
1923
by: Swami | last post by:
I was wondering how I can programmatically find out the path of an installed program. I have an application that needs access to a config file that resides in the folder of another application. I'm guessing that this can be done by accessing the registry, but some articles or sample code would be useful. Thanks.
3
1682
by: Doug | last post by:
I have a split Access database that resides on a file server. The file server is a restricted drive that only people with the correct permissions can browse to this directory on the LAN. Several users use the Access front end to modify the database on the file server, but I would like to make some of the data available (read-only) through webpages with asp. It is not an option to move the database directly to the webserver because these...
4
1613
by: reezaali | last post by:
Hi All, I wanted to set up my websites like this c:\websites\intranettemplate c:\websites\app1 c:\websites\app2 Basically I wanted to have the master pages defined in the template folder and all other apps would "reference" this folder to get the
5
2267
by: samadams_2006 | last post by:
I'm having a problem in accessing a Microsoft Access Database in a VB.NET Web Application. It's so straight forward, I thought I'd walk you through all the details here: 1) I have a .NET Web Application called "Lesson18b" under "C:\Inetpub\wwwroot\Lesson18b". 2) I have one Web Form on this Lesson called "Form18b.aspx" 3) In this same Folder under Inetpub I have the Microsoft NorthWinds
2
2158
by: le0 | last post by:
guys, this is my first time to deploy website to the server, but every time i access the page this error always appears. --------------------------------------------------------------------------------------------- Server Error in '/sample' Application. -------------------------------------------------------------------------------- The Microsoft Jet database engine cannot open the file
1
1456
by: Jerim79 | last post by:
Probably an incredibly simple answer, but I can't seem to phrase it so a search engine can understand it. I have a php script with a simple include: include("/include_this.php") I need to edit this so it accesses the file from another server. I have tried: include("http://192.168.1.1/include_this.php:)
1
1529
by: deece | last post by:
HI There! I hope someone can help me with this as I have been searching for about 2 weeks now for an answer and I have to admit that I am a designer and not much of a coder so all help would be greatly appreciated!! I have a website for a client www.respectmusic.com.au/welcome.html. At the moment it is divided into two frames and the top frame has a wimpy.swf music player. The reason for this is that my client wants the player to always be...
0
9719
marktang
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...
0
10371
jinu1996
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...
1
10374
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10111
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9193
agi2029
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...
1
7650
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 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...
0
5546
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5684
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3853
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.