Reputation: 537
Is there a way to REMOVE a DIV of the master page? not hide, there are some hyperlinks in the div, so I want to remove them from the code as well. thanks
Upvotes: 0
Views: 1913
Reputation: 10012
You could do the following:
<div id="random_name" runat="server" visible="false">
content
</div>
That will allow you to hide the div, but also from the .net show & hide it as well using.
random_name.visible = true
The use of Visible, doesn't just hide it from the view but show it in the code, it completely hides it, not view able by the client at all.
For changing content of master page from child page check out my answer from:
Disable Hyperlink of Master page from content page
Upvotes: 2
Reputation: 16708
By using HTML DOM you can actually remove any element you want. You need to use JavaScript or jQuery to achieve this.
var div = document.getElementById("task_row_" + taskId); div.parentNode.removeChild(div);
Reference: Remove DIV tag using Javascript or Jquery
Upvotes: 2