Results 1 to 6 of 6
Thread: include() through HTTP?
Apr 22, 2009, 08:51 #1
- Join Date
- Dec 2008
- Plymouth, United Kingdon
- 0 Post(s)
- 0 Thread(s)
include() through HTTP?
Can I include file through HTTP? I tried the example below from http://uk2.php.net/function.include
but it is def not working on my localhost.
<?php // Won't work; file.txt wasn't handled by www.example.com as PHP include 'http://www.example.com/file.txt?foo=1&bar=2'; // Won't work; looks for a file named 'file.php?foo=1&bar=2' on the // local filesystem. include 'file.php?foo=1&bar=2'; // Works. include 'http://www.example.com/file.php?foo=1&bar=2'; $foo = 1; $bar = 2; include 'file.txt'; // Works. include 'file.php'; // Works. ?>
This is what I tried to include
<?php include 'http://localhost/mysite/incl_layouts.blog/navigation.php';?>