Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6134637
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T17:22:48+00:00 2026-05-23T17:22:48+00:00

I serve content from a subdirectory on my web server, for example: http://www.myserver.com/subtree I

  • 0

I serve content from a subdirectory on my web server, for example:

http://www.myserver.com/subtree

I notice that the CSS is not rendering correctly, so I look at the source of the HTML file:

<link rel="stylesheet" type="text/css" href="static/stylesheets/style.css"/>

One would expect that browsers such as Chrome or Firefox attempt to find this css at

http://www.myserver.com/subtree/static/stylesheets/style.css

When hovering over the link, I can see that it links me to

http://www.myserver.com/static/stylesheets/style.css

It may be useful to note that I’m using apache’s mod_proxy to serve the content from /subtree from another server running on the local machine. However, my reasoning is that the browser doesn’t know about this and it looks like the content is coming from myserver.com/subtree so therefore it should look for the resources using the relative path.

What am I missing?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T17:22:49+00:00Added an answer on May 23, 2026 at 5:22 pm

    That’s to be expected. The browser cannot know that /subtree is a folder (instead, it could also be just a file served as text/html). If you want the browser to include this path fragment in relative path lookups, make sure that it ends with as slash, as in:

    http://www.myserver.com/subtree/
    

    If you are using Apache, you can use mod_dir’s DirectorySlash directive to automatically fix this for you: mod_dir documentation

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to serve a different content from a single URL depending on
I have some content from server using $.ajax() function. I try to replace some
Can a (||any) proxy server cache content that is requested by a client over
I'm using Java for accessing Alfresco content server via it's web service API for
Scenario is that we send out thousands of emails through SMTP server. Content is
dHi, I'm trying to setup my IIS server (6.0) to serve files from a
From one apache server file_get_contents returns the contents of a url straight away. On
I need to serve audio content (not music though, more like podcasts; human speech),
In an oscommerce site I have the following: Server response = Content-type: text/html;charset=UTF-8 and
I was wondering whether SVN actually compresses the binary content on the server during

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.