User Profile
Collapse
-
That is correct doc. The scrolling is that way intentionally as it just seems more natural to have the scrollbar the full height of the browser window as opposed to right next to the content like a frames page. (it actually took some sweat to make it behave this way!) Now the challenge, as you discovered above is to make anchors work "properly". That is..not to end up under the header. -
Yes Doc, it solves the "Back to the top" problem. Thank you it is just that I was not concerned about that., but rather in the other direction. I have modified the test page for you to see what I men. Click in one of the two test links at the top and you will see the problem. Thanks
Test FileLeave a comment:
-
Frinny. who ro what is "the Doc"? only you, dormilich and dhr.., have replied. I tried all suggestions here. Some pointed out errors in coding (thank you) which I have correcd (if not posted) but those where irrelevant to the problem.
You suggested a spacer. and I do have one. the problem is the anchors.
I reposted there because even though this page currently has no JavaScript. I suspect that is where the answer l...Leave a comment:
-
Thanks Ramanan, this gives me the basic mechanism for doing this. As far as implementation I suppose I need to somehow dynamically get the current position of all anchors on the page and then programatically change them to that value + 300px(or whatever number I need)
Having said that I have no idea how one does that...but I will start searching the web for the first part (get the current position of all anchors on the page)
and...Leave a comment:
-
Thank you all.This page has no JavaScript. The reason I posted on the JavaScript forum originally is because I suspect that is where the answer lies.
The "ankor" and other errors where introduced as I tried to implement Frinalave's first suggestion which I misinterpreted. but they are irrelevant. the point is that the page's anchors work correctly, I just need them to scroll to a position about 130px from the top (right below...Leave a comment:
-
Question about anchors
To define my question I need to establish an example:
Let's say I have a web page (MYPAGE.HTML) and
this webpage is constrained in width.
This web page has 200 lines of text.
I have an anchor on line 30
and a link on the first line that points to that anchorCode:<a name="myanchor">
If I click on the link the webpage will scroll...Code:<a href="#myanchor">go to anchor</a>
-
here it is
The problem is with "in page links". they end up under the header.
Good point on how to ask a question. I will try to be more thoroughLeave a comment:
-
hmmm...Perhaps I did not phrase my question correctly.
When I click on a link with an anchor the browser puts the line where the anchor is at the top of the browser window.
I instead want it to put that line about 30 pixels down from the top of the browser window.
Now I can see how I MIGHT be able to make a style for the anchor where it is always 30px above where it is places (margin relative -30px?) or something like that....Leave a comment:
-
Change location of anchor target by a few pixels
I need all of my anchors to go about 30 pixels above where the anchor tags are placed (there is a floating piece of interface at the top of the page) Is this possible?
Thank you -
Learned a lot with just this question!!!
Eval in all languages is evil, but it is always good to know how it works,
The first response answers my question exactly as I posted it and shows me how to properly use eval..thank you.
I will be using the non-eval sample however as you all recommend.
Thank you all very much.Leave a comment:
-
Dynamic object names
I know so little about javascript that I can't even articlulate the question properly. So, instead here is what I am trying to do.
[CODE=javascript]
var i = document.myform .myselectfield. selectedIndex;
var sel = document.myform .myselectfield. options[i].text;
var i=0
while (i<=9)
{
eval("document. xform" + i + ".custom.value" ) = sel;
i=i+1
}[/CODE]
...
No activity results to display
Show More
Leave a comment: