0

I'm new to Linux and, I'm trying Ubuntu for the first time. I've installed the XAMPP package for linux which, placed the htdocs into the opt/ directory. I've played around building simple pages and it worked just fine. Than, I've decided to pull one of my projects from Git to give it a try but, the include fails saying the file path is invalid. To make sure the package was good, I've installed it to a shared server also running linux and, everything worked just fine. Now, I'm a bit confused. I tried to search for a solution but, still can't figure our what is really wrong. What is odd to me is, although the files were installed (cloned from git) into the opt/htdocs directory, the file properties says a different path (home/myname/Desktop/Localhost). I've made a shortcut from localhost folder to the desktop so, I'm not sure if that's correct or not. By typing php -v I get the response:

PHP 7.0.8-0ubuntu0.16.04.2 (cli) ( NTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies
    with Zend OPcache v7.0.8-0ubuntu0.16.04.2, Copyright (c) 1999-2016, by Zend Technologies

My phpinfo file says:

PHP Version 5.6.24
Server Root /opt/lampp
root:   /opt/lampp/htdocs

And, the PHP error:

include(/opt/lampp/htdocs/Praktik/core/db_connectors/MYSQLi.php): failed to open stream: No such file or directory in /opt/lampp/htdocs/Praktik/core/PraktikConnect.php on line 75

What am I doing wrong?

PS. the installation also worked in other windows machines. I've tried the steps at PHP - Failed to open stream : No such file or directory. Although very similar, it doesn't solved the problem.

Community
  • 1
  • 1
Jay
  • 312
  • 3
  • 12
  • 1
    don't use xampp on ubuntu; just `apt-get install apache php` suffices – hanshenrik Sep 21 '16 at 20:56
  • are you on freenode? – hanshenrik Sep 21 '16 at 20:57
  • @hanshenrik Thank you for the reply, I'm uninstalling XAMPP than will follow your instructions. I'll get back to you once I give it a try. – Jay Sep 22 '16 at 14:55
  • @hanshenrik You were right, looks like it was conflict or something. I've followed the steps here: http://howtoubuntu.org/how-to-install-lamp-on-ubuntu and, everything worked as it should. Thanks! – Jay Sep 22 '16 at 15:42

0 Answers0