FatalErrorException:语法错误,文件意外结束

埃伦斯·塞姆·默特

尊敬的 stackoverflow 会员 PHP 开发人员。尽管项目中有所有编码,但我一直收到以下错误。它在最后一行的第 102 行给出了一个语法错误。我收到错误“语法错误,文件意外结束”。我已经尝试了 3 天,但我找不到错误。非常感谢您的帮助。

<?php foreach($entrysquizquest as $key => $entry): ?>

    <section class="entry quizquestion selectableQuest" id="section_<?php echo e($entry->order); ?>" data-entry="<?php echo e($entry->id); ?>">

        <?php if($entry->title): ?>
            <h2 class="sub-title" >
                <?php echo e($entry->title); ?>

            </h2>
        <?php endif; ?>

        <div class="media">
            <div class="sharemedia">
             <?php echo $__env->make('._particles.others.entrysharebuttons', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
            </div>
            <a id="" class="gif-icon-a"><img class="img-responsive" style="display: block;width:100%" alt="<?php echo e($entry->title); ?>" src="<?php echo e(makepreview($entry->image, null, 'entries')); ?>"></a>
            <small><?php echo $entry->source; ?></small>
        </div>

        <p>
            <?php echo $entry->body; ?>

        </p>
        <div class="clear"></div>
        <div class="answer" style="margin-left:-15px;">
            <?php $sitep = $post->entry()->where('type', 'answer')->where('source', $entry->id)->get(); ?>

            <ol class="option-selection  <?php if($entry->video == '1'): ?>thdefault <?php else: ?> <?php echo e($entry->video == "2" ?  'thlarge' : 'thlist'); ?><?php endif; ?>">
                <?php foreach($sitep as $keya => $answers): ?>
                    <?php  $keya=$keya+1;?>

                    <li>
                        <a class="" href="javascript:"  data-answer="<?php echo e($answers->id); ?>" data-result="<?php echo e($answers->video); ?>" >
                            <div class="answer-cover">
                                <?php if($entry->video!='3'): ?>
                                    <img class="responsive-img" alt="<?php echo e($answers->title); ?>" src="<?php echo e(makepreview($answers->image, null, 'answers')); ?>">
                                <?php endif; ?>
                                <h4 class="option-sel" >
                                    <i class="fa fa-square-o answer-check"></i>
                                    <span  class="option-text">
                                    <?php echo $answers->title > "" ? $answers->title : '<br>'; ?>

                                    </span>
                                </h4>
                            </div>
                        </a>
                        <div class="clear"></div>
                    </li>
                    <?php if(($keya%3)==0 and $entry->video=='1'  or ($keya%2)==0 and $entry->video=='2' ): ?>
                        </ol><div class="clear"></div> <ol class="option-selection  <?php if($entry->video == '1'): ?>thdefault <?php else: ?> <?php echo e($entry->video == "2" ?  'thlarge' : 'thlist'); ?><?php endif; ?>">
                    <?php endif; ?>
                <?php endforeach; ?>
              </ol>
        </div>
        <div class="clear"></div>
    </section>

 






<section class="entry results" id="quiz_result" data-popup="<?php echo e(getcong('BuzzyQuizzesPopup')); ?>">
    <div class="quiz_result_area">
        <h2 class="post-title"><?php echo e($post->title); ?></h2>
        <ol>
            <?php foreach($entrysquizresults as $keyp => $entry): ?>

                <li class="quiz_result" data-order="<?php echo e($keyp); ?>" data-result="<?php echo e($entry->id); ?>" data-link="<?php echo e(Request::url()); ?>" data-name="<?php echo e(trans('buzzyquiz.yougot', ['title'=> $entry->title])); ?>"  data-iname="<?php echo e(trans('buzzyquiz.igot', ['title'=> $entry->title, 'posttitle'=> $post->title])); ?>"  data-itname="<?php echo e(trans('buzzyquiz.igotfortweet', ['title'=> $entry->title])); ?>" data-description="<?php echo e(strip_tags($entry->body)); ?>" data-picture="<?php echo e($entry->image > "" ? makepreview($entry->image, null, 'entries') : makepreview($post->thumb, 'b', 'posts')); ?>">

                    <h2 class="quiz_headline">
                        <?php echo e(trans('buzzyquiz.yougot', ['title'=> $entry->title])); ?>

                    </h2>
                    <div class="clear"></div>
                    <div  class="quiz_text"  <?php echo e($entry->image == '' ? 'style=width:100%' :''); ?><?php echo $entry->body; ?></div>

                    <div class="quiz_img <?php echo e($entry->image == '' ? 'hide' :''); ?>" >
                        <img class="responsive_img" style=" float: right;"  src="data:image/gif;base64,R0lGODlhAQABAPAAAAAAAAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==">
                    </div>

                </li>

            <?php endforeach; ?>
        </ol>

    </div>
<div class="clear"></div>
    <div class="quiz_result_share">
    <h2 class="bold share_title"><?php echo e(trans('buzzyquiz.shareresult')); ?></h2>
    <div class="external-sign-in">
        <a href="javascript:" class="Facebook postToResultFeed"><?php echo e(trans('index.sharefacebook')); ?></a>
        <a href="javascript:" class="Twitter postToResultFeed"><?php echo e(trans('index.sharetweet')); ?></a>
        <a href="javascript:" class="Pinterest postToResultFeed"><?php echo e(trans('index.sharepinterest')); ?></a>
        <a href="https://plus.google.com/share?url=<?php echo e(Request::url()); ?>" class="Google popup-action"><?php echo e(trans('index.sharegoogle')); ?></a>
    </div>
    <div class="clear"></div>
    </div>
</section>
穆罕默德·艾尔沙兹利

在第 57 行添加

<?php endforeach; ?>

你忘了结束 foreach

本文收集自互联网,转载请注明来源。

如有侵权,请联系 [email protected] 删除。

编辑于
0

我来说两句

0 条评论
登录 后参与评论

相关文章

for循环中循环语法错误:意外的文件结束

FatalErrorException:语法错误,意外的':',期望为','或';' 在Laravel

Makefile:语法错误/ bin / sh:-c:语法错误:文件意外结束

Bash配置文件语法错误:文件意外结束

语法错误:.bash_profile文件意外结束

第45行语法错误:文件意外结束

Symfony \组件\调试\异常\ FatalErrorException语法错误,文件意外结束(Laravel)

PHP解析错误:语法错误,文件意外结束,应为“`”

PHP脚本:语法错误,文件意外结束

语法错误:bash中的文件意外结束错误

语法错误:文件意外结束-Bash脚本

语法错误:文件意外结束-Bash脚本

语法错误,PHP中文件意外结束

PHP-解析错误:语法错误,文件意外结束

第42行:语法错误:文件意外结束

bash:语法错误:文件意外结束

语法错误:意外的输入结束

PHP:解析错误:语法错误,文件意外结束

FatalErrorException语法错误,意外的“,”

.bashrc语法错误:文件意外结束

.bashrc:语法错误:文件意外结束

带有原始 .bashrc 的“语法错误:文件意外结束”

语法错误,文件 codeigniter 视图意外结束

我收到解析错误:语法错误,文件意外结束

语法错误,运行 php7 的文件意外结束

解析错误:语法错误、文件意外结束、期望变量

Bash 语法错误:fi 上的文件意外结束

解析错误:语法错误,文件意外结束问题

AWK - 语法错误:文件意外结束