コード例 #1
0
ファイル: stories.php プロジェクト: patilstar/HMVC-WITH-CI
 public function share_send_mail()
 {
     /*---User Mail ---*/
     $user_id = $this->session->userdata("_current_user_id");
     $user_result = user_allinfo_id($user_id);
     $mail_from = $user_result['email_id'];
     $mail_to = $this->input->post('data_value');
     $subject = $this->input->post('subject');
     $message = $this->input->post('message');
     $config = array('mailtype' => 'html', 'charset' => 'iso-8859-1', 'wordwrap' => TRUE);
     $this->load->library('email', $config);
     $this->email->set_newline("\r\n");
     $this->email->from($mail_from);
     $this->email->to($mail_to);
     $this->email->subject($subject);
     $this->email->message($message);
     $this->email->send();
     /*---End USER Mail ---*/
     $msg = "Email Sent to your Friend successfully";
     echo $msg;
 }
コード例 #2
0
    function comments_data_id($story_id, $comment_id)
    {
        $ci =& get_instance();
        $pop = '';
        $html = '  <div id="comment_show_' . $comment_id . '">';
        $comment_reply = $ci->db->query("select * from comments where section_type_id='" . $story_id . "' and section_type='2' and parent_comment_id='" . $comment_id . "' order by id desc")->result_array();
        foreach ($comment_reply as $comment_reply_val) {
            $comment_reply_user = user_allinfo_id($comment_reply_val['user_id']);
            if ($ci->session->userdata('user_logged') != '') {
                $htmlsecondreply = 'onclick="increase_comment(3,' . $comment_reply_val['id'] . ',' . $ci->session->userdata('_current_user_id') . ');"';
            } else {
                $htmlsecondreply = 'data-toggle="modal" data-target="#common-form"';
            }
            $html .= '<div class="comment-box-css-reply">
					<div class="col-lg-1 col-md-2 col-sm-2">
					<a href="javascript:;"  class="avatar-image-css">' . username_photo_by_id($comment_reply_val['user_id']) . '
					</a>
					</div>
					<div class="col-lg-11 col-md-10 col-sm-10">
					<div class="comment-main-box">
					<div class="name-user">' . $comment_reply_user['first_name'] . ' ' . $comment_reply_user['last_name'] . '<span class="color-grey">  ' . $comment_reply_user['professional_skills'] . ' </span></div> 
					<p>' . $comment_reply_val['comments'] . '</p>
					<div class="share-list">
					<a ' . $htmlsecondreply . ' href="javascript:;" ><i class="fa  fa-caret-up"></i>Upvote <span id="comments_3_' . $comment_reply_val['id'] . '">' . vote_count_by_id('3', $comment_reply_val['id']) . '</span> </a>
					<a href="javascript:;" class="days-after">' . get_days_count_from_dates($comment_reply_val['created_date'], date('Y-m-d')) . '</a>
					</div>
					</div> 
					</div>
					</div>  ';
        }
        $html .= ' <div> ';
        return $html;
    }
コード例 #3
0
  <!--======  Story Main Content Section Start ======-->
    
<?php 
$sd_user = user_allinfo_id($res['user_id']);
$twitter_url = base_url() . 'stories/show/' . $res['url_slug'];
?>
       <div class="story-main-right">
         <button data-dismiss="modal" class="close back-to-story1" type="button">×</button>
                  <div class="col-lg-12 col-md-12 col-sm-12">
                      <div class="stories-list-content common-new">
                            <div class="stories-content-top common-new">
                                
                              <div class="col-lg-12 col-md-12 col-sm-12  pro-left">
                                
                                <h4 style="cursor: default;"><?php 
echo $res['title'];
?>
</h4>
                                 
                              </div>
                              
                              <div class="story-main-left">
                <div class="col-lg-12 col-md-12 col-sm-12 main-info-css">
                  <div class="story-con-user common-new">
                      
                      

                      <div class="story-con-img">
                        <a href="<?php 
echo base_url();
?>
コード例 #4
0
ファイル: story_view.php プロジェクト: patilstar/HMVC-WITH-CI
    echo 'no record found';
}
?>
        </ul>
            </div>
            </div>
            </div>
            <div class="col-lg-8 col-md-8 col-sm-12 stories-main-box one-page scrolling-divs">
           <div class="stories-right">
                <div class="stories-main-list">
                    
<?php 
if (is_array($res) && !empty($res)) {
    $r = 1;
    foreach ($res as $val) {
        $story_user = user_allinfo_id($val['user_id']);
        $twitter_url = base_url() . 'stories/show/' . $val['url_slug'];
        ?>
 <div class="stories-list-content common-new" id="story-<?php 
        echo $r;
        ?>
">
                    <div class="stories-content-top common-new">
                        <div class="col-lg-1 col-md-1 col-sm-2 col-xs-2 voting-css pro-right">
                               <?php 
        $onclick_right = array('user_id' => $this->session->userdata('user_logged'), 'section_title' => $val['title'], 'section_type' => '2', 'section_type_action' => 'upvote', 'section_action_id' => $val['id']);
        ?>

                          <a href="javascript:;" <?php 
        echo onclick_upvote($onclick_right);
        ?>
コード例 #5
0
        function comments_data_id_col($story_id, $comment_id, $limit = '0')
        {
            $ci =& get_instance();
            $pop = '';
            if ($limit > 0) {
                $limit_data = 'LIMIT ' . $limit;
            } else {
                $limit_data = '';
            }
            $html2 = '  <div id="comment_show_' . $comment_id . '">';
            $comment_reply = $ci->db->query("select * from comments where section_type_id='" . $story_id . "' and section_type='0' and parent_comment_id='" . $comment_id . "' order by id desc {$limit_data}")->result_array();
            foreach ($comment_reply as $comment_reply_val) {
                $user_link1 = base_url() . 'usersinfo/' . $comment_reply_val['user_id'];
                $comment_reply_user = user_allinfo_id($comment_reply_val['user_id']);
                $onclick_comment2 = array('user_id' => $ci->session->userdata('user_logged'), 'section_title' => $comment_reply_val['comments'], 'section_type' => '3', 'section_type_action' => 'upvote', 'section_action_id' => $comment_reply_val['id']);
                $vote2 = vote_count_by_id('3', $comment_reply_val['id']);
                $vote_msg2 = $vote2 > 0 ? '<span id="comment_3_' . $comment_reply_val['id'] . '">' . $vote2 . '</span>' : '<span id="comment_3_' . $comment_reply_val['id'] . '">Upvote</span>';
                $html2 .= '<div class="comment-box-css-reply">
					<div class="col-lg-1 col-md-2 col-sm-2">
					<a href="' . $user_link1 . '"  class="avatar-image-css" target="_blank">' . username_photo_by_id($comment_reply_val['user_id']) . '
					</a>
					</div>
					<div class="col-lg-11 col-md-10 col-sm-10">
					<div class="comment-main-box">
					<div class="name-user"><a href="' . base_url() . 'usersinfo/' . $comment_reply_user['id'] . '" target="_blank" >' . $comment_reply_user['first_name'] . ' ' . $comment_reply_user['last_name'] . '</a><span class="color-grey">  ' . $comment_reply_user['professional_skills'] . ' </span></div> 
					<p>' . $comment_reply_val['comments'] . '</p>
					<div class="share-list">
					<a ' . onclick_upvote($onclick_comment2) . ' href="javascript:;" ><i class="fa  fa-caret-up"></i>' . $vote_msg2 . '</a>

					<a href="javascript:;" class="days-after">' . get_days_count_from_dates($comment_reply_val['created_date'], date('Y-m-d')) . '</a>
					</div>
					</div> 
					</div>
					</div>  ';
            }
            $html2 .= ' </div> ';
            return $html2;
        }
コード例 #6
0
ファイル: users_view.php プロジェクト: patilstar/HMVC-WITH-CI
                         
                         </div>
                       
                       </div>




<div class="col-lg-10 col-md-10 col-lg-offset-1 col-md-offset-1" style="display:none;" id="divlist">
                                <div class="stories-right">
                                <div class="stories-main-list">

                                  <?php 
if (is_array($users_story) && !empty($users_story)) {
    foreach ($users_story as $users_story_val) {
        $story_user = user_allinfo_id($users_story_val['user_id']);
        ?>
                              <div class="stories-list-content common-new">
                                <div class="stories-content-top common-new">
                                    <div class="col-lg-1 col-md-1 col-sm-2 col-xs-2 voting-css pro-left">
                                      <a class="vote-box active" href="javascript:;" <?php 
        if ($this->session->userdata('user_logged') != '') {
            ?>
                            onclick="increase('2','<?php 
            echo $users_story_val['id'];
            ?>
','<?php 
            echo $this->session->userdata('_current_user_id');
            ?>
');"
                            <?php