Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8038285
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T03:11:13+00:00 2026-06-05T03:11:13+00:00

<?php get_header(); ?> <div id=content> <?php if (have_posts()): ?> <?php $i=0;?> <?php while (have_posts())

  • 0
<?php get_header(); ?>
<div id="content">

<?php if (have_posts()): ?>

    <?php $i=0;?>
    <?php while (have_posts()) : the_post(); ?>
    <?php $i++;?>
    <div class="cols"<? if($i%3==0) echo ' style="margin-right:0"';?>>
        <div class="post" id="post-<?php the_ID(); ?>">
            <?php $thumb=get_post_meta($post->ID, 'image', true); ?>
            <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
            <?php if($thumb!=''){
            $thumb = str_replace(get_bloginfo('url').'/','',$thumb);
            ?>
            <img src="<?php bloginfo('template_url');?>/thumb.php?src=<?=$thumb;?>&w=183&h=140&zc=1" class="thumb" alt="<?php the_title(); ?>" />
            <? } else { ?>
            <img src="<?php bloginfo('template_url'); ?>/images/pic.jpg" alt="" class="thumb" />
            <? } ?>
            </a>

            <h2 class="title"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php echo cut_string(get_the_title(),30,'...'); ?></a></h2>
            <p><?php echo cut_string(get_the_content(),60,'...'); ?></p>
            <p class="meta">
            <?php if(function_exists('the_views')) { ?>
            <span class="views"><?php the_views(); ?></span> <?php } ?>
            <?php comments_popup_link('No Comments', '1 Comment', '% Comments', 'comments'); ?>
            </p>
            <p><?php if(function_exists('the_ratings')) { the_ratings(); } ?> </p>

        </div></div>

    <?php endwhile; ?>
    <div class="clearfix"></div>
    <div class="page_navi"><?php page_navi();?></div>

<?php else: ?>

    <div class="post">
        <h2 class="title">Not Found</h2>
    </div>

<?php endif; ?>
</div>

<!-- end content -->

<?php get_sidebar(); ?>
<?php get_footer(); ?>

Parse error:

syntax error, unexpected T_ENDWHILE in /home/fakecsc1/domains/jocuri2k.com/public_html/wp-content/themes/Games/index.php on line 36

What’s the problem with this code? How can I fix it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T03:11:15+00:00Added an answer on June 5, 2026 at 3:11 am

    Looks like the problem is your use of shorttags here: <? instead of <?php

     <? } else { ?>
                <img src="<?php bloginfo('template_url'); ?>/images/pic.jpg" alt="" class="thumb" />
                <? } ?>
                </a>
    

    If your server isn’t interpreting these as PHP, php will see the endwhile before it sees the close tags. Change them to <?php instead of <?.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

With php file_get_contents() i want just only the post and image. But it's get
I can't get PHP to recognize the ImageMagick (Imagick) class. Everything else works, the
i have a file speakWord.php: <?php header(Content-Type: audio/mpeg); $voice = file_get_contents('http://translate.google.com/translate_tts?tl=' . urlencode($_POST['language']) .
I have made a code -- <?php header(Content-type: text/javascript); require_once('../php/config.php'); $domail_theme = $_GET['theme']; ?>
This is follow up post where I'm having a problem where my php code
I have a WordPress custom post-type setup. I've created single-[customposttype].php However instead of displaying
<?php /** * Template Name: Blog page * Description: The blog page */ get_header();
I'm totally lost :) I have a loop which outputs: POST ITLE POST CONTENT
I cant get a PHP file to send correct headers at my WAMP server.
I have a multiple language website, and I use a php get variable to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.