• I thought I’d mention how I fixed Page not found 404 errors on the initial setup of a clean WP and WPCI installation.

    The problem I was having was that only the frontpage, the wp-admin, and non-permalinks were showing correctly. Using permalinks on pages gave me a 404 error.

    The problem boiled down to an incorrectly configured /application/config/routes.php in the ci folder. I added a single line to make things work:


    <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
    /*
    ...excluding these comments...
    */

    $route['(:any)'] = "welcome/index/$1"; # this line is new!

    $route['default_controller'] = "welcome";
    $route['404_override'] = '';

    /* End of file routes.php */
    /* Location: ./application/config/routes.php */

    If I were the plugin maintainer, I’d mention this issue in the install instructions. Some CI users are not experienced enough to realize this problem right away.

    Other than that, I’m very excited to use this plugin. I plan on using another plugin to insert php tags inside pages/posts, so that WP pages/post can function like a view in the MVC pattern.

    http://wordpress.org/extend/plugins/wp-code-igniter/

Viewing 9 replies - 1 through 9 (of 9 total)
  • i have followed installation instruction from both code igniter and this plugin but my site still blank when i am using permalink structure. i guess it’s not my day 🙂

    Thread Starter Gavin

    (@gavinengel)

    @achmad_i79 if your problem is a blank white screen, you should look at your httpd error log.

    no, i cannot even access to wp-login.php but after I delete the folder wp-code-igniter inside wordpress plugin folder now my site is back to normal , here’s my site http://fnb-fashion.com/

    I just wanted to learn basic programming of code igniter and implemented in wordpress, eventhough i found fully working joomla component to integrate code igniter with it it’s right at http://xavoc.com/index.php?option=com_rokdownloads&view=folder&Itemid=156 but i still not ready to migrate to Joomla

    Thread Starter Gavin

    (@gavinengel)

    I’d recommend you don’t give up on WordPress just yet. I don’t know that much about Joomla, but I do know quite a bit about Drupal–and they are supposedly very similar. And the conclusion I’ve come to with Drupal after years of working with it is: only use it when you cannot use WordPress (it is a pain). I suspect the same can be said for Joomla.

    WordPress programming is also a bit of a pain, but this is why integrating an MVC system into a easy-to-use CMS like WordPress really excites me. I haven’t created a production ready site out of WP/CI, but I have very high hopes.

    As for your current problem, I think you are using Blue Host (I pinged your domain name). I believe Blue Host gives access to the Apache log files in cPanel, you should check that out. Alternatively, if you have shell (ssh) access, you should be able to vi or tail the error log on the command line. That is definitely the first thing you should try.

    It could be that you are running PHP version 4 and a PHP 5 function caused a fatal error. Or it could be a hundred other things. But the error log should give you the information you need to debug it.

    There are times when the error log doesn’t, and I’ve had to put in echo __file__.__line__; statements all over my code. But that technique comes after checking the error log.

    I’ve checked error log inside cpanel and it said :

    [Mon Oct 03 02:59:07 2011] [warn] RewriteCond: NoCase option for non-regex pattern ‘-f’ is not supported and will be ignored.

    do you have any suggestion for configuration inside code igniter, because wordpress doesn’t allow me to play arround with their .htaccess file directly. each time i edit .htaccess inside file manager. my site encounter 500 error problem

    Thread Starter Gavin

    (@gavinengel)

    .htaccess editing is tricky. It still is mostly magic to me.

    2 ideas, first locate the exact line in .htaccess causing the problem, then play around with it.

    Second, it seems that Blue Host doesn’t allow an Apache mod that is needed. You can see about enabling Apache mods in cPanel, but I doubt you’ll succeed. Or, you can switch web hosts to one where you have full control over cPanel. This is a drastic change, I understand. But I think in the end you’d be happier.

    With cloud servers like Rackspace cloud or vr.org (not Amazon EC2 they are expensive), you have full access to everything on the server, and it only costs $10.50 a month. That’s probably twice as much as Blue Host, but the experience you will gain from maintaining your Linux host is immeasurable. I have a feeling you will encounter these kinds of oddities from time to time with a Blue Host or Godaddy, because I have. So I think in the end, you’ll be happier spending the extra $5 a month.

    Sorry if that doesn’t help you much.

    you right about the limitation in bluehost probably in the near future i’ll purchase Dedicated server, for a while i’ll use this plugin without permalink. anyway thanks for your response gavinengel.
    btw wildmice the plugin maker is awesome he also created wp-zend library at http://wordpress.org/extend/plugins/wp-zend-library/ i haven’t test it yet. i’m just curious where the hell is he

    Thread Starter Gavin

    (@gavinengel)

    By the way, don’t get suckered into spending too much for hosting. With Rackspace Cloud or vr.org, you can get great hosting for $11/month.

    I’m not sure what wildmice is doing. I don’t know him/her.

    Thread Starter Gavin

    (@gavinengel)

    Oh and by the way, if you do get a VPS, and if it is Ubuntu, here is are some basic commands for setting up the server (to give you an idea of what I have found to be a good starting point):

    [42 lines of ‘code’ moderated as per the Forum Rules. Please use the pastebin]

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘[Plugin: WP Code Igniter] [fixed] Page Not Found errors’ is closed to new replies.