Welcome Guest, Not a member yet? Register   Sign In
why upload to remote server, CI appear error?
#1

[eluser]cpliu903[/eluser]
why upload to remote server, CI appear more error?

Code:
A PHP Error was encountered

Severity: Notice

Message: Undefined property: Gallery::$pagination

Filename: controllers/gallery.php

Line Number: 24

However, it's not appear error message in the localhost
#2

[eluser]CroNiX[/eluser]
Let me guess, you developed in windows and uploaded to a linux server. Check the file and directory names. Windows sees a file named "Hello.txt" and "hello.txt" as the same file (not case sensitive) while linux will see them as different.
#3

[eluser]cpliu903[/eluser]
[quote author="CroNiX" date="1268905067"]Let me guess, you developed in windows and uploaded to a linux server. Check the file and directory names. Windows sees a file named "Hello.txt" and "hello.txt" as the same file (not case sensitive) while linux will see them as different.[/quote]

Yes, windows development and Linux production

Code:
$this->load->library('pagination');

$this->pagination->initialize($config);

It is default library? why also error?
#4

[eluser]Zeeshan Rasool[/eluser]
Post your controller function here
#5

[eluser]cpliu903[/eluser]
[quote author="Zeeshan Rasool" date="1268911299"]Post your controller function here[/quote]

Code:
class Gallery extends Controller {
    
    function Gallery() {
        parent::Controller();
    }
    
    
    function show() {
        
        $this->load->library('pagination');
        $config['base_url'] = 'http://example.com/index.php/test/page/';
        $config['total_rows'] = '200';
        $config['per_page'] = '20';
        $this->pagination->initialize($config);
        
        $this->load->view('gallery_view');

    }
    
  

}


Quote:http://test.com/index.php/gallery/show
error message:
A PHP Error was encountered

Severity: Notice

Message: Undefined property: Gallery::$pagination

Filename: controllers/gallery.php

Line Number: 15

Fatal error: Call to a member function initialize() on a non-object in xxx

PHP version : 5.2
#6

[eluser]cpliu903[/eluser]
any other idea?




Theme © iAndrew 2016 - Forum software by © MyBB