copyright dynamique avec wordpress

Solutions on MaxInterview for copyright dynamique avec wordpress by the best coders in the world

showing results for - "copyright dynamique avec wordpress"
Valeria
02 Jun 2020
1<?php 
2function comicpress_copyright() {
3global $wpdb;
4$copyright_dates = $wpdb->get_results("
5SELECT
6YEAR(min(post_date_gmt)) AS firstdate,
7YEAR(max(post_date_gmt)) AS lastdate
8FROM
9$wpdb->posts
10WHERE
11post_status = 'publish'
12");
13$output = '';
14if($copyright_dates) {
15$copyright = "© " . $copyright_dates[0]->firstdate;
16if($copyright_dates[0]->firstdate != $copyright_dates[0]->lastdate) {
17$copyright .= '-' . $copyright_dates[0]->lastdate;
18}
19$output = $copyright;
20}
21return $output;
22} 
23?>
similar questions
queries leading to this page
copyright dynamique avec wordpress