Welcome Guest, Not a member yet? Register   Sign In
url helper
#1

[eluser]osgaldor[/eluser]
I'm a little lost with using the url helper. I have a .htaccess file removing the index.php file from the url, but I'm not clear how to correctly use the anchor() function. I'm just testing a dummy controller and view, I want a link to simply go back to the same directory, but every time I put a segmented url in the parameter list, I get a 404 error when I click it. What is that segment argument relative to?
#2

[eluser]osgaldor[/eluser]
How do I call the default method for my class with the url helper?
#3

[eluser]InsiteFX[/eluser]
Code:
anchor('controller/method', 'text', $attributes);
#4

[eluser]osgaldor[/eluser]
Does this method account for the parts removed by .htaccess? I keep getting 404 errors.
#5

[eluser]osgaldor[/eluser]
My default controller is at Dorjeboard/__construct() but that 404's.
#6

[eluser]osgaldor[/eluser]
My full app path is something like localhost/codeigniter/CodeIgniter_2.0.1/Dorjeboard/__construct, but I cannot figure out how to send that to the url helper to reload the default constructor. I have my basepath and everything set in the config dir.
#7

[eluser]InsiteFX[/eluser]
Try:
Code:
anchor('Dorjeboard/index', 'text', $attributes);

You need a index function because that is the default that is called when going to a Controller.





Theme © iAndrew 2016 - Forum software by © MyBB