title: CodeIgniter Noob - How does the index.php file work?
body: <p>Here is my <code>views</code> directory:</p>
  
  <pre><code>-    views/
      -    home.php
      -    contact.php
      -    assets/
          -    css/
              -    main.css
  </code></pre>
  
  <p>config.php: (changing this doesn't seem to do anything)</p>
  
  <pre><code>$config['index_page'] = 'index.php';
  </code></pre>
  
  <p>routes.php:</p>
  
  <pre><code>$route['default_controller'] = "welcome";
  </code></pre>
  
  <p>When I request <code>www.example.com/index.php</code>, the default page (i.e. home.php) loads and all of the assets work. However, when I request <code>www.example.com/index.php/welcome</code> or <code>www.example.com/index.php/welcome/index</code>, the page loads but the assets don't work. The same also happens if I try to load the page from a link from the home page.</p>
  
  <p>I have no idea what index.php is for. I want to be able to just request <code>www.example.com/welcome/index</code> which will call the <code>welcome.php</code> controller and call the <code>index</code> method. <code>application/index.php</code> looks pretty important for everything to work, do I haven't deleted it, but I don't really want it. What can I do?</p>
  
  <p>Thanks.</p>