1
I am working on a blog where within a specific page it has an iframe that points inside the server itself, calling a folder that contains the running Codeigniter.
Until a few days everything worked, this in the old server. I had to switch server and the current server does not work. The only page it opens is the page configured in codeigniter to be the initial, when I need to access a controller I get an error 404.
Wordpress tries to access a folder, and actually this folder does not exist, for example I inform the following url:
server.com.br/codeigniter/controller/action/
Instead of entering the controller and looking for the action it looks for folders and obviously these folders don’t exist, I created folders with these paths and it got the index I put inside the "action" folder, but that’s not what I need. I need it to behave like a framework.
I need a way that when I point to server.com.br/codeigniter/ it understands that it is no longer to behave as if it were the blog, and start behaving like a framework.
I don’t understand anything. htaccess is one of my worst points as a programmer, I tried most of the day to fix a solution with htaccess, but as you can see I had no success, I’m not sure if the correct way to solve this problem would be with htaccess, but it was the only possible exit I could find.
Follow htaccess from wordpress:
\# BEGIN WordPress<br/>
< IfModule mod_rewrite.c> <br/>
RewriteEngine On <br/>
RewriteBase /<br/>
RewriteRule ^index\.php$ - [L]<br/>
RewriteCond %{REQUEST_FILENAME} !-f<br/>
RewriteCond %{REQUEST_FILENAME} !-d<br/>
RewriteRule . /index.php [L]<br/>
< /IfModule> <br/>
\# END WordPress
And also htaccess from codeigniter
RewriteEngine on<br/>
RewriteCond %{REQUEST_FILENAME} !-f<br/>
RewriteCond %{REQUEST_FILENAME} !-d<br/>
RewriteRule ^(.*)$ /index.php?$1 [L]<br/>
If I enter the codeigniter directly by a subdomain the program runs perfectly, however, I cannot access iframe with a subdomain, as I need to retrieve data/variables from within iframe with jQuery/Ajax, if I use a subdomain this is not possible, I need a way to make the blog understand that when it’s server.com.br/codeigniter it starts using codeigniter htaccess, or it enters the controllers instead of looking for folders, (I think this is the solution.)