CodeIgniter Forums
getting index.php 2X in url - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: getting index.php 2X in url (/showthread.php?tid=2109)



getting index.php 2X in url - El Forum - 07-16-2007

[eluser]Unknown[/eluser]
hi folks..

im just wondering how to get rid of this 2X url.
say for example i follow the exact script from ci site,
upload.php

when i go to http://localhost/code/upload.php
after submit, i get a 404 page and url becomes like this.
http://localhost/code/upload/index.php/upload/do_upload

how do i get rid of "/index.php/upload" ??

thanks.


getting index.php 2X in url - El Forum - 07-17-2007

[eluser]the real rlee[/eluser]
Looks like a path issue. I assume your doing something like:
Code:
<form action="/upload/do_upload/" >

Instead use the form helper to make sure the link to your controller function is relative:
Code:
echo form_open('upload/do_upload');