Form validation false interrupting the pagination - help ! |
[eluser]chaminda[/eluser]
Guys, When my form validation fail at login, pagination doesn't work. but when the login successful it works like a charm. i tried to initialize the pagination before the form validation rules and pass pagination along with the view. but no luck. can anyone help me to understand why is this happening? Code: function login()
[eluser]ProImage Web[/eluser]
look at your base_url in your config and then look at the view you are loading on the fail.
[eluser]osci[/eluser]
When your user is logged in he is redirected to main/index, where I suspect you have the same pagination, which should be working as you say. If he is not successfully logged in he is again redirected to your login function, no view. Also your Code: $config['base_url'] = base_url() . 'main/index'; Also your data from your model doesn't seem to handle the offset. And your idea seems a little spaghetti to me. Why would you want pagination to your login form?
[eluser]chaminda[/eluser]
[quote author="osci" date="1306983223"]When your user is logged in he is redirected to main/index, where I suspect you have the same pagination, which should be working as you say. If he is not successfully logged in he is again redirected to your login function, no view. Also your Code: $config['base_url'] = base_url() . 'main/index'; Also your data from your model doesn't seem to handle the offset. And your idea seems a little spaghetti to me. Why would you want pagination to your login form?[/quote] i have created a classified with CI and pagination used by a table in index page. the login form also in the index page. take a look at this url and try to login with invalid user and pass. then you will see what is my problem is. thanks for helping me ![]() My site |
Welcome Guest, Not a member yet? Register Sign In |