понедельник, 10 февраля 2014 г.

Скрыть текст в блоггере

Вот интересный способ скрыть дополнительную информацию в кнопочку на блоггере. 

<div style="margin: 5px 5px 5px;">
<div class="smallfont" style="margin-bottom: 2px; text-align: center;">
<span style="color: red;"><b>ПРАВИЛА КЛУБА ДРУЗЕЙ :</b></span> <input onclick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = ''; this.innerText = ''; this.value = 'Свернуть'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Прочитать'; }" style="font-size: 14px; margin: 0px; padding: 0px; width: 100px;" type="button" value="Прочитать" /> </div>

<div class="alt2" style="-moz-background-clip: -moz-initial; -moz-background-inline-policy: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-size: auto auto; background-attachment: scroll; background-color: white; background-image: none; background-position: 0% 50%; background-repeat: repeat; border: 0px inset; line-height: 1.5em; margin: 0px; padding: 6px;">
<div style="display: none;">
СКРЫТЫЙ ТЕКСТ
<br/>
</div>
</div>
</div>
Код нужно вставлять в запись/страницу в режиме HTML