PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Sunday, July 3, 2022

[FIXED] how to access multiple php files in different sub-folders under LAMPP in LINUX

 July 03, 2022     lampp, linux, php, phpmyadmin, xampp     No comments   

Issue

Hi I am new to LINUX and recently installed LINUXFX which was working great. Now I have LAMPP (XAMPP) Configuration issue with it. After installing XAMPP I was able to load XAMPP demo page successfully, but if I want to open my project folders which are located in different sub-directories, I can't.

In detail, I have copied my project folders to /LAMPP/HTDOCS/ and in .CONF File I could be able to change the root path to access only one project folder. How can I make it for multiple projects. Please Help!

if($row){
   if($row['role']==0 || $row['role']=='0'){
    $_SESSION['login']=$Cashier;
    echo'<script>location.href="admin_dashboard.php";</script>'; 
    }elseif($row['role']==1 || $row['role']=='1'){
        $_SESSION['login']=$Cashier;
    echo'<script>location.href="cashier_dashboard.php";</script>';
  }else{
    echo'<script>alert("!This username  "); 
location.href="index.php";</script>';
    }
}else{
echo'<script>alert("!This username and password do not match "); 
location.href="index.php";</script>';
  }

}
$conn->close();

Solution

I have solved the problem as mentioned below. First as suggested by @Cbroe, I set the path in the Apache Config file. The issue is with the file name. The file name was given as "cashier_dashboard.php" in the code and the original file name was "Cashier_Dashboard.php". As earlier while doing the same in windows 10, it was accepting the code without any problem. I presume in LINUX, we must be very careful in assigning the file name and this should be same in the PHP code as well!

Thank you @cbroe for guiding me!



Answered By - Phani Lanka
Answer Checked By - Mary Flores (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing