# Secure includes + more...?

**URL:** <https://forum.kirupa.com/t/secure-includes-more/241590>\
**Category:** programming\
**Created:** [October 15, 2007, 10:27pm UTC](https://forum.kirupa.com/t/secure-includes-more/241590 "2007-10-15T22:27:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![webreforms](https://avatars.discourse-cdn.com/v4/letter/w/91b2a8/32.png) [@webreforms](https://forum.kirupa.com/u/webreforms)\
**Post date:** [October 15, 2007, 10:27pm UTC](https://forum.kirupa.com/t/secure-includes-more/241590/1 "2007-10-15T22:27:09Z")

</div>

Hey!

Heres the situation:

I have a website. In this website, I have the following structure:

```auto
folder1/folder2/folder4/index.html
folder1/folder3/folder5/index.html

```

OR

```auto
folder1
  |- folder 2
      |- folder 4
          |- index.html
  |- folder 3
       |- folder 5
          |- index.html

```

So. I need to write a script that will be able to do this:  
Include /folder1/folder2/folder4/index.html or /folder1/folder3/folder5/index.html.

I will have a few folders in folder 3/5…

How can I do this?

I have seen scripts to include from one source, but how do I gain the ability to include from either source?

I would think the url should be something like viewer.php?class=folder2&id=folder4 but I have no idea…

Would appreciate any help…
