init
This commit is contained in:
109
app/us/view/article/catelists.phtml
Executable file
109
app/us/view/article/catelists.phtml
Executable file
@@ -0,0 +1,109 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
{include file="include/head" /}
|
||||
<script type="text/javascript">
|
||||
var navID = "1";
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<!--top-->
|
||||
<!--top-->
|
||||
<header class="header-PC header-Index">
|
||||
<div id="header" class="theme-white">
|
||||
{include file="include/top" /}
|
||||
{include file="include/top-header" /}
|
||||
</div>
|
||||
</header>
|
||||
{include file="include/top-header-mobile" /}
|
||||
<!--top End-->
|
||||
<div class="homeban">
|
||||
<div class="bd">
|
||||
<ul>
|
||||
<li><img src="/frontend/weben/images/eng-blog.jpg"/></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 轮播 e -->
|
||||
<div class="swt-Container">
|
||||
<div class="news-vertu">
|
||||
<div class="tab">
|
||||
<?php if(!empty($cate_list)): ?>
|
||||
<?php foreach ($cate_list as $key => $value): ?>
|
||||
<a href="__ORICOROOT__/article/category/<?php echo $value['id'] ?>.html" class="<?php if ($category['id'] == $value['id']): ?> on <?php endif; ?>"><?php echo $value['name']; ?></a>
|
||||
<?php endforeach; ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<div class="search_box">
|
||||
<i class="search_icon"></i>
|
||||
<input type="text" placeholder="Search" class="search" id="article-search-in" value="">
|
||||
</div>
|
||||
<div class="content">
|
||||
<?php if ($list):?>
|
||||
<ul>
|
||||
|
||||
<li>
|
||||
<div class="blog_list ">
|
||||
<?php foreach ($list as $detail):?>
|
||||
<?php
|
||||
if($detail['jump_link'] == ''){
|
||||
$alink = "__ORICOROOT__/article/detail/".$detail['id'].".html";
|
||||
}
|
||||
else{
|
||||
$alink = $detail['jump_link'];
|
||||
}
|
||||
?>
|
||||
<div class="clearfix">
|
||||
<a href="<?php echo $alink;?>">
|
||||
<img src="<?php echo getImage($detail['picture'], 1500, 1000, 6); ?>">
|
||||
<h3><?php echo $detail['name']; ?></h3>
|
||||
<p><?php echo msubstr($detail['description'], 0, 200); ?></p>
|
||||
</a>
|
||||
<span class="blue"><?php echo date("M j, Y",$detail['createtime']); ?></span>
|
||||
</div>
|
||||
<?php endforeach;?>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
<?php else:?>
|
||||
<div class="clearfix"> No Result!</div>
|
||||
<?php endif;?>
|
||||
<!-- 分页 s -->
|
||||
<?php
|
||||
if ($page) {
|
||||
echo $page;
|
||||
}
|
||||
?>
|
||||
<!-- 分页 e -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- bottom s -->
|
||||
{include file="include/bottom" /}
|
||||
<!-- bottom e -->
|
||||
|
||||
<script>
|
||||
$(function(){
|
||||
|
||||
//新闻搜索
|
||||
var article_search_input = $("#article-search-in");
|
||||
|
||||
$(article_search_input).on("keyup", function(e){
|
||||
$("#article-search-in").keyup(function(event) {
|
||||
if (event && event.keyCode === 13) {
|
||||
var keywords = $("#article-search-in").val();
|
||||
var href = "?skeyword=" + encodeURIComponent(keywords);
|
||||
location.href = href;
|
||||
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
191
app/us/view/article/catelists1.phtml
Executable file
191
app/us/view/article/catelists1.phtml
Executable file
@@ -0,0 +1,191 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>News-ORICO Global Site</title>
|
||||
{include file="include/head-seo" /}
|
||||
{include file="include/head" /}
|
||||
<script type="text/javascript">
|
||||
var navID = "1";</script>
|
||||
</head>
|
||||
<body>
|
||||
<!--top-->
|
||||
<header class="header-PC header-Index">
|
||||
<div id="header" class="theme-white">
|
||||
{include file="include/top" /}
|
||||
{include file="include/top-header" /}
|
||||
</div>
|
||||
</header>
|
||||
{include file="include/top-header-mobile" /}
|
||||
|
||||
<!--top End-->
|
||||
<?php if ($category['picture']): ?>
|
||||
|
||||
<!-- 轮播 s -->
|
||||
<div class="homeban">
|
||||
<div class="bd">
|
||||
<ul>
|
||||
<li><img src="<?php echo getImage($category['picture']); ?>"/></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 轮播 e -->
|
||||
<div class="swt-Container">
|
||||
<div class="news-vertu">
|
||||
<div class="tab">
|
||||
<?php if (!empty($cate_list)): ?>
|
||||
<?php foreach ($cate_list as $key => $value): ?>
|
||||
<a href="/us/article/category/<?php echo $value['id'] ?>.html" class="<?php if ($category['id'] == $value['id']): ?> on <?php endif; ?>"><?php echo $value['name']; ?><span></span></a>
|
||||
<?php endforeach; ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- 轮播 e -->
|
||||
<?php endif; ?>
|
||||
<!-- 新闻列表 s -->
|
||||
<div class="new">
|
||||
<div class="swt-Container">
|
||||
<ul class="newfl">
|
||||
<?php
|
||||
//$articles = getDifferentArticle('ishot', 3, ['cid' => 1]);
|
||||
if (0):foreach ($articles as $detail):
|
||||
?>
|
||||
<li>
|
||||
<div class="xwimg"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><img src="<?php echo getImage($detail['picture'], 951, 459, 6); ?>"></a></div>
|
||||
<div class="xwtit"><a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><?php echo $detail['name']; ?></a></div>
|
||||
<div class="xname"><?php echo $detail['writer']; ?> published <?php echo getHMStime($detail['createtime'], time()); ?>/key words: <?php echo $detail['tags']; ?></div>
|
||||
<div class="xwcon"><?php echo msubstr($detail['description'], 0, 200); ?></div>
|
||||
|
||||
<div class="detail"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><i></i>Detailed reading</a></div>
|
||||
<div class="fx">
|
||||
<a href="#"><i class="f1"></i>Share</a>
|
||||
<a href="javascript:void(0);" class="addzan" data-id="<?php echo $detail['id']; ?>"><i class="f2"></i>Like(<?php echo $detail['zancount']; ?>)</a>
|
||||
<a href="<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>#ccount"><i class="f3"></i>Comment
|
||||
(<?php echo $detail['commentcount']; ?>)</a>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</li>
|
||||
<?php
|
||||
endforeach;
|
||||
endif;
|
||||
?>
|
||||
|
||||
<?php if ($list): foreach ($list as $detail): ?>
|
||||
<li>
|
||||
<div style="width:25%; float: left;"> <div class="xwimg"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><img src="<?php echo getImage($detail['picture']); ?>"></a></div></div>
|
||||
<div style="width:72%; float: right;">
|
||||
<div class="xwtit"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><?php echo $detail['name']; ?></a></div>
|
||||
|
||||
<div class="xname"><?php echo $detail['writer']; ?> <?php echo getHMStime($detail['createtime'], time()); ?></div>
|
||||
<!-- <div class="detail">对于注重便携HiFi听音发烧友来说,相信提到“飞傲”这个品牌,我想都不会感到陌生,飞傲音频在圈子里一直有着不错口碑,性能方面拥有绝对的优势。近日,飞傲家族中又迎...</div>-->
|
||||
<div class="detail"><?php echo msubstr($detail['description'], 0, 150);?></div>
|
||||
|
||||
<div class="fx">
|
||||
<a href="#"><i class="f1"></i>Share</a>
|
||||
<a href="javascript:void(0);" class="addzan" data-id="<?php echo $detail['id']; ?>"><i class="f2"></i>Like(<?php echo $detail['zancount']; ?>)</a>
|
||||
<a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>#ccount"><i class="f3"></i>Comment (<?php echo $detail['commentcount']; ?>)</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="clear"></div>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
<!-- 分页 s -->
|
||||
<?php
|
||||
if ($page) {
|
||||
echo $page;
|
||||
}
|
||||
?>
|
||||
<!-- 分页 e -->
|
||||
<?php endif; ?>
|
||||
</ul>
|
||||
<script>
|
||||
$(function() {
|
||||
$(".newfl .addzan").click(function(event) {
|
||||
event.preventDefault();
|
||||
var love = $(this);
|
||||
var id = love.data("id"); //对应id
|
||||
if (!love.data("zan")) {
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
dataType: "json",
|
||||
url: "<?php echo url('/us/article/zan'); ?>",
|
||||
data: {id: id},
|
||||
cache: false, //不缓存此页面
|
||||
success: function(data) {
|
||||
//console.log(data);
|
||||
if (data.code) {
|
||||
love.data("zan", true);
|
||||
love.html('<i class="f2"></i>Like(' + data.data + ')');
|
||||
}
|
||||
}
|
||||
});
|
||||
} else {
|
||||
alert('You have liked it!');
|
||||
}
|
||||
return false;
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
$pingluns = getDifferentPinglun('ishot', 8);
|
||||
if ($pingluns):
|
||||
?>
|
||||
<div class="newrh">
|
||||
<div class="plun">Wonderful Reviews</div>
|
||||
<ul class="pllist">
|
||||
<?php foreach ($pingluns as $pinglun): ?>
|
||||
<li>
|
||||
<a href="<?php echo url('us/pinglun/lists', ['type' => strtolower($pinglun['typeid']), 'cid' => $pinglun['content_id']]); ?>">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns<?php echo $pinglun['tx']; ?>.jpg"></div>
|
||||
<div class="peo1"><?php echo $pinglun['cname']; ?></div>
|
||||
<div class="peo2"><?php echo $pinglun['createtime']; ?></div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1"><?php echo msubstr($pinglun['content'], 0, 200); ?></div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 新闻列表 e -->
|
||||
|
||||
<!-- bottom s -->
|
||||
{include file="include/bottom" /}
|
||||
<!-- bottom e -->
|
||||
<script>
|
||||
$(function(){
|
||||
$(".news-vertu .tab a").click(function(){
|
||||
$(this).addClass('on').siblings().removeClass('on');
|
||||
var index = $(this).index();
|
||||
number = index;
|
||||
$('.news-vertu .content li').hide();
|
||||
$('.news-vertu .content li:eq('+index+')').show();
|
||||
});
|
||||
|
||||
var auto = 1; //等于1则自动切换,其他任意数字则不自动切换
|
||||
if(auto ==1){
|
||||
var number = 0;
|
||||
var maxNumber = $('.news-vertu .tab a').length;
|
||||
function autotab(){
|
||||
number++;
|
||||
number == maxNumber? number = 0 : number;
|
||||
$('.news-vertu .tab a:eq('+number+')').addClass('on').siblings().removeClass('on');
|
||||
$('.news-vertu .content ul li:eq('+number+')').show().siblings().hide();
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
164
app/us/view/article/catelists20191121.phtml
Executable file
164
app/us/view/article/catelists20191121.phtml
Executable file
@@ -0,0 +1,164 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>News-ORICO Global Site</title>
|
||||
{include file="include/head-seo" /}
|
||||
{include file="include/head" /}
|
||||
<script type="text/javascript">
|
||||
var navID = "1";</script>
|
||||
</head>
|
||||
<body>
|
||||
<!--top-->
|
||||
<header class="header-PC header-Index">
|
||||
<div id="header" class="theme-white">
|
||||
{include file="include/top" /}
|
||||
{include file="include/top-header" /}
|
||||
</div>
|
||||
</header>
|
||||
{include file="include/top-header-mobile" /}
|
||||
|
||||
<!--top End-->
|
||||
<?php if ($category['picture']): ?>
|
||||
|
||||
<!-- 轮播 s -->
|
||||
<div class="homeban">
|
||||
<div class="bd">
|
||||
<ul>
|
||||
<li><a href="<?php echo url_rewrite('article', ['id' => $category['id']]); ?>"><img src="<?php echo getImage($category['picture']); ?>"/></a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 轮播 e -->
|
||||
<div class="swt-Container">
|
||||
<div class="news-vertu">
|
||||
<div class="tab">
|
||||
<a href="/article/category/1.html" class="<?php if ($category['id'] == 1): ?> on <?php endif; ?>">News<span></span></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- 轮播 e -->
|
||||
<?php endif; ?>
|
||||
<!-- 新闻列表 s -->
|
||||
<div class="new">
|
||||
<div class="swt-Container">
|
||||
<ul class="newfl">
|
||||
<?php
|
||||
//$articles = getDifferentArticle('ishot', 3, ['cid' => 1]);
|
||||
if (0):foreach ($articles as $detail):
|
||||
?>
|
||||
<li>
|
||||
<div class="xwimg"><a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><img src="<?php echo getImage($detail['picture'], 951, 459, 6); ?>"></a></div>
|
||||
<div class="xwtit"><a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><?php echo $detail['name']; ?></a></div>
|
||||
<div class="xname"><?php echo $detail['writer']; ?> published <?php echo getHMStime($detail['createtime'], time()); ?>/key words: <?php echo $detail['tags']; ?></div>
|
||||
<div class="xwcon"><?php echo msubstr($detail['description'], 0, 200); ?></div>
|
||||
|
||||
<div class="detail"><a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><i></i>Detailed reading</a></div>
|
||||
<div class="fx">
|
||||
<a href="#"><i class="f1"></i>Share</a>
|
||||
<a href="javascript:void(0);" class="addzan" data-id="<?php echo $detail['id']; ?>"><i class="f2"></i>Like(<?php echo $detail['zancount']; ?>)</a>
|
||||
<a href="<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>#ccount"><i class="f3"></i>Comment
|
||||
(<?php echo $detail['commentcount']; ?>)</a>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</li>
|
||||
<?php
|
||||
endforeach;
|
||||
endif;
|
||||
?>
|
||||
|
||||
<?php if ($list): foreach ($list as $detail): ?>
|
||||
<li>
|
||||
<div style="width:25%; float: left;"> <div class="xwimg"><a href="<?php echo url_rewrite('us/articledetail', array('id' => $detail['id'])); ?>"><img src="<?php echo getImage($detail['picture']); ?>"></a></div></div>
|
||||
<div style="width:72%; float: right;">
|
||||
<div class="xwtit"><a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><?php echo $detail['name']; ?></a></div>
|
||||
|
||||
<div class="xname"><?php echo $detail['writer']; ?> <?php echo getHMStime($detail['createtime'], time()); ?></div>
|
||||
<!-- <div class="detail">对于注重便携HiFi听音发烧友来说,相信提到“飞傲”这个品牌,我想都不会感到陌生,飞傲音频在圈子里一直有着不错口碑,性能方面拥有绝对的优势。近日,飞傲家族中又迎...</div>-->
|
||||
|
||||
|
||||
<div class="fx">
|
||||
<a href="#"><i class="f1"></i>Share</a>
|
||||
<a href="javascript:void(0);" class="addzan" data-id="<?php echo $detail['id']; ?>"><i class="f2"></i>Like(<?php echo $detail['zancount']; ?>)</a>
|
||||
<a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>#ccount"><i class="f3"></i>Comment (<?php echo $detail['commentcount']; ?>)</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="clear"></div>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
<!-- 分页 s -->
|
||||
<?php
|
||||
if ($page) {
|
||||
echo $page;
|
||||
}
|
||||
?>
|
||||
<!-- 分页 e -->
|
||||
<?php endif; ?>
|
||||
</ul>
|
||||
<script>
|
||||
$(function() {
|
||||
$(".newfl .addzan").click(function(event) {
|
||||
event.preventDefault();
|
||||
var love = $(this);
|
||||
var id = love.data("id"); //对应id
|
||||
if (!love.data("zan")) {
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
dataType: "json",
|
||||
url: "<?php echo url('/us/article/zan'); ?>",
|
||||
data: {id: id},
|
||||
cache: false, //不缓存此页面
|
||||
success: function(data) {
|
||||
//console.log(data);
|
||||
if (data.code) {
|
||||
love.data("zan", true);
|
||||
love.html('<i class="f2"></i>Like(' + data.data + ')');
|
||||
}
|
||||
}
|
||||
});
|
||||
} else {
|
||||
alert('You have liked it!');
|
||||
}
|
||||
return false;
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
$pingluns = getDifferentPinglun('ishot', 8);
|
||||
if ($pingluns):
|
||||
?>
|
||||
<div class="newrh">
|
||||
<div class="plun">Wonderful Reviews</div>
|
||||
<ul class="pllist">
|
||||
<?php foreach ($pingluns as $pinglun): ?>
|
||||
<li>
|
||||
<a href="<?php echo url('us/pinglun/lists', ['type' => strtolower($pinglun['typeid']), 'cid' => $pinglun['content_id']]); ?>">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns<?php echo $pinglun['tx']; ?>.jpg"></div>
|
||||
<div class="peo1"><?php echo $pinglun['cname']; ?></div>
|
||||
<div class="peo2"><?php echo $pinglun['createtime']; ?></div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1"><?php echo msubstr($pinglun['content'], 0, 200); ?></div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 新闻列表 e -->
|
||||
|
||||
<!-- bottom s -->
|
||||
{include file="include/bottom" /}
|
||||
<!-- bottom e -->
|
||||
</body>
|
||||
</html>
|
||||
191
app/us/view/article/catelists20230805.phtml
Executable file
191
app/us/view/article/catelists20230805.phtml
Executable file
@@ -0,0 +1,191 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>News-ORICO Global Site</title>
|
||||
{include file="include/head-seo" /}
|
||||
{include file="include/head" /}
|
||||
<script type="text/javascript">
|
||||
var navID = "1";</script>
|
||||
</head>
|
||||
<body>
|
||||
<!--top-->
|
||||
<header class="header-PC header-Index">
|
||||
<div id="header" class="theme-white">
|
||||
{include file="include/top" /}
|
||||
{include file="include/top-header" /}
|
||||
</div>
|
||||
</header>
|
||||
{include file="include/top-header-mobile" /}
|
||||
|
||||
<!--top End-->
|
||||
<?php if ($category['picture']): ?>
|
||||
|
||||
<!-- 轮播 s -->
|
||||
<div class="homeban">
|
||||
<div class="bd">
|
||||
<ul>
|
||||
<li><img src="<?php echo getImage($category['picture']); ?>"/></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 轮播 e -->
|
||||
<div class="swt-Container">
|
||||
<div class="news-vertu">
|
||||
<div class="tab">
|
||||
<?php if (!empty($cate_list)): ?>
|
||||
<?php foreach ($cate_list as $key => $value): ?>
|
||||
<a href="/us/article/category/<?php echo $value['id'] ?>.html" class="<?php if ($category['id'] == $value['id']): ?> on <?php endif; ?>"><?php echo $value['name']; ?><span></span></a>
|
||||
<?php endforeach; ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- 轮播 e -->
|
||||
<?php endif; ?>
|
||||
<!-- 新闻列表 s -->
|
||||
<div class="new">
|
||||
<div class="swt-Container">
|
||||
<ul class="newfl">
|
||||
<?php
|
||||
//$articles = getDifferentArticle('ishot', 3, ['cid' => 1]);
|
||||
if (0):foreach ($articles as $detail):
|
||||
?>
|
||||
<li>
|
||||
<div class="xwimg"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><img src="<?php echo getImage($detail['picture'], 951, 459, 6); ?>"></a></div>
|
||||
<div class="xwtit"><a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><?php echo $detail['name']; ?></a></div>
|
||||
<div class="xname"><?php echo $detail['writer']; ?> published <?php echo getHMStime($detail['createtime'], time()); ?>/key words: <?php echo $detail['tags']; ?></div>
|
||||
<div class="xwcon"><?php echo msubstr($detail['description'], 0, 200); ?></div>
|
||||
|
||||
<div class="detail"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><i></i>Detailed reading</a></div>
|
||||
<div class="fx">
|
||||
<a href="#"><i class="f1"></i>Share</a>
|
||||
<a href="javascript:void(0);" class="addzan" data-id="<?php echo $detail['id']; ?>"><i class="f2"></i>Like(<?php echo $detail['zancount']; ?>)</a>
|
||||
<a href="<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>#ccount"><i class="f3"></i>Comment
|
||||
(<?php echo $detail['commentcount']; ?>)</a>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</li>
|
||||
<?php
|
||||
endforeach;
|
||||
endif;
|
||||
?>
|
||||
|
||||
<?php if ($list): foreach ($list as $detail): ?>
|
||||
<li>
|
||||
<div style="width:25%; float: left;"> <div class="xwimg"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><img src="<?php echo getImage($detail['picture']); ?>"></a></div></div>
|
||||
<div style="width:72%; float: right;">
|
||||
<div class="xwtit"><a href="__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><?php echo $detail['name']; ?></a></div>
|
||||
|
||||
<div class="xname"><?php echo $detail['writer']; ?> <?php echo getHMStime($detail['createtime'], time()); ?></div>
|
||||
<!-- <div class="detail">对于注重便携HiFi听音发烧友来说,相信提到“飞傲”这个品牌,我想都不会感到陌生,飞傲音频在圈子里一直有着不错口碑,性能方面拥有绝对的优势。近日,飞傲家族中又迎...</div>-->
|
||||
<div class="detail"><?php echo msubstr($detail['description'], 0, 150);?></div>
|
||||
|
||||
<div class="fx">
|
||||
<a href="#"><i class="f1"></i>Share</a>
|
||||
<a href="javascript:void(0);" class="addzan" data-id="<?php echo $detail['id']; ?>"><i class="f2"></i>Like(<?php echo $detail['zancount']; ?>)</a>
|
||||
<a href="/us<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>#ccount"><i class="f3"></i>Comment (<?php echo $detail['commentcount']; ?>)</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="clear"></div>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
<!-- 分页 s -->
|
||||
<?php
|
||||
if ($page) {
|
||||
echo $page;
|
||||
}
|
||||
?>
|
||||
<!-- 分页 e -->
|
||||
<?php endif; ?>
|
||||
</ul>
|
||||
<script>
|
||||
$(function() {
|
||||
$(".newfl .addzan").click(function(event) {
|
||||
event.preventDefault();
|
||||
var love = $(this);
|
||||
var id = love.data("id"); //对应id
|
||||
if (!love.data("zan")) {
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
dataType: "json",
|
||||
url: "<?php echo url('/us/article/zan'); ?>",
|
||||
data: {id: id},
|
||||
cache: false, //不缓存此页面
|
||||
success: function(data) {
|
||||
//console.log(data);
|
||||
if (data.code) {
|
||||
love.data("zan", true);
|
||||
love.html('<i class="f2"></i>Like(' + data.data + ')');
|
||||
}
|
||||
}
|
||||
});
|
||||
} else {
|
||||
alert('You have liked it!');
|
||||
}
|
||||
return false;
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
$pingluns = getDifferentPinglun('ishot', 8);
|
||||
if ($pingluns):
|
||||
?>
|
||||
<div class="newrh">
|
||||
<div class="plun">Wonderful Reviews</div>
|
||||
<ul class="pllist">
|
||||
<?php foreach ($pingluns as $pinglun): ?>
|
||||
<li>
|
||||
<a href="<?php echo url('us/pinglun/lists', ['type' => strtolower($pinglun['typeid']), 'cid' => $pinglun['content_id']]); ?>">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns<?php echo $pinglun['tx']; ?>.jpg"></div>
|
||||
<div class="peo1"><?php echo $pinglun['cname']; ?></div>
|
||||
<div class="peo2"><?php echo $pinglun['createtime']; ?></div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1"><?php echo msubstr($pinglun['content'], 0, 200); ?></div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 新闻列表 e -->
|
||||
|
||||
<!-- bottom s -->
|
||||
{include file="include/bottom" /}
|
||||
<!-- bottom e -->
|
||||
<script>
|
||||
$(function(){
|
||||
$(".news-vertu .tab a").click(function(){
|
||||
$(this).addClass('on').siblings().removeClass('on');
|
||||
var index = $(this).index();
|
||||
number = index;
|
||||
$('.news-vertu .content li').hide();
|
||||
$('.news-vertu .content li:eq('+index+')').show();
|
||||
});
|
||||
|
||||
var auto = 1; //等于1则自动切换,其他任意数字则不自动切换
|
||||
if(auto ==1){
|
||||
var number = 0;
|
||||
var maxNumber = $('.news-vertu .tab a').length;
|
||||
function autotab(){
|
||||
number++;
|
||||
number == maxNumber? number = 0 : number;
|
||||
$('.news-vertu .tab a:eq('+number+')').addClass('on').siblings().removeClass('on');
|
||||
$('.news-vertu .content ul li:eq('+number+')').show().siblings().hide();
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
224
app/us/view/article/detail.phtml
Executable file
224
app/us/view/article/detail.phtml
Executable file
@@ -0,0 +1,224 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
{include file="include/head" /}
|
||||
<link rel="stylesheet" type="text/css" href="__PUBLIC__/weben/css/cooperation.css">
|
||||
<script type="text/javascript">
|
||||
var navID = "1";
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<!--top-->
|
||||
<!--top-->
|
||||
<header class="header-PC header-Index">
|
||||
<div id="header" class="theme-white">
|
||||
{include file="include/top" /}
|
||||
{include file="include/top-header" /}
|
||||
</div>
|
||||
</header>
|
||||
{include file="include/top-header-mobile" /}
|
||||
<!--top End-->
|
||||
|
||||
<!-- 详情页 s -->
|
||||
<div class="content">
|
||||
<input type="hidden" class="b_id">
|
||||
<div class="detail_box clearfix">
|
||||
<div class="blog_detail" style="margin-top:2.6rem">
|
||||
<div class="blog_title">
|
||||
<h2><?php echo $detail['name']; ?></h2>
|
||||
<p>Posted on <?php echo date("M j, Y",$detail['createtime']); ?></p>
|
||||
</div>
|
||||
<div class="blog_content">
|
||||
|
||||
<?php echo $detail['content']; ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="share_box">
|
||||
<div class="blog_share">
|
||||
<h3>SHARE</h3>
|
||||
<ul class="share_list clearfix">
|
||||
<!-- Go to www.addthis.com/dashboard to customize your tools -->
|
||||
|
||||
<li><a target="_blank" href="https://www.facebook.com/sharer/sharer.php?u=__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>&t=1709023114"><img src="/frontend/weben/images/blog/share1.png"/></a></li>
|
||||
<li><a target="_blank" href="https://www.linkedin.com/shareArticle?mini=true&ro=true&title=<?php echo $detail['name']; ?>&url=__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>&source=&summary=&armin=armin"><img src="/frontend/weben/images/blog/share2.png"/></a></li>
|
||||
<li><a target="_blank" href="http://www.facebook.com/sharer/sharer.php?u=__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>"><img src="/frontend/weben/images/blog/share3.png"/></a></li>
|
||||
<li><a href="http://www.reddit.com/submit?url=__ORICOROOT__<?php echo url_rewrite('articledetail', array('id' => $detail['id'])); ?>&title=<?php echo $detail['name']; ?>" rel="nofollow" title="submit to reddit" target="_blank"><img src="/frontend/weben/images/blog/share4.png"/></a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="repply">
|
||||
<h3>Leave a Reply</h3>
|
||||
<form>
|
||||
<span>Name</span>
|
||||
<input class="form-control itinp new_name" type="text" name="name" style="text-indent: 10px;"/>
|
||||
<span>Email</span>
|
||||
<input class="form-control itinp new_email" type="email" name="email" style="text-indent: 10px; margin-bottom:0;"/>
|
||||
<p style="color: #C6C7C9; font-size: 0.75rem; margin-bottom: 0.625rem;">Your email address will not be pulished.</p>
|
||||
<span>Comment</span>
|
||||
<textarea class="form-control itinp new_comment" rows="3" style="text-indent: 10px;width: 98%; margin-top: 0.625rem;margin-bottom: 0.625rem;border: 1px solid #DBDBDB;" name="comment"></textarea>
|
||||
<div class="comment_btn" style="color:#ffffff;">POST COMMENT</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="comment">
|
||||
<h3>Leave a Comment</h3>
|
||||
<form class="comment_form clearfix">
|
||||
<div style="margin-right: 2.5rem;">Name:<br/>
|
||||
<input class="new_name" type="text" name="name" style="text-indent: 10px;"/>
|
||||
</div>
|
||||
<div>Email:<br/>
|
||||
<input class="new_email" type="email" name="email" style="text-indent: 10px;"/>
|
||||
<p style="color: #C6C7C9; font-size: 0.75rem; margin-bottom: 0.625rem; font-weight: 400;">Your email address will not be pulished.</p>
|
||||
</div>
|
||||
<div class="comment_area">Comment:<br/>
|
||||
<textarea class="new_comment" style="text-indent: 10px;height: 8.125rem;border: 1px solid #DBDBDB !important;" name="comment"></textarea>
|
||||
</div>
|
||||
<div class="comment_btn" style="width: 21.25rem; margin-left: 2.5rem;color:#ffffff;">POST COMMENT</div>
|
||||
</form>
|
||||
</div> -->
|
||||
|
||||
<div class="xq">
|
||||
<?php
|
||||
$articles = getDifferentArticle('default', 3, ['id' => ['neq', $detail['id']]], ['createtime'=>'desc']);
|
||||
if ($articles):
|
||||
|
||||
?>
|
||||
<!-- 猜您喜欢 -->
|
||||
<div class="love">
|
||||
<div class="love1">
|
||||
<p>Recommended for you</p>
|
||||
<p><img src="/frontend/web/images/1line.png"></p>
|
||||
</div>
|
||||
<ul class="love2">
|
||||
<?php foreach ($articles as $article): ?>
|
||||
<?php
|
||||
if($article['jump_link'] == ''){
|
||||
$rlink = "__ORICOROOT__/article/detail/".$article['id'].".html";
|
||||
}
|
||||
else{
|
||||
$rlink = $article['jump_link'];
|
||||
}
|
||||
?>
|
||||
<li>
|
||||
<a href="<?php echo $rlink; ?>">
|
||||
<div class="lvimg"><img src="<?php echo getImage($article['picture']); ?>"></div>
|
||||
<p class="lvtit"><?php echo msubstr($article['name'], 0, 40); ?></p>
|
||||
</a>
|
||||
</li>
|
||||
|
||||
<?php endforeach; ?>
|
||||
<div class="clear"></div>
|
||||
</ul>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
|
||||
|
||||
$(function(){
|
||||
//悬浮表单
|
||||
$(window).scroll(function(){
|
||||
var s_top = Number($(this).scrollTop()); // 获取滚动条,滚动刻度
|
||||
var showTop = Number($(".share_box").height());
|
||||
|
||||
var pTop = Number($(".xq").offset().top);
|
||||
|
||||
if((pTop-s_top-80) >= showTop ){
|
||||
$(".share_box").removeAttr("style"); // 删除属性,让他释放
|
||||
|
||||
}else{
|
||||
//nsole.log(s_top,showTop,pTop,$(window).scrollTop());
|
||||
|
||||
$('.share_box').css("position","absolute"); // 添加属性,让他固定
|
||||
$('.share_box').css('top',pTop-showTop-20);
|
||||
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
// 提交表单
|
||||
$('.comment_btn').click(function(){
|
||||
var new_name = $('.new_name').val();
|
||||
var new_email = $('.new_email').val();
|
||||
var new_comment = $('.new_comment').val();
|
||||
|
||||
console.log('message');
|
||||
if (new_name == '') {
|
||||
//alert("The Name is Empty!");
|
||||
|
||||
$('.new_name').addClass('error');
|
||||
$('.new_name').next('span').removeClass('hide');
|
||||
return false;
|
||||
}else{
|
||||
$('.new_name').removeClass('error');
|
||||
$('.new_name').next('span').addClass('hide');
|
||||
}
|
||||
|
||||
|
||||
if (new_comment == '') {
|
||||
//alert("The Comment is Empty!");
|
||||
|
||||
$('.new_comment').addClass('error');
|
||||
$('.new_comment').next('span').removeClass('hide');
|
||||
return false;
|
||||
}else{
|
||||
$('.new_comment').removeClass('error');
|
||||
$('.new_comment').next('span').addClass('hide');
|
||||
}
|
||||
|
||||
if (new_email == '') {
|
||||
$('.new_email').addClass('error');
|
||||
$('.new_email').next('span').removeClass('hide');
|
||||
}
|
||||
else{
|
||||
if (/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/.test(new_email) == false) {
|
||||
$('.new_email').addClass('error');
|
||||
$('.new_email').next('span').removeClass('hide');
|
||||
return false;
|
||||
}
|
||||
else{
|
||||
$('.new_email').removeClass('error');
|
||||
$('.new_email').next('span').addClass('hide');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
var bid = "<?php echo $detail['id'];?>";
|
||||
//点击创建申请块
|
||||
if(new_name && new_email && new_comment && bid) {
|
||||
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: "/us/article/addcomment",
|
||||
data: {'name':new_name, 'email':new_email,'comment':new_comment,'article_id':bid},
|
||||
dataType: "json",
|
||||
success: function(data){
|
||||
if(data.code == 200) {
|
||||
alert("留言提交成功!");
|
||||
$(".new_name").val("");
|
||||
$(".new_email").val("");
|
||||
$(".new_comment").val("");
|
||||
}
|
||||
else{
|
||||
alert(data.msg);
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
})
|
||||
})
|
||||
</script>
|
||||
<!-- bottom s -->
|
||||
{include file="include/bottom" /}
|
||||
<!-- bottom e -->
|
||||
</body>
|
||||
</html>
|
||||
151
app/us/view/article/lists.phtml
Executable file
151
app/us/view/article/lists.phtml
Executable file
@@ -0,0 +1,151 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
{include file="include/head" /}
|
||||
<script type="text/javascript">
|
||||
var navID = "1";
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<!--top-->
|
||||
<!--top-->
|
||||
<header class="header-PC header-Index">
|
||||
<div id="header" class="theme-white">
|
||||
{include file="include/top" /}
|
||||
{include file="include/top-header" /}
|
||||
</div>
|
||||
</header>
|
||||
{include file="include/top-header-mobile" /}
|
||||
|
||||
<!--top End-->
|
||||
<!-- 轮播 s -->
|
||||
<div class="homeban banner-other">
|
||||
<div class="bd">
|
||||
<ul>
|
||||
<li><a href="#"><img src="__PUBLIC__/web/uploadfiles/image/ban2.jpg"/></a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 轮播 e -->
|
||||
|
||||
<!-- 新闻列表 s -->
|
||||
<div class="new">
|
||||
<div class="w1440">
|
||||
<div class="vtext">
|
||||
<p class="tl1">News</p>
|
||||
<p class="tl2"></p>
|
||||
</div>
|
||||
<?php if ($list): ?>
|
||||
<ul class="newfl">
|
||||
<?php foreach ($list as $detail): ?>
|
||||
<li>
|
||||
<div class="xwtit"><a href="<?php echo url_rewrite('us/articledetail', array('id' => $detail['id'])); ?>"><?php echo $detail['name']; ?></a></div>
|
||||
<div class="xname"><?php echo $detail['writer']; ?> published <?php echo getHMStime($detail['createtime'], time()); ?>/key words:<?php echo $detail['tags']; ?></div>
|
||||
<div class="xwcon"><?php echo msubstr($detail['description'], 0, 200); ?></div>
|
||||
<div class="xwimg"><img src="<?php echo getImage($detail['picture'], 951, 459, 6); ?>"></div>
|
||||
<div class="detail"><a href="<?php echo url_rewrite('us/articledetail', array('id' => $detail['id'])); ?>"><i></i>Detailed reading</a></div>
|
||||
<div class="fx">
|
||||
<a href="#"><i class="f1"></i>Share</a>
|
||||
<a href="#"><i class="f2"></i>Favorite</a>
|
||||
<a href="#"><i class="f3"></i>Comment (15)</a>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
<!-- 分页 s -->
|
||||
<?php
|
||||
if ($page) {
|
||||
echo $page;
|
||||
}
|
||||
?>
|
||||
<!-- 分页 e -->
|
||||
</ul>
|
||||
|
||||
<?php endif; ?>
|
||||
<div class="newrh">
|
||||
<div class="plun">Wonderful Reviews</div>
|
||||
<ul class="pllist">
|
||||
<li>
|
||||
<a href="#">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns1.jpg"></div>
|
||||
<div class="peo1">Visitor</div>
|
||||
<div class="peo2">2018-09-05</div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1">ELITE916 of PHANTEKS, JD 7K supports ATX&ITX dual systems . And I remember 916 dual-system needs two power adapters. </div>
|
||||
<div class="plrh2">REVOLTX power adapter and EVOLVX host. That’s friendly for users needing two systems… </div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns2.jpg"></div>
|
||||
<div class="peo1">Visitor</div>
|
||||
<div class="peo2">2018-09-05</div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1">ELITE916 of PHANTEKS, JD 7K supports ATX&ITX dual systems . And I remember 916 dual-system needs two power adapters. </div>
|
||||
<div class="plrh2">REVOLTX power adapter and EVOLVX host. That’s friendly for users needing two systems… </div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns3.jpg"></div>
|
||||
<div class="peo1">Visitor</div>
|
||||
<div class="peo2">2018-09-05</div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1">ELITE916 of PHANTEKS, JD 7K supports ATX&ITX dual systems . And I remember 916 dual-system needs two power adapters.
|
||||
</div>
|
||||
<div class="plrh2">REVOLTX power adapter and EVOLVX host. That’s friendly for users needing two systems… </div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns4.jpg"></div>
|
||||
<div class="peo1">Visitor</div>
|
||||
<div class="peo2">2018-09-05</div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1">ELITE916 of PHANTEKS, JD 7K supports ATX&ITX dual systems . And I remember 916 dual-system needs two power adapters. </div>
|
||||
<div class="plrh2">REVOLTX power adapter and EVOLVX host. That’s friendly for users needing two systems… </div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">
|
||||
<div class="plfl">
|
||||
<div class="plimg"><img src="__PUBLIC__/web/uploadfiles/image/ns5.jpg"></div>
|
||||
<div class="peo1">Visitor</div>
|
||||
<div class="peo2">2018-09-05</div>
|
||||
</div>
|
||||
<div class="plrh">
|
||||
<div class="plrh1">ELITE916 of PHANTEKS, JD 7K supports ATX&ITX dual systems . And I remember 916 dual-system needs two power adapters. </div>
|
||||
<div class="plrh2">REVOLTX power adapter and EVOLVX host. That’s friendly for users needing two systems… </div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 新闻列表 e -->
|
||||
|
||||
<!-- bottom s -->
|
||||
{include file="include/bottom" /}
|
||||
<!-- bottom e -->
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user