json - How to Protect PHP Url From Direct Accessing? -


i using web link eg: http://example.com/abc/abc.php retrieving json data in application eg windows phone.

everything works fine url can direct accessible browser. don't want url direct accessible.

how protect url direct access allow app?

you can either use .htaccess(it's file can use url rewriting , redirecting), , no . . . don't know lot of that, you'd have how it.

but, if file php or phtml file, write:

<?php  // redirect away file whenever go access it. header("location: your/location/file.php");  ?> 

anyways, that's can with, successful answering this.


Comments

Popular posts from this blog

php - trouble displaying mysqli database results in correct order -

depending on nth recurrence of job in control M -

sql server - Cannot query correctly (MSSQL - PHP - JSON) -