• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
FUNNY URL BEHAVIOUR.

#1
[eluser]joeizang[/eluser]
Hello guys,

sorry but something wired is happening to me i thought I should share. everything works fine in my CI install doing local development but i noticed that if I for example clicked on link with value of href being "controller/function" everything works fine. if i try to navigate to another page(essentially to another function inside my controller say "controller/function1", my codeigntier stacks the url. this is an eg of what it does!

"http://localhost/wayefoundation/index.php/mainpage/mainpage/programs"

I was checking the community and only CI 1.5.3 was mentioned to have some sort of bug even though i believe to check myself as well. can anyone please expalin what is happening to the url above?

Much obliged

#2
[eluser]jedd[/eluser]
[quote author="joeizang" date="1257045374"]
I was checking the community and only CI 1.5.3 was mentioned to have some sort of bug ..
[/quote]

And the version you're running is ... ?

Quote:everything works fine in my CI install doing local development but i noticed that if I for example clicked on link with value of href being "controller/function" everything works fine.

if i try to navigate to another page(essentially to another function inside my controller say "controller/function1", my codeigntier stacks the url. this is an eg of what it does!

Right.

Do you think you could show some source, say of your anchor() calls where you're generating the links that you then click on? It's much easier to fix someone's code when you can see it, rather than just hear about it.

#3
[eluser]renownedmedia[/eluser]
He's using relative links without a base href. Fo sho.

#4
[eluser]Colin Williams[/eluser]
Ugh. The CodeIgniter download page needs an entry quiz...

#5
[eluser]skunkbad[/eluser]
[quote author="Thomas Hunter" date="1257063493"]He's using relative links without a base href. Fo sho.[/quote]

He might be using relative links, or he might have a problem with .htaccess, or he may not have settings in config/config the way they need to be. Whatever the case, it shouldn't be that hard to track down the problem.

#6
[eluser]jedd[/eluser]
He/she might be doing a lot of things - but until a response is forthcoming it's probably not that useful to speculate wildly on the effectively limitless range of whacky possibilities.

Though, having said that, in my eternally humble opinion the only thing they need to do is learn [url="/wiki/How_to_ask_a_good_question"]how to ask a good question[/url]. Wink

#7
[eluser]joeizang[/eluser]
hi,

sorry I just got on line now, and I am not using relative links. I am using CI 1.7.2 but I was able to sort out my problem with the use of site_url() function. Please may i add that I am just fulfilled using CI and knowing that I can churn out site quickly. And some of us are not expert programmers but are getting there so please don't get frustrated with my school boy questions.

God bless.

#8
[eluser]Greg Aker[/eluser]
Can you please show us some code joeizang? How are you generating the link? What about a .htaccess file?

-greg


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.