Welcome Guest, Not a member yet? Register   Sign In
Help!! I am getting an error I can not understand trying to load a view...
#1

[eluser]nealumney[/eluser]
Hi folks,

Not use why but I am getting this error:

"Unable to load the requested file: noitemfound.php"

This happens after the following code:

Code:
if (!$items = $this->item->getitemsforsale($this->input->post('itemid')) )
        {
            $this->load->view('noitemfound');
        }

The 'noitemfound.php' file is in the application views directory and actually contains no php at all and is just a polite notification that the user needs to refine their search criteria. I am sure you need more information to help, but not sure what more you need. I should point out that the message is a response to an ajax call.

Thanks.

Neal
#2

[eluser]TheFuzzy0ne[/eluser]
Check the case of the file (it should be all lowercase).
Check the permissions of the file.
Check that Darth Vader is not in the vicinity playing Jedi mind tricks on you.
#3

[eluser]nealumney[/eluser]
There are times when a on man feels like a complete fool... I am talking about me! I could not see the wood for the trees... and yes the case for the view was not that used in the load request... how dumb am I!!

I am sure Darth Vader had something to do with it though!!
#4

[eluser]Dave Blencowe[/eluser]
For simplicities sake I always find it is easier to user lower-case alphanumeric names for all my files. If a space is needed then I substitute it with an underscore. Having a good practice like this will prevent errors, make it easier to find files and also make your finished product look much more polished.
#5

[eluser]TheFuzzy0ne[/eluser]
This should be made more clear in the user guide.

Slightly off-topic: The PHP Style Guide is worth a read - http://ellislab.com/codeigniter/user-gui...guide.html
#6

[eluser]Dam1an[/eluser]
Love the implication of anything going wrong being Darth Vadars fault
I personally prefer to blame it on the misalignment of the moon Wink
#7

[eluser]wiredesignz[/eluser]
You know you're a nerd if bugs in your code are blamed on Star Wars characters. Tongue
#8

[eluser]TheFuzzy0ne[/eluser]
You know you're a geek if you start calling people nerds for blaming bugs in their code on Star Wars characters.
#9

[eluser]wiredesignz[/eluser]
Yes. Wink

EDIT:
But I blame Derek Jones or Derek Allard for the bugs in my code.
#10

[eluser]TheFuzzy0ne[/eluser]
You mean OB-wan Kenobi and Luke Skywalker?




Theme © iAndrew 2016 - Forum software by © MyBB