hello again... I need to create a link on one page (my home page) that links directly to a image on another page already containing multiple images. Thought I knew how to do it...by creating an anchor; & my code looks like this: <a href="theOtherPage.html#PHOTO.png">IMAGE SUBJECT</a> HTML: but it doesn't work. Even tried the forward slash after the page id: <a href="theOtherPage.html/#PHOTO.png">IMAGE SUBJECT</a> HTML: but that doesn't work either. When the user clicks the link, I want the specific image to show up dead center (which I thought was an anchor)...anyone have any idea what I'm doing wrong? thanx, mark4man
Hi. I believe it should work even if the image has an id="PHOTO.png" (same as name of the image itself). It will be visible when link clicked, but not as dead center. Well, if you also own the other page... you could make the image a bit centered: make a wrapper for this image, make the image centered, relative to its wrapper, and make this wrapper to have the id="PHOTO.png" instead? Just an idea Hendra
No...sorry...didn't explain myself correctly...the image in question is already centered/positioned correctly on that 2nd page...don't need help w/ that...it's the link itself, not jumping to the image...the page is here: http://www.moonjams.net/events7.html I need to create links on my home page that go directly to *each* image on that 2nd page you see (there's 2 there now, but there will be more). thanx, mark4man
Yes...both links I created take you to the top of the Events page, instead of the images themselves. That's ok for the 1st event image, which is located at the top of the page, but not the rest
Same principle man... for any regular HTML pages. Stupid question but perhaps just show me how you'd make link on homepage for 2nd image on events page... specifically? <a href="events.html#Layer8">IMAGE SUBJECT</a> or <a href="events.html#RBTR.jpg">IMAGE SUBJECT</a> ?
hdewantara... The second one...to the image file itself (that's the way I did it, anyway). So...is that what the error is...do I instead need to direct it to the div? btw...ftm...thanx very much for helping me...I appreciate it; & everyone on my org's website committee appreciates it (as will the entire org soon). mark4man
hdewantara...FOLLOW UP... oh, man...missed that entirely...you already sorta indicated that in the prior post...missed it...will try now. thanx again, mark4man
Cool To be precise,... to any elements which has id attribute (see more in here: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a). Cheers, Hendra D.
Hendra D... It works (anchoring the 'div')...thanx! What's happening is, the referenced div appears at the top of the page. Keeping in mind that all the images on that page are already centered horizontally (left to right), is there any way to code the anchor so as to have the image in question also appear centered vertically (top to bottom)? (this would be the final piece to the puzzle). thanx again, mark4man