I have used frameset and frames to connect 3 html pages.The problem arises when i click on link provided in any of 3 html pages ,those link only opens in their respective frames.so help me so that i can open those link on whole page rather than inside a frame
Use the attribute target=_parent in the a elements.
Where you'd usually use:
<a href="http://www.example.com">
Or to open in a new window:
<a href="http://www.example.com" target="_blank">
Instead, specify the name of your frame as the target:
<a href="http://www.example.com" target="nav">
Related
using this HTML commands in vscode:-->
<a>href="page2.html"/>page2</a>
<a>href="https://www.google.com">Google </a>
when i refresh the page it is showing web address insted of showing only link ,where we can click
to enter on specifice link address.
It is showing following result:-->
href="page2.html"/>page2
href="https://www.google.com">Google
You need to move href inside the <a> tag, like this:
page2
Google
Sooo.. I've got this navigation on the frontpage. I'm trying make it link to an anchor on another page.
www.oddfuse.com
This is the anchor link:
<a class="hover" title="Skills" href="/page#skills">
As you can see, it does not redirect to the specified page.
However it does work when typed directly into the address bar:
www.oddfuse.com/page#skills
This also works:
<a class="hover" title="Skills" href="/page">
But with the hash, I get no response whatsoever.
Any ideas on how I fix this?
Okay, so it turned out that it was the jQuery Mobile somehow messing with the anchor tags.
I needed to put data-ajax="false" in the link, and it now works perfectly. TMYK.
Found the solution here
can you try including the file extension?
i.e.
<a class="hover" title="Skills" href="/page.html#skills" />
I'm wondering if it thinks the # is part of a file name that can't be found.
If you want a link to jump a specific location on a different page, you'll need to replace #anchor with the full URL for the target page, similar to:
<a class="hover" title="Skills" href="http://oddfuse.com/page/#skills">
I am trying to open a my linked in page in a specified html frameset frame I have setup. however it wont open the link in the specified frame set, but the link is valid as I have double checked this. (I am trying to open the link in the frame named Middle)
<a href="http://www.linkedin.com/pub/xxxx-xxx-xxxxx/3a/292/26a" target="Middle">
<img src="../Images/Linkedin.png" border="0" alt="Link in with me" align="right"
onmouseover="this.src='../Images/Linkedin_Rollover.png'"
onmouseout="this.src='../Images/Linkedin.png'">
</img>
Perhaps I have missed somthing?
I have a link on one page that needs to go to a different page, but load to a specific section on that other page.
I have done this before with bootstrap but they take all the 'coding' out of it, so I need to know how to do from scratch. Here is the markup I have based on this link (not the best resource, I know): http://www.w3schools.com/html/html_links.asp
**Page One**
<a href="/academics/page.html#timeline> Click here </a>
**Page I am linking to**
<div id="timeline" name="timeline"> ... </div>
Can I do this with just HTML, or do I need some JavaScript? If I need to do it via JS, it needs to be on the target page, right?
I believe the example you've posted is using HTML5, which allows you to jump to any DOM element with the matching ID attribute. To support older browsers, you'll need to change:
<div id="timeline" name="timeline" ...>
To the old format:
<a name="timeline" />
You'll then be able to navigate to /academics/page.html#timeline and jump right to that section.
Also, check out this similar question.
You can simply use
<a href="directry/filename.html#section5" >click me</a>
to link to a section/id of another page by
To navigate to a section of another page use:
<a href="example.html#example-section>name-of-link</a>
The example.html would be the page you want to go to, and the #example-section would be the name of the id on that page that you want to navigate to.
To link from a page to another section of the page, I navigate through the page depending on the page's location to the other, at the URL bar, and add the #id. So what I mean;
This takes you #the_part_that_you_want at the page before
I tried the above answer - using page.html#ID_name it gave me a 404 page doesn't exist error.
Then instead of using .html, I simply put a slash / before the # and that worked fine. So my example on the sending page between the link tags looks like:
El Chorro
Just use / instead of .html.
To link from a page to another section just use
my first div
In my HTML, I am currently using the following BASE tag to simplify file management:
<base href="../" target="_blank" />
I am willing to add a 'top of the page' button at the bottom of a page. The following line will not work, probably because the base is one directory up.
<a id="back2top" class="button" href="#">Back to the top</a>
So I tried this instead (where the href points to the page itself):
<a id="back2top" class="button" href="fr/1_calendar.html">Back to the top</a>
However, when I click on the button, the bowser does 2 things:
- it goes to the top of the page (what I want)
- and opens a new window (tested on IE and Chrome).
Is there a way I can:
- either override BASE so that href="#" works
- or prevent the second window from opening
If you use <base href=...>, it by definition affects all relative URLs. It cannot be overridden; the only way to prevent it from affecting a URL is to use a relative URL.
So if <base href=...> is used, the only way in HTML to set up a link to the start of a document is to use one with a href specifying the absolute (full) URL of the document itself.
On the other hand, by the spec the href value in base tag must be an absolute URL. So whatever the tag does in your case is to be classified as undocumented error handling.
If you can use javascript this would work:
function goToTop(){
window.scrollTo(0,0)
return false; //prevent page from reloading
}
Your html could look like:
Back to the top
or:
<a onclick="javascript:goToTop()">Back to the top</a>