Including WordPress with php.
-
If I have my WordPress index in a different directory (/wordpress/index.php), how do I use php includes to place it in my site’s index file? I tried
<div style=”position:absolute;left:24px;top:286px;width:270px;z-index:1;” align=”justify”>
<?php include(“home/username/public_html/wordpress/index.php”); ?>
</div>but I get the following errors:
Warning: main(home/vibrant/public_html/wordpress/index.php): failed to open stream: No such file or directory in /home2/vibrant/public_html/blog.php on line 3
Warning: main(): Failed opening ‘home/vibrant/public_html/wordpress/index.php’ for inclusion (include_path=’.:/usr/lib/php:/usr/local/lib/php’) in /home2/vibrant/public_html/blog.php on line 3
Is there any way to include it or will I have to install WordPress in my root directory?
The topic ‘Including WordPress with php.’ is closed to new replies.