1

私の問題は、コードイグナイターのルートに関するものです。私はそれで作業しており、関数ごとにルートを書きました。最後のルートを配置すると、これが機能せず、404 エラーが発生します。どうしてか分かりません?ルートの順番を間違えているのかもしれませんが、正しいと思います。これは私のルートです:

 //MATCH SHARE
// route not working 
    $routes['upload_image/upload_photo'] = "upload_image/upload_photo"; 

//all route working
    //VOTATION//
    $route['auth_social/fblogin'] = "auth_social/fblogin";
    $route['votation/user_plus/(:any)'] = "votation/user_plus";
    $route['votation/user_minum/(:any)'] = "votation/user_minum";



    $route['finish_registration/(:any)/(:any)'] = "auth/activate"; // activate e-mail
    $route['auth'] = "auth"; // index auth
    $route['register'] = "auth/register";
    $route['login'] = "auth/login"; // login
    $route['logout'] = "auth/logout";
    $route['default_controller'] = "auth/register"; // register

    $route['(:any)'] = "profile/user";

    $route['404_override'] = '';

htaccess

RewriteEngine on
RewriteCond $1 !^(index\.php|resources|robots\.txt)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
4

2 に答える 2

0

あなたの変数は間違っ $routesているはずです $route['upload_image/upload_photo'] = "upload_image/upload_photo";

于 2014-02-15T17:07:03.720 に答える