Exemplo n.º 1
0
						<?php 
    }
    ?>
						<li><i class="glyphicon glyphicon-th-list"></i></li>
						<li>
							<a href="<?php 
    echo U('article/index/term?id=' . mc_get_meta($val['id'], 'term'));
    ?>
">
								<?php 
    echo mc_get_page_field(mc_get_meta($val['id'], 'term'), 'title');
    ?>
							</a>
						</li>
					</ul>
					<div id="entry">
						<?php 
    echo mc_magic_out($val['content']);
    ?>
					</div>
					<hr>
					<?php 
    echo W("Comment/index", array($val['id']));
    ?>
				</div>
			</div>
		</div>
	</div>
<?php 
}
mc_template_part('footer');
Exemplo n.º 2
0
			<div class="col-sm-9">
				<div class="form-group">
					<label>
						群组名称
					</label>
					<input name="title" type="text" class="form-control" placeholder="" value="<?php 
echo mc_get_page_field($_GET['id'], 'title');
?>
">
				</div>
				<div class="form-group">
					<label>
						群组描述
					</label>
					<textarea name="content" class="form-control" rows="3"><?php 
echo mc_magic_out(mc_get_page_field($_GET['id'], 'content'));
?>
</textarea>
				</div>
				<input name="id" type="hidden" value="<?php 
echo $_GET['id'];
?>
">
				<button type="submit" class="btn btn-warning btn-block">
					保存
				</button>
				
			</div>
			<div class="col-sm-3">
				<div class="form-group">
					<label>
Exemplo n.º 3
0
    echo $val['title'];
    ?>
"></a>
								<div class="caption">
									<h3 class="mt-0">
										<a href="<?php 
    echo mc_get_url($val['id']);
    ?>
"><?php 
    echo $val['title'];
    ?>
</a>
									</h3>
									<p>
										<?php 
    echo mc_cut_str(strip_tags(mc_magic_out($val['content'])), 70);
    ?>
									</p>
									<ul class="list-inline">
										<li><i class="glyphicon glyphicon-star-empty"></i> <?php 
    echo mc_shoucang_count($val['id']);
    ?>
</li>
										<li><i class="glyphicon glyphicon-time"></i> <?php 
    echo date('Y-m-d', $val['date']);
    ?>
</li>
									</ul>
								</div>
						</div>
					<?php 
Exemplo n.º 4
0
				<form class="inline hidden-xs" method="post" action="<?php 
            echo U('home/perform/comment_delete');
            ?>
">
					<button type="submit" class="btn btn-danger btn-xs pull-right">删除</button>
					<input type="hidden" name="id" value="<?php 
            echo $val['id'];
            ?>
">
				</form>
				<?php 
        }
        ?>
			</h4>
			<p><?php 
        echo mc_magic_out($val['action_value']);
        ?>
</p>
			<a class="btn btn-default btn-xs btn-huifu" href="#comment-textarea" huifu-data="<?php 
        echo $val['id'];
        ?>
 ">回复</a>
			<?php 
        $comment2 = M('action')->where("page_id='" . $val['id'] . "' AND action_key='comment2'")->select();
        if ($comment2) {
            ?>
			<ul class="mt-20 list-unstyled">
				<?php 
            foreach ($comment2 as $val2) {
                ?>
				<li id="comment-<?php 
Exemplo n.º 5
0
                    ?>
										<p><?php 
                    echo mc_cut_str(strip_tags(mc_magic_out(mc_get_page_field($page_id, 'content'))), 250);
                    ?>
</p>
										<?php 
                }
                ?>
									<?php 
            }
            ?>
								<?php 
        } elseif ($key == 'comment' || $key == 'comment2') {
            ?>
								<div class="mb-10"><?php 
            echo mc_magic_out($value);
            ?>
</div>
								<?php 
        } elseif ($key == 'wish') {
            ?>
								<p>支持金额:<span class="text-danger"><?php 
            echo $value;
            ?>
</span>元</p>
								<?php 
        }
        ?>
								<p class="post-info">
									<i class="glyphicon glyphicon-time"></i><?php 
        echo date('Y-m-d H:i:s', $val['date']);
Exemplo n.º 6
0
function mc_seo()
{
    $nofollow = false;
    if (MODULE_NAME == 'Home') {
        if (CONTROLLER_NAME == 'Index') {
            if (ACTION_NAME == 'index') {
                if ($_GET['keyword'] || $_GET['page']) {
                    $nofollow = true;
                } else {
                    $keywords = mc_option('home_keywords');
                    $description = mc_option('home_description');
                }
            } else {
                $nofollow = true;
            }
        } else {
            $nofollow = true;
        }
    } elseif (MODULE_NAME == 'Pro') {
        if (ACTION_NAME == 'index') {
            $keywords = mc_option('pro_keywords');
            $description = mc_option('pro_description');
        } elseif (ACTION_NAME == 'term') {
            $keywords = mc_get_page_field($_GET['id'], 'title');
            $description = '';
        } elseif (ACTION_NAME == 'single') {
            if (mc_get_meta($_GET['id'], 'keywords')) {
                $keywords = mc_get_meta($_GET['id'], 'keywords');
            } else {
                $keywords = mc_get_page_field($_GET['id'], 'title');
            }
            if (mc_get_meta($_GET['id'], 'description')) {
                $description = mc_cut_str(strip_tags(mc_get_meta($_GET['id'], 'description')), 152);
            } else {
                $description = mc_cut_str(strip_tags(mc_magic_out(mc_get_page_field($_GET['id'], 'content'))), 152);
            }
        } else {
            $nofollow = true;
        }
    } elseif (MODULE_NAME == 'Post') {
        if (CONTROLLER_NAME == 'Group') {
            if (ACTION_NAME == 'index') {
                $keywords = mc_option('group_keywords');
                $description = mc_option('group_description');
            } elseif (ACTION_NAME == 'single') {
                $keywords = mc_get_page_field($_GET['id'], 'title');
                $description = mc_cut_str(strip_tags(mc_magic_out(mc_get_page_field($_GET['id'], 'content'))), 152);
            } else {
                $nofollow = true;
            }
        } else {
            $keywords = mc_get_page_field($_GET['id'], 'title');
            $description = mc_cut_str(strip_tags(mc_magic_out(mc_get_page_field($_GET['id'], 'content'))), 152);
        }
    } elseif (MODULE_NAME == 'Article') {
        if (ACTION_NAME == 'index') {
            $keywords = mc_option('article_keywords');
            $description = mc_option('article_description');
        } elseif (ACTION_NAME == 'term') {
            $keywords = mc_get_page_field($_GET['id'], 'title');
            $description = '';
        } elseif (ACTION_NAME == 'single') {
            $keywords = mc_get_page_field($_GET['id'], 'title');
            $description = mc_cut_str(strip_tags(mc_magic_out(mc_get_page_field($_GET['id'], 'content'))), 152);
        } else {
            $nofollow = true;
        }
    } elseif (MODULE_NAME == 'User') {
        if (CONTROLLER_NAME == 'Index') {
            $display_name = mc_user_display_name($_GET['id']);
            if (ACTION_NAME == 'index') {
                $keywords = mc_get_page_field($_GET['id'], 'title');
                $description = mc_cut_str(strip_tags(mc_magic_out(mc_get_page_field($_GET['id'], 'content'))), 152);
            } else {
                $nofollow = true;
            }
        } else {
            $nofollow = true;
        }
    } else {
        $nofollow = true;
    }
    if ($nofollow) {
        $meta .= '<meta name="robots" content="noindex,nofollow" />
';
    } else {
        $meta .= '<meta name="keywords" content="' . $keywords . '">
';
        $meta .= '<meta name="description" content="' . $description . '">
';
    }
    return $meta;
}
Exemplo n.º 7
0
					<div id="nothing">
						暂时没有任何群组,去<a href="<?php 
        echo U('publish/index/add_group');
        ?>
">建立第一个群组</a>吧!
					</div>
					<?php 
    }
    ?>
				</div>
				<div class="col-sm-6 col-md-4 col col-3 hidden-sm">
					<h4 class="title">
						<i class="icon-bullhorn"></i> 网站公告
					</h4>
					<div class="panel panel-default">
						<div class="panel-body">
							<?php 
    echo mc_magic_out(mc_option('gonggao'));
    ?>
						</div>
					</div>
				</div>
			</div>
		</div>
		
		<?php 
}
?>
	</div>
<?php 
mc_template_part('footer');