// Set Favicon function getDomainFromEmail($email) { // Get the data after the @ sign return substr(strrchr($email, "@"), 1); } $path = "/testweb/home.php"; //Show filename with file extension echo basename($path) ."
"; //Show filename without file extension echo basename($path,".php"); ?> The output of the code above will be: home.php home $quote = DB::table('quotes') ->select('quote') ->orderBy('rand()') ->limit(1) ->pluck('quote');