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 8892055
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T22:53:54+00:00 2026-06-14T22:53:54+00:00

I’m running XAMPP on win7 to test fairly simple sites using PHP/MySQL/AJAX, and have

  • 0

I’m running XAMPP on win7 to test fairly simple sites using PHP/MySQL/AJAX, and have run into the problem of not being able to reference files correctly.

I know that C:\xampp\htdocs is “equivalent” to http://localhost/, and I have a project subdirectory in C:\xampp\htdocs\lorem_ipsum (which is http://localhost/lorem_ipsum/). Within that are some more folders (one for php scripts, one for css stylesheets, etc).

I’m having problems referencing files in these subdirectories.

For example, in lorem_ipsum/index.php I use the line:

require_once 'http://localhost/lorem_ipsum/php/login.php'

Which creates the error:

Warning: require_once(): http:// wrapper is disabled in the server configuration by allow_url_include=0 in C:\xampp\htdocs\lorem_ipsum\index.php on line 13

Warning: require_once(http://localhost/lorem_ipsum/php/login.php): failed to open stream: no suitable wrapper could be found in C:\xampp\htdocs\lorem_ipsum\index.php on line 13

Fatal error: require_once(): Failed opening required 'http://localhost/lorem_ipsum/php/login.php' (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\lorem_ipsum\index.php on line 13

By googling around I’ve gathered that it’s some sort of “filesharing/security” issue, but I have absolutely no idea what that means or how to fix it (I’m still very much a beginner).

When I use the following CSS, for example:

background-image:url('http://localhost/lorem_ipsum/images/bg.png')

The background is white, not ‘bg.png’. Same if I use './images/bg.png'.

I’ve tried all sorts of different ways to reference the files, and none have worked. I also tried taking down any firewalls and that didn’t work, either.

My ultimate question is: Why all the problems having to do with file references?

Secondary questions: Are the PHP and CSS errors related, or have I screwed them both up that badly? How can I stop this from happening? Is there a setting in apache/php that needs to change, or am I just coding it wrong?

  • 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-06-14T22:53:55+00:00Added an answer on June 14, 2026 at 10:53 pm

    In PHP, you should reference files from the Document_Root that is specified (C:\xampp\htdocs in your case). So try

    require_once "/lorem_ipsum/phplogin.php";
    

    The url in the css should work if the file is being hosted properly. But you can also try a relative path like:

    background-image:url('/lorem_ipsum/images/bg.png');
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I have a French site that I want to parse, but am running into
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have just tried to save a simple *.rtf file with some websites and
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
I am currently running into a problem where an element is coming back from
I have thousands of HTML files to process using Groovy/Java and I need to
I'm making a simple page using Google Maps API 3. My first. One marker
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example

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.