J
Jim Rendant
I am having a problem with programming in perl using paths to style sheets
and other static pages. I need a little clarification
My scenario
root directory | - /var/www
html directory | - /html FULL PATH - /var/www/html
images dir | - /images -
/var/www/html/images
cgi-bin dir | - /cgi-bin -
/var/www/cgi-bin
perl scripts dir | -/perl -
/var/www/cgi-bin/perl
The PERL directory holds programs that create pages on the fly by reading
both dynamic data and snippets of the final html page. The page is assembled
by reading a snippet file and then inserting dynamic data and reading
another snippet. I PRINT the snippet to Standard Out which is the web page
itself.
My CSS page is stored in my /var/www/html directory. In my HTML text stored
in the /var/www/cgi-bin/perl, I use the statement:
<link href="html/base.css" rel="stylesheet" type="text/css">
Since normally everything is relative to the base directory "/var/www" I
would think that it should work but it does not.
If I use the full path it cant find the file
"/var/www/var/www/html/base.css" Which shows that it append the full path
name to the base directory.
How can I programmatically specify the path to my CSS sheets and for that
matter my images when I use them?
Thanks in advance
and other static pages. I need a little clarification
My scenario
root directory | - /var/www
html directory | - /html FULL PATH - /var/www/html
images dir | - /images -
/var/www/html/images
cgi-bin dir | - /cgi-bin -
/var/www/cgi-bin
perl scripts dir | -/perl -
/var/www/cgi-bin/perl
The PERL directory holds programs that create pages on the fly by reading
both dynamic data and snippets of the final html page. The page is assembled
by reading a snippet file and then inserting dynamic data and reading
another snippet. I PRINT the snippet to Standard Out which is the web page
itself.
My CSS page is stored in my /var/www/html directory. In my HTML text stored
in the /var/www/cgi-bin/perl, I use the statement:
<link href="html/base.css" rel="stylesheet" type="text/css">
Since normally everything is relative to the base directory "/var/www" I
would think that it should work but it does not.
If I use the full path it cant find the file
"/var/www/var/www/html/base.css" Which shows that it append the full path
name to the base directory.
How can I programmatically specify the path to my CSS sheets and for that
matter my images when I use them?
Thanks in advance