Welcome Guest, Not a member yet? Register   Sign In
uri problem
#1

[eluser]alberta[/eluser]
i have problem in uri , i am using this

Code:
<a href='projects/index/{id}' rel="lyteframe">{code}</a>

first time it goes correctly, and uri becomes

Code:
http://localhost/project/index.php/projects/index/5

when i second time clink on it then uri becomes, then it concatenates with previous one and becomes

Code:
http://localhost/project/index.php/projects/index/5/projects/index/6

can some one tell me how to get rid of this ??

Thanks
#2

[eluser]n0xie[/eluser]
Auto load URI helper class and try this:
Code:
<a href='&lt;?php echo site_url(); ?&gt;projects/index/{id}' rel="lyteframe">{code}</a>
#3

[eluser]TheFuzzy0ne[/eluser]
You need to prefix you're URL with a forward slash:
Code:
<a href='/projects/index/{id}' rel="lyteframe">{code}</a>

EDIT: ...Or do what n0xie suggested Big Grin
#4

[eluser]mTuran[/eluser]
Firstly setup project.loc address for developing app:

http://www.elxis.org/guides/developers-g...hosts.html

Then link from root like that:

Code:
<a href='/projects/index/{id}' rel="lyteframe">{code}</a>

When you upload to your web site, you have not to change anything i will be not use any extra helper.

I think this is best way.




Theme © iAndrew 2016 - Forum software by © MyBB