I have some php files that reside outside of EE. I would like to insert some EE content into these php files.
It works if I call the EE content via an iframe:
<iframe src="http://domain/site/permalink/auto_stores"></iframe>I would prefer not to use an iframe if possible so I thought I would try it via php include or php require:
<?php
require("http://domain/site/permalink/auto_stores");
?>The result are these messages:
Warning: require(http://domain/site/permalink/auto_stores) [function.require]: failed to open stream: HTTP request failed! HTTP/1.1 401 Access Denied in C:\Inetpub\expressionengine\firm\\index.php on line 80
Fatal error: require() [function.require]: Failed opening required ‘http://domain/site/permalink/auto_stores’ (include_path=’.;c:\\php\\pear’) in C:\Inetpub\expressionengine\firm\index.php on line 80
A similar message appears for either php include or php require.
/firm/index.php is a non-EE page calling on the EE content.
I enabled both allow_url_fopen and allow_url_include in my php.ini file.
Navigating directly to http://domain/site/permalink/auto_stores does show the content. The template used in this case is bare bones (title and body only).
Any ideas?