Hiding elements on a page

The other day I had a user ask about removing the (More Links) wording from a Link List Web Part. Basically she had but the view into Summary View and with the number of items that appears it also states at the bottom to click to see more links. But all her links were showing up so she just wanted that removed.

Being my normal helpful self I seen no reason to argue that it didn’t matter if it was on the page or not and searched for a quick script to accomplish this.

 

The code is as follows

[code]

<script>

document.getElementById(“onetidMoreAnn”).innerHTML=””

</script>

[/code] 

I then called the code from a Content Editor Webpart and the More Links Disappeared.

I got the onetidMoreAnn by using the Developer Dashboard in IE and finding that links ID in attributes. I imagine you can do this for any element on a page.

Simple and I still look like a hero.

%d bloggers like this: