|
Robert--
I have never used a base tag, but I still use relative links in
dynamically generated HTML. Works just fine.
Rgds
Kevin
Sent from my iPad
On 17 Jan 2013, at 22:57, "Dean, Robert" <rdean@xxxxxxxxxxxx> wrote:
The browser would only do that if you reset the document base using<base> tag. I should have thought of that earlier, because it's (IMO)
the
the more correct solution to the original problem. However, it's been
a while since I've written a cgi-bin script that produces HTML. ;-)
behalf of Kevin Turner [kevin.turner@xxxxxxxxxxxxxxx]
Example
<head>
<base href="http://my.domain.name/" /> </head>
________________________________________
From: web400-bounces@xxxxxxxxxxxx [web400-bounces@xxxxxxxxxxxx] on
Sent: Thursday, January 17, 2013 5:30 PMprogram (for example) are deemed to be in the document root. So HTML
To: Web Enabling the IBM i (AS/400 and iSeries)
Subject: Re: [WEB400] CSS file not being found
Vern
It depends on the directives, but normally HTML delivered from a CGI
delivered that way can reference static resources relative to the
document root (without a preceding '/').
apps. Not sure why, or what is better or worse really. I am sure
It works like that for me anyway :) I never use absolute paths in my
there are arguments to be had either way.
On Behalf Of Vernon Hamberg
Rgds
Kevin
-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx
[mailto:web400-bounces@xxxxxxxxxxxx]
Sent: 17 January 2013 22:26current folder is determined - I thought it was the folder where the
To: Web Enabling the IBM i (AS/400 and iSeries)
Subject: Re: [WEB400] CSS file not being found
Kevin
I've generally used absolute paths, so it'd help me to know how the
active HTML file is located.
not located anywhere. So what is the current folder then? Is it the
Now if that's true - it's fine for static pages. But dynamic pages
are
document root?
do remember reading about it once upon a time - along with other fairy
I was just looking up some of this but did not get an answer
quickly. I
tales, eh?
work. That just makes it an absolute path. It should would without
Vern
On 1/17/2013 4:20 PM, Kevin Turner wrote:
Steve
You should not have to put a '/' in front of the file name to make
it
'/' as long as the file you are looking for it relative to the current folder.
absolute:
For example:
/foo/bar/kevin.css
This translates to:
http://www.example.com/foo/bar/kevin.css
But without the slash, it becomes a relative reference rather than
for the directory "foo" and then drill down to "bar" for kevin.css.foo/bar/kevin.css
tells the server to look in the current folder (not the root
folder)
look in directory "foo" and then drill down to "bar" for kevin.css.../foo/bar/kevin.css
tells the server to go back one folder from the current folder,
then
referencing it properly, relative to the current folder (i.e. the
So if it doesn't work without a '/', it just means that you are not
folder in which the HTML file resides that is requesting it).
then it can be referenced like this:
In other words, if I have a directory structure like this:
myserver
-->htdocs
---->css
If my html file is in myserver/htdocs and my css file (called
steve.css) is in myserver/htdocs/css Then my html can reference the
css like this (without a '/' at the start) href="css/steve.css"
If steve.css is in the same place as the html (i.e in
myserver/htdocs)
kevin.turner@xxxxxxxxxxxxxxx> wrote:href="steve.css"
Clear as mud!
Kevin
-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx
[mailto:web400-bounces@xxxxxxxxxxxx]
On Behalf Of Steve Richter
Sent: 17 January 2013 21:54
To: Web Enabling the IBM i (AS/400 and iSeries)
Subject: Re: [WEB400] CSS file not being found
On Thu, Jan 17, 2013 at 4:47 PM, Kevin Turner <
front of the .css file name:That is what I said in my first reply Steve! :)I see that now.. Smacks head.
Now that it is working I see that it does not work without the / in
in a <directory> directive, but if the directory does not exist, it
<link rel="stylesheet" href="/steve.css" /> <!-- works -->
<link rel="stylesheet" href="steve.css" /> <!-- does not work -->
The <directory> directives are mainly for you to dictate
permissions to various locations in the document root. You can
refer to anything
just gets ignored.
http://archive.midrange.com/web400.got it.
--
This is the Web Enabling the IBM i (AS/400 and iSeries) (WEB400)
mailing list To post a message email: WEB400@xxxxxxxxxxxx To
subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at
intended by CoralTree Systems Ltd for the use of the named individuals
NOTICE: The information in this electronic mail transmission is
or entity to which it is directed and may contain information that is
privileged or otherwise confidential. If you have received this
electronic mail transmission in error, please delete it from your
system without copying or forwarding it, and notify the sender of the
error by reply email or by telephone, so that the sender's address records can be corrected.
list To post a message email: WEB400@xxxxxxxxxxxx To subscribe,
-------------------------------------------------------------------
---
----------
CoralTree Systems Limited
25 Barnes Wallis Road
Segensworth East, Fareham
PO15 5TT
Company Registration Number 5021022.
Registered Office:
12-14 Carlton Place
Southampton, UK
SO15 2EA
VAT Registration Number 834 1020 74.
--
This is the Web Enabling the IBM i (AS/400 and iSeries) (WEB400)
mailing
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400http://archive.midrange.com/web400.
or email: WEB400-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at
by CoralTree Systems Ltd for the use of the named individuals or
NOTICE: The information in this electronic mail transmission is
intended
entity to which it is directed and may contain information that is
privileged or otherwise confidential. If you have received this
electronic mail transmission in error, please delete it from your
system without copying or forwarding it, and notify the sender of the
error by reply email or by telephone, so that the sender's address records can be corrected.
----------------------------------------------------------------------
----------
list
CoralTree Systems Limited
25 Barnes Wallis Road
Segensworth East, Fareham
PO15 5TT
Company Registration Number 5021022.
Registered Office:
12-14 Carlton Place
Southampton, UK
SO15 2EA
VAT Registration Number 834 1020 74.
--
This is the Web Enabling the IBM i (AS/400 and iSeries) (WEB400)
mailing
To post a message email: WEB400@xxxxxxxxxxxx To subscribe,list
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/web400.
--
This is the Web Enabling the IBM i (AS/400 and iSeries) (WEB400)
mailing
To post a message email: WEB400@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/web400.
NOTICE: The information in this electronic mail transmission is intended
by CoralTree Systems Ltd for the use of the named individuals or entity to
which it is directed and may contain information that is privileged or
otherwise confidential. If you have received this electronic mail
transmission in error, please delete it from your system without copying or
forwarding it, and notify the sender of the error by reply email or by
telephone, so that the sender's address records can be corrected.
--------------------------------------------------------------------------------
CoralTree Systems Limited
25 Barnes Wallis Road
Segensworth East, Fareham
PO15 5TT
Company Registration Number 5021022.
Registered Office:
12-14 Carlton Place
Southampton, UK
SO15 2EA
VAT Registration Number 834 1020 74.
--
This is the Web Enabling the IBM i (AS/400 and iSeries) (WEB400) mailing
list
To post a message email: WEB400@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/web400
or email: WEB400-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/web400.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.