php - Database error when accessing $_SERVER variable in Codeigniter -


i'm using codeigniter , i'm trying echo $_server['http_referer']. whenever tried access $_server variable i'm getting database error.

a database error occurred  unable select specified database: my_db_name  filename: core/loader.php  line number: 346 

is codeigniter restriction or bug.

so, can use :

$this->load->library('user_agent'); echo $this->agent->referrer(); 

read also: http://ellislab.com/codeigniter/user-guide/libraries/user_agent.html


Comments

Popular posts from this blog

PHPMotion implementation - URL based videos (Hosted on separate location) -

javascript - Using Windows Media Player as video fallback for video tag -

c# - Unity IoC Lifetime per HttpRequest for UserStore -