Answers for "copyright year php"

PHP
2

automatic years php

&copy; <?php echo date("Y"); ?>
Posted by: Guest on April-26-2020
0

php copyright footer

© <?php echo date("Y"); ?> Copyright.
Posted by: Guest on August-18-2020
1

php wp copyright and year

function comicpress_copyright() // returns:  (c) My blog Name 2014 - 2021
{
    global $wpdb;
    $copyright_dates = $wpdb->get_results("
    SELECT
    YEAR(min(post_date_gmt)) AS firstdate,
    YEAR(max(post_date_gmt)) AS lastdate
    FROM
    $wpdb->posts
    WHERE
    post_status = 'publish'
    ");
    $output = '';
    if ($copyright_dates) {
        $copyright = "&copy; " . get_bloginfo('name') . ' ' . $copyright_dates[0]->firstdate;
        if ($copyright_dates[0]->firstdate != $copyright_dates[0]->lastdate) {
            $copyright .= '-' . $copyright_dates[0]->lastdate;
        }
        $output = $copyright;
    }
    return $output;
}
Posted by: Guest on July-24-2021
1

automatic years php

&copy; 2008-<?php echo date("Y"); ?> // 2008-20??
Posted by: Guest on April-26-2020

Browse Popular Code Answers by Language