Mam pewien problem z wordpressem. Chciałbym aby na stronie kategorii pojawił się pod tytułem wpisu plik załącznika.
Kod pliku który, jak mi się wydaje, odpowiada za wygląd tych podstron wklejam poniżej. Funkacja która odpowiada za wyświetlanie downloadu to:
<?php da_display_download_attachments(); ?>
jednak kiedy wstawię ją tak jak niżej ( linia 46 ) pliki na stronie pojawiają się w dwóch miejscach: http://www.probamikrofonu.pl/test/?cat=11 . Chciałbym aby div "Załączniki do pobrania" był tylko pod tytułem. Co robię źle ?
<?php // $style = 'post' or 'block' or 'vmenu' or 'simple' function theme_wrapper($style, $args){ $func_name = "theme_{$style}_wrapper"; if (function_exists($func_name)) { call_user_func($func_name, $args); } else { theme_block_wrapper($args); } } function theme_post_wrapper($args = '') { $args = wp_parse_args($args, 'id' => '', 'class' => '', 'title' => '', 'heading' => 'h2', 'thumbnail' => '', 'before' => '', 'content' => '', 'after' => '' ) ); if (theme_is_empty_html($title) && theme_is_empty_html($content)) return; if ($id) { $id = ' id="' . $id . '"'; } if ($class) { $class = ' ' . $class; } ?> <div class="wto-box-body wto-post-body"> <div class="wto-post-inner wto-article"> <?php if (!theme_is_empty_html($title)){ } ?> <div class="wto-postcontent"> <?php da_display_download_attachments(); ?> <!-- article-content --> <?php ?> <!-- /article-content --> </div> <div class="cleared"></div> <?php ?> </div> <div class="cleared"></div> </div> </div> <?php } function theme_simple_wrapper($args = '') { $args = wp_parse_args($args, 'id' => '', 'class' => '', 'title' => '', 'heading' => 'div', 'content' => '', ) ); if (theme_is_empty_html($title) && theme_is_empty_html($content)) return; if ($id) { $id = ' id="' . $id . '"'; } if ($class) { $class = ' ' . $class; } if ( !theme_is_empty_html($title)) echo '<'.$heading.' class="wto-widget-title">' . $title . '</'.$heading.'>'; } function theme_block_wrapper($args) { $args = wp_parse_args($args, 'id' => '', 'class' => '', 'title' => '', 'heading' => 'div', 'content' => '', ) ); if (theme_is_empty_html($title) && theme_is_empty_html($content)) return; if ($id) { $id = ' id="' . $id . '"'; } if ($class) { $class = ' ' . $class; } $begin = <<<EOL <div class="wto-box wto-block{$class}"{$id}> <div class="wto-box-body wto-block-body"> EOL; $begin_title = <<<EOL <div class="wto-bar wto-blockheader"> <$heading class="t"> EOL; $end_title = <<<EOL </$heading> </div> EOL; $begin_content = <<<EOL <div class="wto-box wto-blockcontent"> <div class="wto-box-body wto-blockcontent-body"> EOL; $end_content = <<<EOL <div class="cleared"></div> </div> </div> EOL; $end = <<<EOL <div class="cleared"></div> </div> </div> EOL; if ($begin_title && $end_title && !theme_is_empty_html($title)) { } } function theme_vmenu_wrapper($args) { $args = wp_parse_args($args, 'id' => '', 'class' => '', 'title' => '', 'heading' => 'div', 'content' => '', ) ); if (theme_is_empty_html($title) && theme_is_empty_html($content)) return; if ($id) { $id = ' id="' . $id . '"'; } if ($class) { $class = ' ' . $class; } $begin = <<<EOL <div class="wto-box wto-vmenublock{$class}"{$id}> <div class="wto-box-body wto-vmenublock-body"> EOL; $begin_title = <<<EOL EOL; $end_title = <<<EOL EOL; $begin_content = <<<EOL <div class="wto-box wto-vmenublockcontent"> <div class="wto-box-body wto-vmenublockcontent-body"> EOL; $end_content = <<<EOL <div class="cleared"></div> </div> </div> EOL; $end = <<<EOL <div class="cleared"></div> </div> </div> EOL; if ($begin_title && $end_title && !theme_is_empty_html($title)) { } } ?>