• 12-06-2021, 12:59:14
    #1
    Arkadaşlar biraz karışık geldi

    Rica etsem kaldırabilecek varmı.

    <?php if ( (has_post_thumbnail)) { ?> bunu kaldırınca hata veriyor.

    <?php get_header(); // add header ?>  
    <!-- Begin Content -->
    <div class="wrap-fullwidth">
    
    <div class="single-content">
    <article>
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <div <?php post_class('post') ?> id="post-<?php the_ID(); ?>">
    
    <div class="media-single-content">
    
    <h1 class="article-title"><?php the_title(); ?></h1>
    <div class="meta-art">
    <div class="single-date"><?php echo get_the_date(); ?></div>
    <?php $showcase_wp_category = get_the_category(); if ($showcase_wp_category) { echo '<a href="' . get_category_link( $showcase_wp_category[0]->term_id ) . '">' . $showcase_wp_category[0]->name.'</a> ';} ?>
    <div class="single-thumb"><?php if (function_exists('thumbs_rating_getlink')) { echo thumbs_rating_getlink(); } ?></div>
    
    <!-- end .home-data -->
    </div><!-- end .meta-art -->
    <div class="clear"></div>
    
    <?php if ( function_exists( 'rwmb_meta' ) ) {
    // If Meta Box plugin is activate ?>
    <?php
    $showcase_wp_youtubecode = rwmb_meta('showcase_wp_youtube', true );
    $showcase_wp_vimeocode = rwmb_meta('showcase_wp_vimeo', true );
    $showcase_wp_images = rwmb_meta('showcase_wp_slider', true );
    $showcase_wp_hideimg = rwmb_meta('showcase_wp_hideimg', true );
    ?>
    
    <?php if(!empty($showcase_wp_images)) { ?>
    <!-- #### Single Gallery #### -->
    <div class="single-gallery">
    <?php
    $showcase_wp_images = rwmb_meta( 'showcase_wp_slider', 'type=image&size=showcase_wp_thumbnail-gallery-single' );
    foreach($showcase_wp_images as $key =>$image)
    { echo wp_kses_post("<a href='{$image['full_url']}' rel='mygallery'><img src='{$image['url']}' alt='{$image['alt']}' /></a>");
    } ?>
    </div><!-- end .single-gallery -->
    <div class="clear"></div>
    <?php } ?>
    
    <?php if(!empty($showcase_wp_youtubecode)) { ?>
    <!-- #### Youtube video #### -->
    <?php $showcase_wp_youtubeembed = '//www.youtube.com/embed/'; ?>
    <iframe class="single_iframe" width="100%" height="420" src="<?php echo esc_url($showcase_wp_youtubeembed); ?><?php echo esc_html($showcase_wp_youtubecode); ?>?wmode=transparent&amp;showinfo=0" frameborder="0" allowfullscreen></iframe>
    <?php } ?>
    
    <?php if(!empty($showcase_wp_vimeocode)) { ?>
    <!-- #### Vimeo video #### -->
    <?php $showcase_wp_vimeoembed = '//player.vimeo.com/video/'; ?>
    <iframe class="single_iframe" width="100%" height="420" src="<?php echo esc_url($showcase_wp_vimeoembed); ?><?php echo esc_html($showcase_wp_vimeocode); ?>?portrait=0" frameborder="0" allowFullScreen></iframe>
    <?php } ?>
    
    <?php if(!empty($showcase_wp_images) || !empty($showcase_wp_youtubecode) || !empty($showcase_wp_vimeocode)) { ?>
    <?php } elseif ( has_post_thumbnail()) { ?>
    <?php if(!empty($showcase_wp_hideimg)) { } else { ?>
    <?php the_post_thumbnail('showcase_wp_thumbnail-single-image'); ?>
    <?php } // disable featured image ?>
    <?php } ?>
    
    <?php } else {
    // Meta Box Plugin ?>
    <?php the_post_thumbnail('showcase_wp_thumbnail-single-image'); ?>
    <?php } ?>
    <div class="clear"></div>
    </div><!-- end .media-single-content -->
    
    <div class="entry">
    <!-- excerpt -->
    <?php if ( !empty( $post->post_excerpt ) ) : ?> <div class="entry-excerpt"><h3> <?php echo the_excerpt(); ?> </h3></div> <?php else : false; endif; ?>
    
    <?php if ( function_exists( 'rwmb_meta' ) ) {
    // If Meta Box plugin is activate ?>
    <?php
    $showcase_wp_buttonselect = rwmb_meta('showcase_wp_buttonselect', true );
    $showcase_wp_buttons = rwmb_meta('showcase_wp_buttons', true );
    ?>
    <?php if ($showcase_wp_buttonselect == 'value2') { ?>
    <div class="entry-buttons">
    <?php echo stripslashes($showcase_wp_buttons); ?>
    </div>
    <?php } ?>
    <?php } // Meta Box Plugin ?>
    
    <!-- entry content -->
    <?php the_content(''); // content ?>
    <?php wp_link_pages(); // content pagination ?>
    <div class="clear"></div>
    </div><!-- end .entry -->
    <div class="clear"></div>
    </div><!-- end #post -->
    <?php endwhile; endif; ?>
    </article><!-- end article -->
    
    
    <!-- Related Articles & Author / Tags and Categories -->
    <div id="tabs_wrapper">
    <div id="tabs_container">
    <ul id="tabs">
    <li class="active"><a href="#tab1"><i class="fa fa-bars"></i><span><?php esc_html_e( 'Related Articles', 'showcase_wp' ); ?></span></a></li>
    <li><a href="#tab2"><i class="fa fa-user"></i></a></li>
    <li><a href="#tab3"><i class="fa fa-folder-open"></i></a></li>
    <li><a href="#tab4"><i class="fa fa-tags"></i></a></li>
    </ul><!-- end .tabs -->
    </div><!-- end #tabs_container -->
    <!-- Related Articles -->
    <div id="tabs_content_container">
    <div id="tab1" class="tab_content" style="display: block;">
    <ul class="related-posts">
    <?php $showcase_wp_related = get_posts( array( 'category__in' => wp_get_post_categories($post->ID), 'numberposts' => 4, 'post__not_in' => array($post->ID) ) );
    if( $showcase_wp_related ) foreach( $showcase_wp_related as $post ) { setup_postdata($post); ?>
    <li>
    <?php if ( (has_post_thumbnail)) { ?>
    
    <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('showcase_wp_thumbnail-blog', array('title' => "")); ?></a>
    
    
    <?php } ?>
    
    <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><h4> <?php the_title(); ?> </h4></a>
    <div class="footer-data">
    <?php if (function_exists('thumbs_rating_getlink')) { echo thumbs_rating_getlink(); } ?>
    </div><!-- end .home-data -->
    </li>
    <?php } wp_reset_postdata(); ?>
    </ul><!-- end .mv_list_small -->
    <div class="clear"></div>
    </div><!-- end #tab1 -->
    <!-- Author -->
    <div id="tab2" class="tab_content">
    <?php if(get_the_author_meta('description') ): ?>
    <div class="author-meta">
    <div class="author-left-meta">
    <a href="<?php echo esc_url(get_author_posts_url( get_the_author_meta( 'ID' ) )); ?>"><?php echo get_avatar( get_the_author_meta( 'user_email' ), 70 ); ?></a>
    </div><!-- end .author-left-meta -->
    <div class="author-info">
    <strong><?php the_author_posts_link(); ?></strong> &rsaquo; <a class="author-link" href="<?php the_author_meta('url'); ?>" target="_blank"><?php the_author_meta('url'); ?></a><br />
    <p><?php the_author_meta('description'); ?>
    <ul class="author-social-top">
    <?php $showcase_wp_author_fblink = '//facebook.com/'; ?>
    <?php if(get_the_author_meta('showcase_wp_facebook')) { ?><li class="facebook"><a target="_blank" href="<?php echo esc_url($showcase_wp_author_fblink); ?><?php echo esc_html(the_author_meta('showcase_wp_facebook')); ?>"><i class="fa fa-facebook"></i></a></li><?php } ?>
    <?php $showcase_wp_author_twlink = '//twitter.com/'; ?>
    <?php if(get_the_author_meta('showcase_wp_twitter')) { ?><li class="twitter"><a target="_blank" href="<?php echo esc_url($showcase_wp_author_twlink); ?><?php echo esc_html(the_author_meta('showcase_wp_twitter')); ?>"><i class="fa fa-twitter"></i></a></li><?php } ?>
    <?php $showcase_wp_author_glink = '//plus.google.com/'; ?>
    <?php if(get_the_author_meta('showcase_wp_google')) { ?><li class="google"><a target="_blank" href="<?php echo esc_url($showcase_wp_author_glink); ?><?php echo esc_html(the_author_meta('showcase_wp_google')); ?>?rel=author"><i class="fa fa-google-plus"></i></a></li><?php } ?>
    </ul>
    </p>
    </div><!-- end .autor-info -->
    <div class="clear"></div>
    </div><!-- end .author-meta -->
    <?php endif; ?>
    <div class="clear"></div>
    </div><!-- end #tab2 -->
    <!-- Categories -->
    <div id="tab3" class="tab_content">
    <?php $showcase_wp_categories = get_the_category();
    if ($showcase_wp_categories): ?>
    <div class="ct-size"><?php the_category(' <span>,</span> '); // categories ?></div><div class="clear"></div>
    <?php endif; ?>
    <div class="clear"></div>
    </div><!-- end #tab3 -->
    <!-- Tags -->
    <div id="tab4" class="tab_content">
    <?php $showcase_wp_tags = get_the_tags();
    if ($showcase_wp_tags): ?>
    <div class="ct-size"><?php the_tags('', ' <span>,</span> '); // tags ?></div><div class="clear"></div>
    <?php endif; ?>
    <div class="clear"></div>
    </div><!-- end #tab4 -->
    </div><!-- end .tabs_content_container -->
    </div><!-- end #tabs_wrapper -->
    
    
    <!-- Comments -->
    <div id="comments" class="comments">
    <?php if (get_comments_number()==0) { } else { ?>
    <div class="comments-title"><i class="fa fa-comments"></i> <?php esc_html_e( 'Comments', 'showcase_wp' ); ?></div>
    <?php } ?>
    <div class="clear"></div>
    <?php comments_template('', true); // comments ?>
    </div>
    <div class="clear"></div>
    
    </div><!-- end .single-content -->
    
    
    <!-- Begin Sidebar (small) -->
    <?php get_template_part('sidebar-small'); ?>
    <!-- end #sidebar (middle) -->
    
    <!-- Begin Sidebar (right) -->
    <?php get_sidebar(); // add sidebar ?>
    <!-- end #sidebar (right) -->
    
    
    <div class="clear"></div>
    </div><!-- end .wrap-fullwidth -->
    
    <div id="single-share">
    <?php $showcase_wp_facebooklink = 'https://www.facebook.com/sharer/sharer.php?u='; ?>
    <a class="fbbutton" target="_blank" href="<?php echo esc_url($showcase_wp_facebooklink); ?><?php the_permalink(); ?>"><i class="fa fa-facebook-official"></i></a>
    <?php $showcase_wp_twitterlink = 'https://twitter.com/intent/tweet?text=Check%20out%20this%20article:%20'; ?>
    <a class="twbutton" target="_blank" href="<?php echo esc_url($showcase_wp_twitterlink); ?><?php the_title(); ?>%20-%20<?php the_permalink(); ?>"><i class="fa fa-twitter"></i></a>
    <?php $articleimage = wp_get_attachment_url( get_post_thumbnail_id($post->ID)); ?>
    <?php $showcase_wp_pinlink = 'https://pinterest.com/pin/create/button/?url='; ?>
    <a class="pinbutton" target="_blank" href="<?php echo esc_url($showcase_wp_pinlink); ?><?php the_permalink(); ?>&amp;media=<?php echo esc_html($articleimage); ?>&amp;description=<?php the_title(); ?>"><i class="fa fa-pinterest"></i></a>
    <?php $showcase_wp_googlelink = 'https://plus.google.com/share?url='; ?>
    <a class="googlebutton" target="_blank" href="<?php echo esc_url($showcase_wp_googlelink); ?><?php the_permalink(); ?>"><i class="fa fa-google-plus-square"></i></a>
    <?php $showcase_wp_emaillink = 'mailto:?subject='; ?>
    <a class="emailbutton" target="_blank" href="<?php echo esc_url($showcase_wp_emaillink); ?><?php the_title(); ?>&amp;body=<?php the_permalink(); ?> <?php echo showcase_wp_excerpt(strip_tags(strip_shortcodes(get_the_excerpt())), 140); ?>"><i class="fa fa-envelope"></i></a>
    </div><!-- end #single-share -->
    
    <?php get_footer(); // add footer  ?>
  • Kabul Edilen Cevap
    • Süslü parantez açılmış kapanışı bulman lazım
      {…..} böyle bloke silmen lazım
  • 12-06-2021, 13:00:19
    #2
    Bu cevap, konu sahibi tarafından kabul edilebilir bir cevap olarak işaretlendi.
    Süslü parantez açılmış kapanışı bulman lazım
    {…..} böyle bloke silmen lazım
  • 12-06-2021, 13:01:58
    #3
    120 ve 125 dahil silin.