WordPress.org

Ready to get started?Download WordPress

Forums

Parse Error (5 posts)

  1. luapnampahc
    Member
    Posted 1 year ago #

    Hi.

    My posts on the website are showing this line:

    Parse error: syntax error, unexpected $end in /var/sites/m/marketsizeresearch.com/public_html/blog/wp-content/themes/daily_headlines/single.php on line 112

    The code from single.php is as follows below. Can anyone tell me where there is a problem..

    <?php
    $template = '' == ($tpl=trim(get_post_meta($post->ID, 'wpzoom_post_template', true))) ? 'side-right' : $tpl;
    
    get_header();
    ?>
    
    <div id="content"<?php echo $template == 'side-left' ? ' class="templateLeft"' : ''; ?>>
    
    	<div class="wrap">
    
    		<?php
    		wp_reset_query();
    
    		if (have_posts()) :
    
    			while (have_posts()) :
    
    				the_post();
    
    				?><div class="postInfo">
    
    					<h1 class="title"><?php the_title(); ?></h1>
    					<p class="postmetadata">
    					<?php if (option::get('post_author') == 'on') { if ($prev) {echo ' / '; } ?><?php _e('Posted by', 'wpzoom'); ?> <?php the_author_posts_link(); $prev = TRUE; } ?>
    					<?php if (option::get('post_category') == 'on') { if ($prev) {echo ' / '; } ?><span class="category"><?php _e('In ', 'wpzoom'); the_category(', '); ?></span><?php $prev = TRUE; } ?>
    					<?php if (option::get('post_date') == 'on') { if ($prev) {echo ' / '; } ?><time datetime="<?php the_time("Y-m-d"); ?>" pubdate><?php the_time("F j, Y");  ?></time><?php $prev = TRUE; } ?>
    					<?php edit_post_link( __('Edit post', 'wpzoom'), ' / ', ''); ?>
    					</p><!-- end .postmetadata -->
    
    				</div>
    
    				<div id="main">
    
    					<div class="column <?php echo $template == 'full' ? 'column-full' : 'column-double'; ?> column-last widget single">
    
    						<?php
    						if ( option::get('ad_content_select') == 'on' && option::get('ad_content_pos') == 'Before content' ) {
    
    							?><div class="banner">
    
    								<?php if ( option::get('ad_content_code') <> "" ) {
    									echo stripslashes(option::get('ad_content_code'));
    								} else {
    									?><a>"><img src="<?php echo option::get('ad_content_imgpath'); ?>" alt="<?php echo option::get('ad_content_imgalt'); ?>" /></a><?php
    								} ?>
    
    							</div><?php
    
    						}
    						?>
    
    						<div class="post-content"><?php the_content(''); ?></div>
    
    						<?php wp_link_pages( array( 'before' => '<p class="pages"><strong>' . __('Pages', 'wpzoom') . ':</strong> ', 'after' => '</p>', 'next_or_number' => 'number' ) ); ?>
    
    						<div class="clear"> </div>
    
    						<?php if (option::get('post_tags') == 'on') { ?><?php the_tags( '<p class="tags"><strong>'.__('Tags', 'wpzoom').':</strong> ', ', ', '</p>'); } ?>
    
    						<?php
    						if ( option::get('ad_content_select') == 'on' && option::get('ad_content_pos') == 'After content' ) {
    
    							?><div class="banner">
    
    								<?php if ( option::get('ad_content_code') <> "" ) {
    									echo stripslashes(option::get('ad_content_code'));
    								} else {
    									?><a>"><img src="<?php echo option::get('ad_content_imgpath'); ?>" alt="<?php echo option::get('ad_content_imgalt'); ?>" /></a><?php
    								} ?>
    
    							</div><?php
    
    						}
    						?>
    
    						<?php if (option::get('post_share') == 'on') { ?>
    						<div class="social">
    
    							<h3><?php _e('Share this article','wpzoom'); ?></h3>
    
    							<ul class="wpzoomSocial">
    
    <li><a href="http://twitter.com/share">" class="twitter-share-button" data-count="horizontal">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></li>
    <li><iframe src="http://www.facebook.com/plugins/like.php?href=<?php echo urlencode(get_permalink($post->ID)); ?>&layout=button_count&show_faces=false&width=1000&action=like&font=arial&colorscheme=light&height=21" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:80px; height:21px;" allowTransparency="true"></iframe></li>
    <li><g:plusone size="medium"></g:plusone></li>
    							<div class="clear"> </div>
    
    						</div><!-- end .social -->
    						<?php } ?>
    
    						<?php if (option::get('post_comments') == 'on') {
    							comments_template();
    						} ?>
    
    						<div class="clear"> </div>
    
    					</div><!-- end .single -->
    
    				</div><!-- end #main --><?php
    
    			endwhile;
    
    		endif;
    
    		if ( $template != 'full' ) {
    
    			?><div id="sidebar">

    [Moderator note: Please wrap all code in backticks]

  2. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    Where did that theme come from - it does not appear to be one that is from the repository on this site, in which case, you'll likely need to contact the vendor/developer for help.

  3. luapnampahc
    Member
    Posted 1 year ago #

    Its a WPZOOM theme, called Daily Headlines. I was just wondering if the syntax is missing a bracket or a semicolon or something. Is there a website that checks syntax? I'll get in touch with WPZoom too.

  4. ricoh
    Member
    Posted 1 year ago #

    if ( $template != 'full' ) {
    
    } // <-- whoopsie ?><div id="sidebar">
  5. ricoh
    Member
    Posted 1 year ago #

    DOH! just saw what yogi posted, sorry

Topic Closed

This topic has been closed to new replies.

About this Topic