5

I have a few static html pages of content. I want to make an index page that has two div's One for a sidebar menu and one to hold content. When one of the menu links in the sidebar is clicked I want to load one of the other static html pages into the content div.

I just cant find any documentation that shows how to do this, so i'm not even sure if it's possible. Can anyone help?

2 Answers 2

6

You can also use ng-view to setup routes that will load your templates into your div. It's pretty straight forward, and there's a good example @ https://docs.angularjs.org/api/ngRoute/directive/ngView

Sign up to request clarification or add additional context in comments.

Comments

4

Use ng-include:

<ng-include
       src="{string}"
       [onload="{string}"]
       [autoscroll="{string}"]>
</ng-include>

http://docs.angularjs.org/api/ng.directive:ngInclude

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.