I have tried to do some research on this problem and thought maybe I need to ask a different question.
I have been working my way through PHP & My SQL: Novice to Ninja 6th edition. I have had a few hiccups but have managed to work things out until the end of chapter 2 Many Templates, One Controller. When I set up the files as directed and go to http://192.168.10.10/index.php instead of a form asking me for my name I receive these messages:
Warning : include(/home/vagrant/Code/Project/public/…/templates/form.html.php): failed to open stream: No such file or directory in /home/vagrant/Code/Project/public/index.php on line 3
Warning : include(): Failed opening ‘/home/vagrant/Code/Project/public/…/templates/form.html.php’ for inclusion (include_path=’.:/usr/share/php’) in /home/vagrant/Code/Project/public/index.php on line 3
This is the situation – in my homestead.yaml I have these lines:
- map: c:/users/diane/classics_test/classics_test
my index.php is in c:/users/diane/classics_test/classics_test/project/public should this be the same as /home/vagrant/code/project/public?
the file I am attempting to include (form.html.php) is in c:/users/diane/classics_test/classics_test/project/templates
I am including it with this –
include DIR . ‘/…/templates/form.html.php’
when I echo DIR I get /home/vagrant/Code/Project/public/ so when I go up a level and then to /templates I should be in the correct spot, right?
It seems to me all of that checks out, so should my real question be what is meant by (include_path=’.:/usr/share/php’) in the warning?