Ошибка создания шорткода
-
wordpress при активации плагина шорткода выдал такое предупреждение
«Плагин создал 3 символа неожиданного вывода при активации. Если возникнет ошибка “headers already sent” с RSS-лентами или иные проблемы, то попробуйте деактивировать или удалить этот плагин.»
сам плагин:
<?php /* Plugin Name: Шорткод */ add_shortcode ( 'thanks', 'my_shortcode_thanks' ); function my_shortcode_thanks ( $attr, $content = null ) { return <<<HTML <div class='container'> <section class='ac-container'> <div> <input id='ac-1' name='accordion-1' type='checkbox' /> <label for='ac-1'>О нас</label> <article class='ac-small'> <p>Well, the way they make shows is, they make one show. That show's cato make more shows.</p> </article> </div> <div> <input id='ac-2' name='accordion-1' type='checkbox' /> <label for='ac-2'>Наши работы</label> <article class='ac-medium'> <p>I did, then some kid with a nail showed me I was living in his world, a world where chaos rules not order </p> </article> </div> <div> <input id='ac-3' name='accordion-1' type='checkbox' /> <label for='ac-3'>Ссылки</label> <article class='ac-large'> <p>Now, I don't know exactly when we turned on each other, but I know that seven of us survived the slide... </p> </article> </div> <div> <input id='ac-4' name='accordion-1' type='checkbox' /> <label for='ac-4'>Контакты</label> <article class='ac-large'> <p>You see? It's curious. Just as a matter of deductive logic. </p> </article> </div> </section> </div> <style> a{ color: #333; text-decoration: none; } .container{ width: 100%; position: relative; text-align: center; } .clr{ clear: both; } .ac-container{ width: 600px; margin: 10px auto; text-align: center; } .ac-container label{ font-family: 'Arial Narrow', Arial, sans-serif; font-size: 13px; position: relative; z-index: 20; display: block; height: 30px; cursor: pointer; color: #777; text-shadow: 1px 1px 1px rgba(255,255,255,0.8); line-height: 33px; background: #ffffff; background: -moz-linear-gradient(top, #ffffff 1%, #eaeaea 100%); background: -webkit-gradient(linear, left top, left bottom, color-stop(1%,#ffffff), color-stop(100%,#eaeaea)); background: -webkit-linear-gradient(top, #ffffff 1%,#eaeaea 100%); background: -o-linear-gradient(top, #ffffff 1%,#eaeaea 100%); background: -ms-linear-gradient(top, #ffffff 1%,#eaeaea 100%); background: linear-gradient(top, #ffffff 1%,#eaeaea 100%); filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#eaeaea',GradientType=0 ); box-shadow: 0px 0px 0px 1px rgba(155,155,155,0.3), 1px 0px 0px 0px rgba(255,255,255,0.9) inset, 0px 2px 2px rgba(0,0,0,0.1); } .ac-container label:hover{ background: #fff; } .ac-container input:checked + label, .ac-container input:checked + label:hover{ background: #c6e1ec; color: #3d7489; text-shadow: 0px 1px 1px rgba(255,255,255, 0.6); box-shadow: 0px 0px 0px 1px rgba(155,155,155,0.3), 0px 2px 2px rgba(0,0,0,0.1); } .ac-container label:hover:after, .ac-container input:checked + label:hover:after{ content: ''; position: absolute; width: 24px; height: 24px; right: 13px; top: 7px; background: transparent url(../images/arrow_down.png) no-repeat center center; } .ac-container input:checked + label:hover:after{ background-image: '\029'; } .ac-container input{ display: none; } .ac-container article{ background: rgba(255, 255, 255, 0.5); margin-top: -1px; overflow: hidden; height: 0px; position: relative; z-index: 10; -webkit-transition: height 0.3s ease-in-out, box-shadow 0.6s linear; -moz-transition: height 0.3s ease-in-out, box-shadow 0.6s linear; -o-transition: height 0.3s ease-in-out, box-shadow 0.6s linear; -ms-transition: height 0.3s ease-in-out, box-shadow 0.6s linear; transition: height 0.3s ease-in-out, box-shadow 0.6s linear; } .ac-container article p{ font-style: italic; color: #777; line-height: 23px; font-size: 14px; padding: 20px; text-shadow: 1px 1px 1px rgba(255,255,255,0.8); } .ac-container input:checked ~ article{ -webkit-transition: height 0.5s ease-in-out, box-shadow 0.1s linear; -moz-transition: height 0.5s ease-in-out, box-shadow 0.1s linear; -o-transition: height 0.5s ease-in-out, box-shadow 0.1s linear; -ms-transition: height 0.5s ease-in-out, box-shadow 0.1s linear; transition: height 0.5s ease-in-out, box-shadow 0.1s linear; box-shadow: 0px 0px 0px 1px rgba(155,155,155,0.3); } .ac-container input:checked ~ article.ac-small{ height: 140px; } .ac-container input:checked ~ article.ac-medium{ height: 180px; } .ac-container input:checked ~ article.ac-large{ height: 230px; } </style> HTML; } ?>
Просмотр 13 ответов — с 1 по 13 (всего 13)
Просмотр 13 ответов — с 1 по 13 (всего 13)
- Тема «Ошибка создания шорткода» закрыта для новых ответов.