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

  • Home
  • SEARCH
  • 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 6607273
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T19:29:09+00:00 2026-05-25T19:29:09+00:00

I have exactly the same problem treated in this topic . That’s: I have

  • 0

I have exactly the same problem treated in this topic. That’s: I have some static files in some folders and I want only some users to see that content. That users are coming from a previous login.

To get that, I’m trying to implement the first solution given in this topic, that’s:

Create the following .htaccess file under "static-files":

Options +FollowSymLinks  
RewriteEngine on  
RewriteRule ^(.*)$ ../authorize.php?file=$1 [NC]

And then in authorize.php…

if (isLoggedInUser()) readfile('static-files/'.$_REQUEST['file']);
else echo 'denied';

This authorize.php file is grossly over simplified, but you get the idea.kquote

So, redirect any request to the authorize.php file, who check if the user is logged in and, if so, serve the content.

That’s working perfectly with html, js and images… but I don’t know why css styles are not showed. It’s strange, because I can access that css files directly with my browser, but when they are called from the html it’s not working. Of course, if I try to work without the authorize.php styles are showed as usual.

What am I missing out?

Thank you,

  • 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-25T19:29:10+00:00Added an answer on May 25, 2026 at 7:29 pm

    You are probably not sending the right content-type header. That makes style sheets fail in Firefox.

    Do a

    header("Content-type: text/css");
    

    whenever a CSS style sheet has been requested.

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

Sidebar

Related Questions

I seem to have exactly the same problem as this person: http://forums.adobe.com/thread/618752 He also
I have exactly the same problem as this SO poster; Visual Studio Crashing When
I come here from this topic Where user has exactly the same problem. I
I have two webservices that have exactly the same methods and signatures but point
vb.net windows forms question. I've got 3 forms that have exactly the same functions,
I have four tables containing exactly the same columns, and want to create a
I have classes that are named exactly the same across different plug-ins that I
I have a few tables that have similar fields but not exactly the same.
I have exactly the same problem as described here: http://bugs.jqueryui.com/ticket/7930 . The problem is
I found this thread here: http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=16836 I have exactly the same problem. Quote: Rob

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.