<p>Have you tried adding <code>'omitScriptNameInUrls' =&gt; true,</code> to your <code>general.php</code> settings?</p>

<p><a href="http://buildwithcraft.com/docs/config-settings#omitScriptNameInUrls" rel="nofollow">http://buildwithcraft.com/docs/config-settings#omitScriptNameInUrls</a></p>

CC BY-SA 3.0
2015-09-22T18:50:03.370Z
Hi @dgrebb, I've set that to true aswell as 'usePathInfo' => true but not seeing any change.
Boxhead
CC BY-SA 3.0
2015-09-22T20:13:43.443Z
Hi @dgrebb, you were right about the omitScriptNameInUrls setting. That fixed the URLs but we're still seeing issues with no entry/asset/category lists loading in the CP. Any thoughts?
Boxhead
CC BY-SA 3.0
2015-09-22T17:55:47.093Z
2015-09-22T17:55:47.093Z
dgrebb
<p>With regard to the 2nd part of the original question, whereby no entry, asset, category or user lists were display, this turned out to be a post_max_size issue in the php.ini config. It had been incorrectly set to 64<strong>MB</strong> rather than 64<strong>M</strong>.</p>

CC BY-SA 3.0
2015-09-23T14:29:40.120Z
Interesting find. Glad you got it sorted!
dgrebb
CC BY-SA 3.0
2015-09-23T12:33:13.157Z
2015-09-23T12:33:13.157Z
Boxhead
<p>All of our control panel URLs are being rewritten to show index.php?p=admin/***</p>

<p>While this isn't a problem in itself we can't determine why it's happening when the frontend of the website itself is writing the URLs cleanly and correctly without the index.php?p= </p>

<p>We have in our .htaccess file</p>

<pre><code>&lt;IfModule mod_rewrite.c&gt;
  RewriteEngine On

  # Send would-be 404 requests to Craft
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_URI} !^/(favicon\.ico|apple-touch-icon.*\.png)$ [NC]
  RewriteRule (.+) index.php?p=$1 [QSA,L]
&lt;/IfModule&gt;
</code></pre>

<p>There are no other Rewrites happening.</p>

<p>A possibly related issue we're seeing is that there are no entries, assets or categories listing in the control panel. Looking through the logs I can see the following</p>

<pre><code>2015/09/22 16:55:23 [error] [exception.Craft\HttpException.400] exception 'Craft\HttpException' with message 'Param “elementType” doesn’t exist.' in /var/www/vhosts/mysite.org/httpdocs/craft/app/services/HttpRequestService.php:586
Stack trace:
#0 /var/www/vhosts/mysite.org/httpdocs/craft/app/controllers/BaseElementsController.php(50): Craft\HttpRequestService-&gt;getRequiredParam('elementType')
#1 /var/www/vhosts/mysite.org/httpdocs/craft/app/controllers/ElementIndexController.php(68): Craft\BaseElementsController-&gt;getElementType()
#2 /var/www/vhosts/mysite.org/httpdocs/craft/app/framework/web/CWebApplication.php(281): Craft\ElementIndexController-&gt;init()
#3 /var/www/vhosts/mysite.org/httpdocs/craft/app/etc/web/WebApp.php(784): CWebApplication-&gt;runController('elementIndex/ge...')
#4 /var/www/vhosts/mysite.org/httpdocs/craft/app/etc/web/WebApp.php(276): Craft\WebApp-&gt;_processActionRequest()
#5 /var/www/vhosts/mysite.org/httpdocs/craft/app/framework/base/CApplication.php(184): Craft\WebApp-&gt;processRequest()
#6 /var/www/vhosts/mysite.org/httpdocs/craft/app/index.php(62): CApplication-&gt;run()
#7 /var/www/vhosts/mysite.org/httpdocs/index.php(40): require_once('/var/www/vhosts...')
#8 {main}
REQUEST_URI=/index.php?p=admin/actions/elementIndex/getElements
HTTP_REFERER=http://mysite.org/index.php?p=admin/entries/pages
---
2015/09/22 16:55:23 [error] [application] Param “elementType” doesn’t exist.

******************************************************************************************************
</code></pre>

<p>We do have PATH_INFO installed and enabled on the server.</p>

<p>Craft Pro 2.4.2692</p>

<p>Any help would be much appreciated.
Many thanks</p>

CC BY-SA 3.0
2015-09-22T19:40:56.620Z
Sounds like a dupe? Try this: https://craftcms.stackexchange.com/questions/4386/url-rewrites-not-working-return-apache-404s/4387#4387
Brad Bell
CC BY-SA 3.0
2015-09-22T19:51:08.510Z
Hi @BradBell I don't think it's the same problem. My .htaccess file is being used (if I put invalid apache config settings in there it breaks the whole site). Also I'm only seeing problems in the Control Panel, the sites front-end is working a treat!
Boxhead
CC BY-SA 3.0
2015-09-22T20:00:36.383Z
You sure there's no parent `.htaccess` file above Craft's? The rules will inherit from each other.
Brad Bell
CC BY-SA 3.0
2015-09-22T20:12:35.337Z
My bad, I was editing a staged version of the general.php config file. Adding 'omitScriptNameInUrls' => true fixed the URLs (must have cached false at some point). We're still experiencing trouble loading entries/assets/categories in the CP though. Any thoughts?
Boxhead
CC BY-SA 3.0
2015-09-22T20:26:27.987Z
@BradBell Shall I re-ask the 2nd part to the question about not seeing entry/asset/category lists in the CP as a new question?
Boxhead
CC BY-SA 3.0
2015-09-22T21:24:37.570Z
The only reason you'd get that error is if something required was missing from `$_POST`, so I'd still suspect some `.htaccess` weirdness. Or maybe mod_security or Suhosin.
Brad Bell
<control-panel><url><error>
Control Panel URLs being rewritten to use index.php?p=admin/
# Control Panel URLs being rewritten to use index.php?p=admin/

(Asked by: username_0 on 2015-09-22)

All of our control panel URLs are being rewritten to show index.php?p=admin/***
While this isn't a problem in itself we can't determine why it's happening when the frontend of the website itself is writing the URLs cleanly and correctly without the index.php?p= 
We have in our .htaccess file

  RewriteEngine On

  # Send would-be 404 requests to Craft
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_URI} !^/(favicon\.ico|apple-touch-icon.*\.png)$ [NC]
  RewriteRule (.+) index.php?p=$1 [QSA,L]


There are no other Rewrites happening.
A possibly related issue we're seeing is that there are no entries, assets or categories listing in the control panel. Looking through the logs I can see the following
2015/09/22 16:55:23 [error] [exception.Craft\HttpException.400] exception 'Craft\HttpException' with message 'Param “elementType” doesn’t exist.' in /var/www/vhosts/mysite.org/httpdocs/craft/app/services/HttpRequestService.php:586
Stack trace:
#0 /var/www/vhosts/mysite.org/httpdocs/craft/app/controllers/BaseElementsController.php(50): Craft\HttpRequestService->getRequiredParam('elementType')
#1 /var/www/vhosts/mysite.org/httpdocs/craft/app/controllers/ElementIndexController.php(68): Craft\BaseElementsController->getElementType()
#2 /var/www/vhosts/mysite.org/httpdocs/craft/app/framework/web/CWebApplication.php(281): Craft\ElementIndexController->init()
#3 /var/www/vhosts/mysite.org/httpdocs/craft/app/etc/web/WebApp.php(784): CWebApplication->runController('elementIndex/ge...')
#4 /var/www/vhosts/mysite.org/httpdocs/craft/app/etc/web/WebApp.php(276): Craft\WebApp->_processActionRequest()
#5 /var/www/vhosts/mysite.org/httpdocs/craft/app/framework/base/CApplication.php(184): Craft\WebApp->processRequest()
#6 /var/www/vhosts/mysite.org/httpdocs/craft/app/index.php(62): CApplication->run()
#7 /var/www/vhosts/mysite.org/httpdocs/index.php(40): require_once('/var/www/vhosts...')
#8 {main}
REQUEST_URI=/index.php?p=admin/actions/elementIndex/getElements
HTTP_REFERER=http://mysite.org/index.php?p=admin/entries/pages
---
2015/09/22 16:55:23 [error] [application] Param “elementType” doesn’t exist.

******************************************************************************************************

We do have PATH_INFO installed and enabled on the server.
Craft Pro 2.4.2692
Any help would be much appreciated.
Many thanks

**Tags:** control-panel, url, error

> **Comments:**
> **username_1**: Sounds like a dupe? Try this: https://craftcms.stackexchange.com/questions/4386/url-rewrites-not-working-return-apache-404s/4387#4387  
> **username_0**: Hi @BradBell I don't think it's the same problem. My .htaccess file is being used (if I put invalid apache config settings in there it breaks the whole site). Also I'm only seeing problems in the Control Panel, the sites front-end is working a treat!  
> **username_1**: You sure there's no parent `.htaccess` file above Craft's? The rules will inherit from each other.  
> **username_0**: My bad, I was editing a staged version of the general.php config file. Adding 'omitScriptNameInUrls' => true fixed the URLs (must have cached false at some point). We're still experiencing trouble loading entries/assets/categories in the CP though. Any thoughts?  
> **username_0**: @BradBell Shall I re-ask the 2nd part to the question about not seeing entry/asset/category lists in the CP as a new question?  
> **username_1**: The only reason you'd get that error is if something required was missing from `$_POST`, so I'd still suspect some `.htaccess` weirdness. Or maybe mod_security or Suhosin.  

---

## 2 answers

### Answer by username_2 on 2015-09-22. Score: 0 | Accepted answer

Have you tried adding `'omitScriptNameInUrls' => true,` to your `general.php` settings?

<http://buildwithcraft.com/docs/config-settings#omitScriptNameInUrls>

> **Comments:**
> **username_0**: Hi @username_2, I've set that to true aswell as 'usePathInfo' => true but not seeing any change.  
> **username_0**: Hi @username_2, you were right about the omitScriptNameInUrls setting. That fixed the URLs but we're still seeing issues with no entry/asset/category lists loading in the CP. Any thoughts?  

---

### Answer by username_0 on 2015-09-23. Score: 1

With regard to the 2nd part of the original question, whereby no entry, asset, category or user lists were display, this turned out to be a post\_max\_size issue in the php.ini config. It had been incorrectly set to 64**MB** rather than 64**M**.

> **Comments:**
> **username_2**: Interesting find. Glad you got it sorted!  

---

