Welcome Guest, Not a member yet? Register   Sign In
Prevent direct access to views
#6

[eluser]Bart Mebane[/eluser]
Another option is the approach used in the CI system files. Include this line at the top of every source file:
Code:
if ( ! defined('BASEPATH')) exit('No direct script access allowed');
The BASEPATH constant is defined in index.php. This statement thus allows pages to be accessed only through CI.


Messages In This Thread
Prevent direct access to views - by El Forum - 11-03-2010, 05:31 AM
Prevent direct access to views - by El Forum - 11-03-2010, 05:54 AM
Prevent direct access to views - by El Forum - 11-03-2010, 05:56 AM
Prevent direct access to views - by El Forum - 11-03-2010, 06:26 AM
Prevent direct access to views - by El Forum - 11-03-2010, 06:29 AM
Prevent direct access to views - by El Forum - 11-03-2010, 06:42 AM
Prevent direct access to views - by El Forum - 11-03-2010, 07:24 AM
Prevent direct access to views - by El Forum - 11-03-2010, 08:31 AM



Theme © iAndrew 2016 - Forum software by © MyBB