403Webshell
Server IP : 69.72.244.102  /  Your IP : 216.73.216.164
Web Server : LiteSpeed
System : Linux s3434.fra1.stableserver.net 4.18.0-513.24.1.lve.2.el8.x86_64 #1 SMP Fri May 24 12:42:50 UTC 2024 x86_64
User : konzalta ( 1271)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /proc/thread-self/cwd/wp-content/plugins/portx-core/include/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/thread-self/cwd/wp-content/plugins/portx-core/include/post-view.php
<?php


function getPostViews($postID){
    $count_key = 'post_views_count';
    $count = get_post_meta($postID, $count_key, true);
    if($count==''){
        delete_post_meta($postID, $count_key);
        add_post_meta($postID, $count_key, '0');
        return "0";
    }
    return $count;
}
function setPostViews($postID) {
    $count_key = 'post_views_count';
    $count = get_post_meta($postID, $count_key, true);
    if($count==''){
        $count = 0;
        delete_post_meta($postID, $count_key);
        add_post_meta($postID, $count_key, '0');
    }else{
        $count++;
        update_post_meta($postID, $count_key, $count);
    }
    return false;
}
// Remove issues with prefetching adding extra views


function harry_blog_single_social(){
    $post_url = get_the_permalink();
 ?>    
    <div class="postbox__share text-xl-end">
        <span><?php echo esc_html__('Share On:', 'harry');?></span>
        <a href="https://www.linkedin.com/shareArticle?mini=true&url=<?php echo esc_url($post_url);?>" target="_blank"><i class="fab fa-linkedin tp-linkedin"></i></a>
        <a href="https://www.facebook.com/sharer/sharer.php?u=<?php echo esc_url($post_url);?>" target="_blank""><i class="fab fa-facebook tp-facebook" ></i></a>
        <a href="https://twitter.com/share?url=<?php echo esc_url($post_url);?>" target="_blank"><i class="fab fa-twitter tp-twitter"></i></a>
    </div>
   <?php return false;
}

// harry_product_single_social
function harry_product_single_social(){
    $post_url = get_the_permalink();
 ?>    
    <div class="product__details-share">
        <span><?php echo esc_html__('Share On:', 'harry');?></span>
        <a href="https://www.linkedin.com/shareArticle?mini=true&url=<?php echo esc_url($post_url);?>" target="_blank"><i class="fab fa-linkedin-in tp-linkedin"></i></a>
        <a href="https://www.facebook.com/sharer/sharer.php?u=<?php echo esc_url($post_url);?>" target="_blank""><i class="fab fa-facebook-f tp-facebook" ></i></a>
        <a href="https://twitter.com/share?url=<?php echo esc_url($post_url);?>" target="_blank"><i class="fab fa-twitter tp-twitter"></i></a>
    </div>
   <?php return false;
}


function gp_reading_time() {
    global $post;
    $article = get_post_field( 'post_content', $post->ID ); //gets full text from article
    $wordcount = str_word_count( strip_tags( $article ) ); //removes html tags
    $time = ceil($wordcount / 250); //takes rounded of words divided by 250 words per minute
        
    if ($time == 1) { //grammar conversion
        $label = " minute";
    } else {
        $label = " minutes";
    }
        
    $totalString = $time . $label; //adds time with minute/minutes label
    return $totalString;
        
    }

    function theme_domain_reading_time() {
        global $post;
        // load the content
        $thecontent = $post->post_content;
        // count the number of words
        $words = str_word_count( strip_tags( $thecontent ) );
        // rounding off and deviding per 200 words per minute
        $m = floor( $words / 50 );
    
        // calculate the amount of read time
        $readtime = $m . ' min' . ( $m == 1 ? '' : 's' ) ;
    
        // return the readtime
        return $readtime;
}

Youez - 2016 - github.com/yon3zu
LinuXploit