Hello world!

echo basename($_SERVER[‘REQUEST_URI’], ‘?’ . $_SERVER[‘QUERY_STRING’]); // returns only file name (test.php)

echo $_SERVER[‘SCRIPT_FILENAME’];  // full path with  / slahes (C:/xampp/htdocs/4126/temp.php)

echo __FILE__;  // full path with  \ slahes (C:\xampp\htdocs\4126\temp.php)

show all duplicate record if a duplicate record field is there

SELECT    tbl_country.* FROM  tbl_country


INNER JOIN (SELECT country_name FROM  tbl_country
GROUP BY country_name HAVING count(country_name) > 1) dup ON  tbl_country.country_name= dup.country_name

Advertisements

Image