An html page that displays data from other html pages

Hi all.

I am trying to brainstorm the following:


Part One of my question:
I have a manual with various policies. Each policy has two options: Internal and External.

I would like to have a policy have one html page, so if I have 3 policies there will be 3 html pages. Is there a way to have one html page display all the policies which are in different html pages.

For example:

Policy 1: No running (Internal) --> Html Page 1

Policy 2: No screaming (Internal) --> Html Page 2

Policy 3: No sleeping (External) --> Html Page 3

So let's say I want to have an option to see all of the html pages into one, so that i can make one single print out, instead of 3.

Policy 1: No running (Internal)
Policy 2: No screaming (Internal and External)
Policy 3: No sleeping (External)

Part Two of my question:

As you can see some policies will be internal, external or both. I would like to have one html to show all internal policies, and a separate to include all external policies. How can I accomplish this? Are smart tags the answer or to keep all this data in a database?

I plan to store these html pages in Sharepoint will this be a problem, if it is then i'd just save each html page in the webpage folder. Thanks in advance!
printmediaAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

PreeceCommented:
You could simply have all policies on one page, and show/hide policies as needed.

Preece
PreeceCommented:
I just put this together and it may server as a starting point if the idea is practical in your situation:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>
<head>
<title>Untitled</title>
<script language="JavaScript" type="text/javascript">
<!--
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
function ShowAll()  {
  var elements=document.getElementsByTagName("tr");
       for(var i = 0; i < elements.length; i++) {
        elements.item(i).style.display = "";
      }
}
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
function HideRow(tr)  {
  //alert("yep");
  var row=document.getElementById(tr);
      row.style.display = "none";

}
//-->
</script>

</head>
<body>
  <input type=button value='show all' onclick="javascript: ShowAll();">

  <table border=1 cellspacing=0 cellpadding=2>
    <tr>
      <td>&nbsp;</td>
      <td>Policy #</td>
      <td>Name</td>
      <td>Type</td>
      <td>Description</td>
    </tr>      
    <tr id="tr_1">
      <td><input type=checkbox onclick="javascript: HideRow('tr_1');"></td>
      <td>0001</td>
      <td>No Running</td>
      <td>Internal</td>
      <td>Abslolutely no running is permitted without shoes on.</td>
    </tr>      
    <tr id="tr_2">
      <td><input type=checkbox onclick="javascript: HideRow('tr_2');"></td>
      <td>0002</td>
      <td>Internal</td>
      <td>No screaming</td>
      <td>Screaming is not permitted unless everyone in the room has been issued earplugs.</td>
    </tr>      
    <tr id="tr_3">
      <td><input type=checkbox onclick="javascript: HideRow('tr_3');"></td>
      <td>0003</td>
      <td>External</td>
      <td>No sleeping</td>
      <td>Sleeping is not allowed unless you have a warm enough blanket and a pillow.</td>
      <td></td>
    </tr>      
  </table>
</body>
</html>


Preece
PreeceCommented:
Here is another example without the use of tr id's:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>
<head>
<title>Untitled</title>
<script language="JavaScript" type="text/javascript">
<!--
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
function ShowAll()  {
  var elements=document.getElementsByTagName("tr");
       for(var i = 0; i < elements.length; i++) {
        elements.item(i).style.display = "";
      }
}
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
//function HideRow(tr)  {
//  //alert("yep");
//  var row=document.getElementById(tr);
//      row.style.display = "none";
//
//}
//-->
</script>

</head>
<body>
  <input type=button value='show all' onclick="javascript: ShowAll();">

  <table border=1 cellspacing=0 cellpadding=2>
    <tr>
      <td>&nbsp;</td>
      <td>Policy #</td>
      <td>Name</td>
      <td>Type</td>
      <td>Description</td>
    </tr>      
    <tr>
      <td><input type=checkbox onclick="javascript: this.parentNode.parentNode.style.display='none';"></td>
      <td>0001</td>
      <td>No Running</td>
      <td>Internal</td>
      <td>Abslolutely no running is permitted without shoes on.</td>
    </tr>      
    <tr>
      <td><input type=checkbox onclick="javascript: this.parentNode.parentNode.style.display='none';"></td>
      <td>0002</td>
      <td>Internal</td>
      <td>No screaming</td>
      <td>Screaming is not permitted unless everyone in the room has been issued earplugs.</td>
    </tr>      
    <tr>
      <td><input type=checkbox onclick="javascript: this.parentNode.parentNode.style.display='none';"></td>
      <td>0003</td>
      <td>External</td>
      <td>No sleeping</td>
      <td>Sleeping is not allowed unless you have a warm enough blanket and a pillow.</td>
      <td></td>
    </tr>      
  </table>
</body>
</html>


Preece

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

printmediaAuthor Commented:
Please excuse the question but what are tr ids?
ThinkPaperIT ConsultantCommented:
tr ids = table row IDs.
In Preece's example they're: <tr id="tr_3">

With table row IDs you can define ids for each row and do a multitude of stuff with it (hide/show/formatting) You can make one row blue and another green if you wanted to.
printmediaAuthor Commented:
What if I have policies on different html pages because they reside on different areas of the intranet site, and I just want to have one html page that brings all of these policies on different html pages into one major html page. Is that possible?
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Development Software

From novice to tech pro — start learning today.