Welcome Guest, Not a member yet? Register   Sign In
Return Url
#1

[eluser]Gerep[/eluser]
Hi guys, a very basic question. How do I set a return URL?

I'm trying to send it as parameter like:

Code:
<a href="&lt;?php echo base_url();?&gt;cliente/login/url/www.teste.com.br" class="compre ntip" title="Faça Login para comprar" rel="">compre agora</a><

Where url will be my parameter and "www.teste.com.br" will be the url to redirect to.

But it returns me a error:

Code:
404 Page Not Found
The page you requested was not found.

Any help will be appreciated.
#2

[eluser]Cristian Gilè[/eluser]
Index.php is missing. Do you remove index.php from urls? Check also for controller and method names correctness.

Alternative way to build the url:

Code:
<a href="&lt;?php echo site_url('cliente/login/url/www.teste.com.br'); ?&gt;" class="compre ntip" title="Faça Login para comprar" rel="">compre agora</a>


Cristian Gilè
#3

[eluser]Gerep[/eluser]
Problem not solved =(

I'm using the .htaccess to take care of index.php

When I take the url/www.teste.com.br from the url, it loads the cliente controller correctly but not with the full url.
#4

[eluser]Gerep[/eluser]
Problem now solved =)

I was trying to work with the index method of my controller so I did not add the method on the URL and that was my mistake.

Code:
cliente/index/url/www.teste.com.br

NOT

Code:
cliente/url/www.teste.com.br

Stupid mistake, I thought because the index method was automatically loaded there was no need to call it.

Thanks for your help Cristian Gilè




Theme © iAndrew 2016 - Forum software by © MyBB