/[LeafOK_CVS]/fenglin/bbs/themes/default/view_article.view.php
ViewVC logotype

Diff of /fenglin/bbs/themes/default/view_article.view.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.27 by sysadm, Sat Apr 26 05:28:31 2025 UTC Revision 1.38 by sysadm, Thu Jun 19 09:19:34 2025 UTC
# Line 23  Line 23 
23    
24          $navigator_bar = <<<HTML          $navigator_bar = <<<HTML
25                  <a class="s2" href="main.php?sid={$result_set['data']['sid']}">{$BBS_name}</a>&gt;&gt;<a class="s2" href="list.php?sid={$result_set['data']['sid']}">{$result_set["data"]["section_title"]}</a>&gt;&gt;<a class="s2" href="list.php?sid={$result_set['data']['sid']}&ex={$result_set['data']['ex']}">{$section_scope}</a>                  <a class="s2" href="main.php?sid={$result_set['data']['sid']}">{$BBS_name}</a>&gt;&gt;<a class="s2" href="list.php?sid={$result_set['data']['sid']}">{$result_set["data"]["section_title"]}</a>&gt;&gt;<a class="s2" href="list.php?sid={$result_set['data']['sid']}&ex={$result_set['data']['ex']}">{$section_scope}</a>
26            HTML;
27    
28            if ($_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_POST) &&
29                    (!$result_set["data"]["lock"]))
30            {
31            $navigator_bar .= <<<HTML
32                  <a class="s2" href="article_post.php?reply_id={$result_set['data']['id']}&quote=0" title="直接回复该文章">[快速回复]</a>                  <a class="s2" href="article_post.php?reply_id={$result_set['data']['id']}&quote=0" title="直接回复该文章">[快速回复]</a>
33          HTML;          HTML;
34            }
35    
36          if ($previous_id > 0)          if ($previous_id > 0)
37          {          {
38                  $navigator_bar .= <<<HTML                  $navigator_bar .= <<<HTML
# Line 99  Line 107 
107                  font-size: 16px;                  font-size: 16px;
108                  text-decoration: line-through;                  text-decoration: line-through;
109          }          }
110            IMG.auto_adjust
111            {
112                    display: none;
113            }
114          </style>          </style>
         <script type="text/javascript" src="../js/img_adjust.js"></script>  
115          <script src="../js/polyfill.min.js"></script>          <script src="../js/polyfill.min.js"></script>
116          <script src="../js/axios.min.js"></script>          <script src="../js/axios.min.js"></script>
117            <script src="../js/jquery.min.js"></script>
118          <script type="text/javascript">          <script type="text/javascript">
119          function ch_page(page)          function ch_page(page)
120          {          {
# Line 321  Line 333 
333                  {                  {
334                          f.addEventListener("submit", (e) => {                          f.addEventListener("submit", (e) => {
335                                  e.preventDefault();                                  e.preventDefault();
336                                  move_article(f.sid.value);                                  if (f.sid.value > 0)
337                                    {
338                                            move_article(f.sid.value);
339                                    }
340                          });                          });
341                  }                  }
342          });          });
343    
344          </script>          $(document).ready(function() {
345          <script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3013347141025996" crossorigin="anonymous">                  $("img[class=auto_adjust]").on("load", function() {
346                            if ($(this).width() > {$BBS_img_max_width})
347                            {
348                                    $(this).width({$BBS_img_max_width});
349                            }
350                            $(this).show();
351                    })
352                    .on("mousewheel", function(e) {
353                            var zoom = parseFloat($(this).css("zoom"));
354                            zoom *= (1 + e.originalEvent.wheelDelta / 1000);
355                            if (zoom > 0)
356                            {
357                                    $(this).css("zoom", zoom);
358                            }
359                    });
360            });
361          </script>          </script>
362          </head>          </head>
363          <body>          <body>
# Line 392  Line 422 
422                                          <span id="set_delete_{$article['aid']}"><img src="images/del.gif" width="16" height="16"><a class="s4" href="" onclick="return article_op('delete', {$article['aid']}, 1, true);" title="删除该文章">删除</a></span>                                          <span id="set_delete_{$article['aid']}"><img src="images/del.gif" width="16" height="16"><a class="s4" href="" onclick="return article_op('delete', {$article['aid']}, 1, true);" title="删除该文章">删除</a></span>
423                                  HTML;                                  HTML;
424                          }                          }
425                          if ($_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_POST))                          if ($_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_POST) &&
426                                    (!$result_set["data"]["lock"]))
427                          {                          {
428                                  $article_ctrl_bar .= <<<HTML                                  $article_ctrl_bar .= <<<HTML
429                                          <img src="images/edit.gif" width="16" height="16"><a class="s4" href="article_post.php?reply_id={$article['aid']}" title="引用回复该文章">回复</a>                                          <img src="images/edit.gif" width="16" height="16"><a class="s4" href="article_post.php?reply_id={$article['aid']}" title="引用回复该文章">回复</a>
# Line 410  Line 441 
441                          }                          }
442                          if ($article["tid"] == 0 && $_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_POST | S_MAN_S))                          if ($article["tid"] == 0 && $_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_POST | S_MAN_S))
443                          {                          {
444                                  $set_ontop_display = ($article["ontop"] ? "none" : "inline");                                  $set_ontop_display = ($result_set["data"]["ontop"] ? "none" : "inline");
445                                  $unset_ontop_display = ($article["ontop"] ? "inline" : "none");                                  $unset_ontop_display = ($result_set["data"]["ontop"] ? "inline" : "none");
446    
447                                  $article_ctrl_bar .= <<<HTML                                  $article_ctrl_bar .= <<<HTML
448                                          <a class="s4" id="set_ontop_{$article['aid']}" style="display: {$set_ontop_display}" href="" onclick="return article_op('ontop', {$article['aid']}, 1, true)" title="置顶">置顶</a>                                          <a class="s4" id="set_ontop_{$article['aid']}" style="display: {$set_ontop_display}" href="" onclick="return article_op('ontop', {$article['aid']}, 1, true)" title="置顶">置顶</a>
449                                          <a class="s4" id="unset_ontop_{$article['aid']}" style="display: {$unset_ontop_display}" href="" onclick="return article_op('ontop', {$article['aid']}, 0)" title="取消置顶">取消置顶</a>                                          <a class="s4" id="unset_ontop_{$article['aid']}" style="display: {$unset_ontop_display}" href="" onclick="return article_op('ontop', {$article['aid']}, 0)" title="取消置顶">取消置顶</a>
450                                  HTML;                                  HTML;
451                          }                          }
452                          if ($article["tid"] == 0 && $_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_POST) &&                          if ($article["tid"] == 0 && $_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_POST) &&
453                                  ($_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_MAN_S) || $_SESSION["BBS_uid"] == $article["uid"]))                                  ($_SESSION["BBS_priv"]->checkpriv($result_set["data"]["sid"], S_MAN_S) || $_SESSION["BBS_uid"] == $article["uid"]))
454                          {                          {
455                                  $set_lock_display = ($article["lock"] ? "none" : "inline");                                  $set_lock_display = ($result_set["data"]["lock"] ? "none" : "inline");
456                                  $unset_lock_display = ($article["lock"] ? "inline" : "none");                                  $unset_lock_display = ($result_set["data"]["lock"] ? "inline" : "none");
457    
458                                  $article_ctrl_bar .= <<<HTML                                  $article_ctrl_bar .= <<<HTML
459                                          <a class="s4" id="set_lock_{$article['aid']}" style="display: {$set_lock_display}" href="" onclick="return article_op('lock', {$article['aid']}, 1);" title="禁止回复">静默</a>                                          <a class="s4" id="set_lock_{$article['aid']}" style="display: {$set_lock_display}" href="" onclick="return article_op('lock', {$article['aid']}, 1);" title="禁止回复">静默</a>
# Line 453  Line 484 
484                  $nickname = htmlspecialchars($article["nickname"], ENT_HTML401, 'UTF-8');                  $nickname = htmlspecialchars($article["nickname"], ENT_HTML401, 'UTF-8');
485                  $title_f = split_line(htmlspecialchars($article["title"], ENT_HTML401, 'UTF-8'), "", 65, 2, "<br />");                  $title_f = split_line(htmlspecialchars($article["title"], ENT_HTML401, 'UTF-8'), "", 65, 2, "<br />");
486                  $title_class = ($article["visible"] ? "title_normal" : "title_deleted");                  $title_class = ($article["visible"] ? "title_normal" : "title_deleted");
487                  $content_f = LML(htmlspecialchars((isset($article["content"]) ? $article["content"] : ""), ENT_HTML401, 'UTF-8'), true, true, 80);                  $content_f = LML(htmlspecialchars($article["content"], ENT_HTML401, 'UTF-8'), true, true, 80);
488                  $content_class = ($article["visible"] ? "content_normal" : "content_deleted");                  $content_class = ($article["visible"] ? "content_normal" : "content_deleted");
489    
490                  $transship_info = "";                  $transship_info = "";
# Line 470  Line 501 
501                  foreach ($article["attachments"] as $attachment)                  foreach ($article["attachments"] as $attachment)
502                  {                  {
503                          $filename = $attachment["filename"];                          $filename = $attachment["filename"];
                         $ext = strtolower(substr($filename, (strrpos($filename, ".") ? strrpos($filename, ".") + 1 : 0)));  
504    
505                          $atta_list .= <<<HTML                          $atta_list .= <<<HTML
506                                  <span id="attachment_{$attachment['aid']}"><img src="images/closed.gif"><a class="s2" href="dl_file.php?aid={$attachment['aid']}" target="_target">{$filename}</a> ({$attachment["size"]}字节)                                  <span id="attachment_{$attachment['aid']}"><img src="images/closed.gif"><a class="s2" href="dl_file.php?aid={$attachment['aid']}" target="_target">{$filename}</a> ({$attachment["size"]}字节)
# Line 494  Line 524 
524    
525                          if ($attachment["check"])                          if ($attachment["check"])
526                          {                          {
527                                    $ext = strtolower(pathinfo($filename, PATHINFO_EXTENSION));
528                                  switch ($ext)                                  switch ($ext)
529                                  {                                  {
530                                          case "bmp":                                          case "bmp":
# Line 505  Line 536 
536                                          case "tiff":                                          case "tiff":
537                                                  $atta_list .= <<<HTML                                                  $atta_list .= <<<HTML
538                                                          <br />                                                          <br />
539                                                          <img onmousewheel="return bbs_img_zoom(event, this)" src="dl_file.php?aid={$attachment['aid']}">                                                          <img class="auto_adjust" src="dl_file.php?aid={$attachment['aid']}">
540                                                  HTML;                                                  HTML;
541                                                  break;                                                  break;
542                                  }                                  }
# Line 533  Line 564 
564                                          作者:&nbsp;<a class="s2" href="view_user.php?uid={$article['uid']}" onclick='return {$user_viewable}' target=_blank title="查看用户资料">{$username}</a>                                          作者:&nbsp;<a class="s2" href="view_user.php?uid={$article['uid']}" onclick='return {$user_viewable}' target=_blank title="查看用户资料">{$username}</a>
565                                  </td>                                  </td>
566                                  <td width="75%" class="body">                                  <td width="75%" class="body">
567                                          <span style="color:#606060;">标题:</span>                                          <span style="color: #606060">标题:</span>
568                                          <img src="images/expression/{$article['icon']}.gif">                                          <img src="images/expression/{$article['icon']}.gif">
569                                          <span id="title_{$article['aid']}" class="{$title_class}">                                          <span id="title_{$article['aid']}" class="{$title_class}">
570                                                  {$title_f}                                                  {$title_f}
# Line 545  Line 576 
576                          </tr>                          </tr>
577                          <tr>                          <tr>
578                                  <td align="center">                                  <td align="center">
579                                          昵称:&nbsp;<span style="color: #909090;">{$nickname}</span>                                          昵称:&nbsp;<span style="color: #909090">{$nickname}</span>
580                                  </td>                                  </td>
581                                  <td class="body">                                  <td class="body">
582                                          <span style="color:#606060;">来自:</span>&nbsp;<span style="color: #909090; ">{$article["sub_ip"]}</span>                                          <span style="color: #606060">来自:</span>&nbsp;<span style="color: #909090">{$article["sub_ip"]}</span>
583                                  </td>                                  </td>
584                                  <td>                                  <td>
585                                  </td>                                  </td>
# Line 558  Line 589 
589                                          经验值:&nbsp;<span style="color:red;">{$article["exp"]}</span>                                          经验值:&nbsp;<span style="color:red;">{$article["exp"]}</span>
590                                  </td>                                  </td>
591                                  <td class="body">                                  <td class="body">
592                                          <span style="color:#606060;">发贴时间:</span>&nbsp;<span style="color: #909090; ">{$article["sub_dt"]->format("Y年m月d日 H:i:s (\U\T\C P)")}</span>                                          <span style="color: #606060">发贴时间:</span>&nbsp;<span style="color: #909090">{$article["sub_dt"]->format("Y年m月d日 H:i:s (\U\T\C P)")}</span>
593                                  </td>                                  </td>
594                                  <td>                                  <td>
595                                  </td>                                  </td>
596                          </tr>                          </tr>
597                          <tr>                          <tr>
598                                  <td align="center">                                  <td align="center">
599                                          等级:&nbsp;<span style="color: #909090;">{$level}</span>                                          等级:&nbsp;<span style="color: #909090">{$level}</span>
600                                  </td>                                  </td>
601                                  <td class="body">                                  <td class="body">
602                                          <span style="color:#606060;">长度:</span>&nbsp;<span style="color: #909090; ">{$article["length"]}字</span>                                          <span style="color: #606060">长度:</span>&nbsp;<span style="color: #909090">{$article["length"]}字</span>
603                                  </td>                                  </td>
604                                  <td>                                  <td>
605                                  </td>                                  </td>
# Line 576  Line 607 
607                          <tr height="2">                          <tr height="2">
608                                  <td>                                  <td>
609                                  </td>                                  </td>
610                                  <td style="background-color: #909090;">                                  <td style="background-color: #909090">
611                                  </td>                                  </td>
612                                  <td>                                  <td>
613                                  </td>                                  </td>
# Line 594  Line 625 
625                          <tr>                          <tr>
626                                  <td>                                  <td>
627                                  </td>                                  </td>
628                                  <td style="color:#000000; ">                                  <td style="color: #000000">
629                                          ========== * * * * * ==========                                          ========== * * * * * ==========
630                                          <br />                                          <br />
631                                          {$atta_list}                                          {$atta_list}
# Line 701  Line 732 
732          </body>          </body>
733          </html>          </html>
734          HTML;          HTML;
 ?>  


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1