Welcome Guest, Not a member yet? Register   Sign In
Site only runs default controller index function, no matter the URI
#11

[eluser]Dahak-II[/eluser]
I realized that the bit that was pointed out to me last night about the controller constructor calls hadn't been implemented in the model constructors.

Things have improved, in the sense that my log files now show my trace logging for the controller and model calls, but it's not rendering the results.

The log is showing:

Code:
DEBUG - 2011-02-14 19:35:03 --> URI Class Initialized
DEBUG - 2011-02-14 19:35:03 --> Router Class Initialized
DEBUG - 2011-02-14 19:35:03 --> No URI present. Default controller set.

I've cycled through the uri_protocol values on the target server again without success.

Interim verdict: incomplete migration to 2.0, but still not running yet.
#12

[eluser]crnalajna[/eluser]
You may try to look into phpinfo() to see what happen with your url. - phpinfo(32);
You can make screenshoot of that phpinfo screen and attach it here.

I don't konw but maybe your php is working in cgi mode or something, and if so you need a different .htaccess setup.
http://ellislab.com/forums/viewthread/96347/
#13

[eluser]Dahak-II[/eluser]
I posted this in the other, similar thread.

I've established that the, IIRC, $_SERVER['QUERY_STRING'] (I always extend the Profiler library to include displaying all of the superglobals) value holds my URI and that when I set uri_protocol to QUERY_STRING the URI library reads in the values and sets $this->uri->uri_string and $this->uri->segments (I believe that's pluralized).

The values in those two variables seem to hold what they should.

At a guess, it's getting lost somewhere in the Router library.

I called it a night at that point last night and I'll see what I can trace tonight.

As for the htaccess files, this is not a new installation, but an upgrade from a previously-running CI1.73 setup, so I'm not quite prepared to assault the htaccess file yet.
#14

[eluser]Ayeyermaw[/eluser]
[quote author="JasonS" date="1297605597"]Try changing the 'uri_protocol' config option to something else.[/quote]
This solution is what resolved my issue.
I found that if this config setting was set to anything other than 'QUERY_STRING' or 'REQUEST_URI' then my default controller would always load
#15

[eluser]Unknown[/eluser]
$config['uri_protocol'] = 'ORIG_PATH_INFO';
did the trick for me.
#16

[eluser]wh1tel1te[/eluser]
I had almost the exact same problem as you. I uploaded my CI 2.0 to production, and all URL's pointed to the home page no matter what. However, this was a new CI installation, not an upgrade. After fiddling with my .htaccess for ages, I finally got it to work with this:

Code:
RewriteEngine On

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]

Hopefully it helps.
#17

[eluser]predat0r[/eluser]
[quote author="wh1tel1te" date="1299575549"]I had almost the exact same problem as you. I uploaded my CI 2.0 to production, and all URL's pointed to the home page no matter what. However, this was a new CI installation, not an upgrade. After fiddling with my .htaccess for ages, I finally got it to work with this:

Code:
RewriteEngine On

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]

Hopefully it helps.[/quote]

I used mariuskmc's htaccess file with modified RewriteBase and it WORKS. (CI 2.0.1)

By the way, thanks for the solution!
#18

[eluser]crimsun[/eluser]
Hello Team,


I use the htaccess that you provide over here but still i have some problem in url actually problem is something differant let me post here the url

When i logged in site with using the folowing link
http://localhost/demo/loginadmin

After suucessfull login i use redirect('homeadmin/viewadmins');
and the link in url is like below

http://localhost/demo/?homeadmin/viewadmins

And it not gives proper result on page just page get blank...
and when i remove that "?" symbol so it work fine so how can i remove that using htaccess or anuy other help please suggest me.....
i need following link
http://localhost/demo/homeadmin/viewadmins

Thanks in Advance Smile
#19

[eluser]Dahak-II[/eluser]
Just a long-term follow-up to this thread.

I've been experimenting with the same system configuration (Dev-WIMP, 'Production'-LAMP) with the newer CI v2.0.2.

I uploaded the raw default installation with the htaccess stripping out the index.php file and it worked in both environments.

I then upgraded a clean copy of my site code to the v2 standard and it now seems to be running on the remote LAMP system.

No clear idea why v2_0_0 didn't want to work, but I suspected something related to the router.

I had to tweak a few bits of link generating code, but that was fairly trivial.
#20

[eluser]coolgeek[/eluser]
Yeah, I just switched back to AUTO on v2.0.1

I also switched back to 2.0.1 from 2.0.2 because the Security class hosed the CSRF cookie handling




Theme © iAndrew 2016 - Forum software by © MyBB