Join the Stack Overflow Community
Stack Overflow is a community of 6.6 million programmers, just like you, helping each other.
Join them; it only takes a minute:
Sign up

I have two HTML pages. One HTML page has all divs made with specific IDs. In another page, I am writing ng-include with a variable, which is a $scope.something in the controller. And on this

First HTML page looks like this.

<ng-include src="element"></ng-include>

The controller looks like this:

$scope.element = 'secondhtml.html' + divId;

Second HTML:

<div id="first">abc</div>
<div id="second">xyz</div>

On this the whole second HTML loads away. How can I target just a specific div from the secondhtml page? I don't want to create multiple HTML pages. Please help me out. Thank you.

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.