Internal Links problem |
[eluser]phpLearner[/eluser]
I am trying to use html internal links in codeigniter web application. at the top of the page I used Code: <a name='editable'></a> at the bottom of the page i used Code: <a href='#editable'>Click Here</a> When i click on the click here, it is not navigating to the top. What did i do wrong. I can post the whole code but it is way big.
[eluser]boltsabre[/eluser]
Try changing it to: Code: <a id='editable'></a> However, I doubt that that is what is causing your problems, you see internal hyperlinks using name all the time, but perhaps a super weird browser and a html5 doctype may break if you use name... worth trying anyway. Oh... maybe try changing it from an <a> tag to a <div> or something, perhaps linking from an <a> to an <a> is causing something, but again I this is more wishful thinking. Also copy and past your reference "editable" just to be 100% sure that you have the same spellings... Apart from that, I cannot think of anything else, it looks fine to me...
[eluser]TheFuzzy0ne[/eluser]
What you've got should work. The only reason I can think of that would cause it not to work, is that your page is not being parsed properly, as a result of not being formatted correctly. I suggest you try validating your HTML: http://validator.w3.org.
[eluser]phpLearner[/eluser]
I changed it Code: id='editable'. The problem is when i hover on the link it points to Code: www.expense-book.com/#editable and when i click nothing happens.
[eluser]TheFuzzy0ne[/eluser]
Are you sure it's not because your page just isn't long enough (i.e, the vertical scroll bar is not visible)? If your page does not scroll, I wouldn't expect it to do anything when you click on the hash.
[eluser]boltsabre[/eluser]
Quote:Are you sure it’s not because your page just isn’t long enough (i.e, the vertical scroll bar is not visible)? If your page does not scroll, I wouldn’t expect it to do anything when you click on the hash.That's a very good point! And the html validation is also a very good idea Quote:The problem is when i hover on the link it points toIs that the correct page? Are you already on the page www.expense-book.com? Or is it pointing to a different page from what the hyperlink is on?
[eluser]phpLearner[/eluser]
I want it to point to a name/id. Not to a hyperlink. If you have time please check this on www.expense-book.com the first page itself. Please view the source code and see. I can also post the source code but unless you can see the functionality, the problem aint be cleared. Help me.
[eluser]boltsabre[/eluser]
Okay, visited the page there is NO "click here" and there is no "editable" in your source code... not sure what you are trying to do, there is nothing to click!!! |
Welcome Guest, Not a member yet? Register Sign In |