Dean got it... it is trying to look in the /cgi-bin directory (which is
mapped to a library) and it won't work.

I would suggest referencing objects with a forward slash at all time in
your HTML, and setting up your directory structure so things are easy to
find. That will make things easier for different environments as well.

/www
/www/css
/www/javascript
/www/images

That sort of thing.. then /www will be mapped to / in your web page so
/css/filename.css is how you would specify a CSS file.

Understanding the relationships and how things are mapped is really a step
that should be taken before venturing too far into developing
applications. It just hard to follow that rule when it's so fun though. :)

Brad
www.bvstools.com


On Thu, Jan 17, 2013 at 1:24 PM, Dean, Robert <rdean@xxxxxxxxxxxx> wrote:

The link will be looking for the file in /QSYS.LIB/CGI400.LIB. Since
there's no object type *CSS, there's no way to make this work.

You need to change the link from <link rel="stylesheet"
href="dashbd02b.css" /> to something like <link rel="stylesheet"
href="/dashbd02b.css" />

Then IHS will look for dashbd02b.css file in the server's document root in
the IFS.
-----Original Message-----
From: web400-bounces@xxxxxxxxxxxx [mailto:web400-bounces@xxxxxxxxxxxx] On
Behalf Of Steve Richter
Sent: Thursday, January 17, 2013 2:16 PM
To: Web Enabling the AS400 / iSeries
Subject: [WEB400] CSS file not being found

Why would my css file not be found for the web page I am serving from a
CGI-BIN AS400 library?

this is the url that I navigate to:
http://intranet400.sssss.com/cgi-bin/Dashbd02c

there is a program named dashbd02c in library CGI400 on the as400. This
works.

But the CSS is not being found.
fiddler tells me the .css file is being looked for in
/cgi-bin/dashbd02b.css

but cgi-bin in this apache config is an as400 library.
ScriptAlias /cgi-bin/ /qsys.lib/cgi400.lib/

Here is my apache config.

The name is INTRANET

the member INTRANET in QATMHINSTC contains the following:
-apache -d /www/intranet -f conf/httpd.conf -AutoStartY

so I would expect the server to search /www/intranet for the .css file.
But it is not being found. Fiddler has the line marked in red.
"/cgi-bin/dashbd02b.css"

there are a few <Director> entries in the .CONFD file <Directory
/www/steve/css>
order allow,deny
allow from all
</Directory>

currently I have the .CSS file in the /www/intranet directory. also the
/www/steve directory.

here is my HTML code:

<html>
<head>
<meta http-equiv="refresh" content="120"> <link rel="stylesheet"
href="dashbd02b.css" /> </head> <body> <H1>some heading text</H1> <P> some
paragraph text.
</P>
<pre>
some pre text lines
line 1 line 1 line 1 line 1
line 2 line 2 line 2 line 2
line 3 line 3 line 3 line 3
</pre>

</body>
</html>
--
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.

--
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 thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.