0

i tried to remove index.php from my url in codeigniter project hosted on azure server.if i manually removed index.php from url its showing "The resource you are looking for has been removed, had its name changed, or is temporarily unavailable." following is my .htaccess file

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* /index.php/$0 [PT,L]

my config file

$config['base_url'] = 'http://myapp.azurewebsites.net/';
$config['index_page'] = '';
$config['uri_protocol'] = 'REQUEST_URI';
3
  • 2
    Possible duplicate of Remove index.php in Codeigniter URL Commented Mar 19, 2017 at 11:40
  • i used .htaccess as per above link suggested but it still showing "The resource you are looking for has been removed, had its name changed, or is temporarily unavailable." Commented Mar 19, 2017 at 12:07
  • add "on Azure server" in your title and people wont be voting down so quickly Commented Mar 20, 2017 at 11:44

1 Answer 1

2

Basically, in Azure Web App you could add Default documents via the Azure portal to achieve this.

  1. In the Azure Portal, open the blade for the web app.
  2. Click Application Settings.
  3. Add index.php to Default documents list.

enter image description here

BTW, Azure uses IIS (not Apache) to host your application, so the .htaceess file doesn't work in Azure Web App.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.