$this->security->get returns Undefined Index error
Asked by
jsherk
on 2011-01-13
When I use $this->
Undefined index: some_item
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- PHPDevShell Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- jsherk
- Solved:
- 2011-01-14
- Last query:
- 2011-01-14
- Last reply:
- 2011-01-14
This question was originally filed as bug #702600.
TitanKing (titan-phpdevshell) said : | #1 |
This in general is standard PHP behavior. You need to check variables are set be fore using them. The empty() function works well for this.
if (! empty($
// Do something...
}
jsherk (jeff-forerunnertv) said : | #2 |
Yes I see... I realized that I was checking isset() for the post but not for the get... as soon as I added isset() around the get it worked fine!
Thanks
To post a message you must log in.