HTML site having links to the other site to be opened in the same page -


i want create pure html website. pages of site contain left side menu having same content. menu have links other pages of different site. want links opened in right side of same page i.e. master page concept. don't want use other language other html.

from comments:

eg. suppose there main.html i.e. main page have 2 iframes 1 left side menu panelwhich have source page iframe_source.html. iframe_source.html page have links sites google.com or w3schools.com. on right side of main.html have second frame or iframe i.e. container frame. want when user clicks on links google or w3schools site sites should opened in right side container frame.

could please guide me on this?

the src attribute specifies url (web address) of iframe page.

an iframe can used target frame link.the target attribute of link must refer name attribute of iframe.

plunkr

style.css:

.box{     width:50%;     float:left;  } 

index.html:

<!doctype html> <html>    <head>     <link rel="stylesheet" href="style.css">     <script src="script.js"></script>   </head>     <body>  <div class="box"> <iframe src="menu.html" name="iframe_a" frameborder="1" scrolling="no" width="100%" height="512" >   <p>your browser not support iframes.</p> </iframe> </div> <div class="box"> <iframe name="iframe_b" frameborder="1" scrolling="no" width="100%" height="512">   <p>your browser not support iframes.</p> </iframe> </div> </body>  </html> 

menu.html:

<html>   <body>     <div>       <ul>         <li><a href="http://www.w3schools.com" target="iframe_b">w3schools.com</a></li>         <li><a href="https://www.bing.com/" target="iframe_b">search tool</a></li>       </ul>     </div>   </body> </html> 

Comments