Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Postgresql timestamps in article.php are wrongly managed #232

Open
cg6e713n opened this issue May 4, 2023 · 0 comments
Open

Postgresql timestamps in article.php are wrongly managed #232

cg6e713n opened this issue May 4, 2023 · 0 comments

Comments

@cg6e713n
Copy link

cg6e713n commented May 4, 2023

I had to modify Article.php code like this to See correct dates on articles

                    if ( $article->mDate && $parameters->getParameter( 'userdateformat' ) ) {
                            // Apply the userdateformat
                            // cg6e713n 2023/05/04 INC3062517
                            //$article->myDate = gmdate( $parameters->getParameter( 'userdateformat' ), (int)wfTimestamp( TS_UNIX, $article->mDate ) );
                            $article->myDate = gmdate( $parameters->getParameter( 'userdateformat' ), (int)wfTimestamp( TS_UNIX, $row->revactor_timestamp ) );

Dpl code used :


category = Actu
nottitlematch=Accueil|Actualité
ordermethod = firstedit
order = descending
adduser = true
mode = userformat
addpagecounter = true
addeditdate = true
userdateformat = d/m/Y
count = 5
include = %0
cacheperiod = 10
format = ,

  • ,
  • [[https://si-scientifique.edf.fr/index.php?curid=%PAGEID%&action=edit Modifier]] %USER% le %DATE%

,




category = Actu
nottitlematch=Accueil|Actualité
ordermethod = firstedit
order = descending
adduser = true
mode = userformat
addpagecounter = true
addeditdate = true
userdateformat = d/m/Y
include = %0
cacheperiod = 10
format = ,
  • ,
  • [[https://si-scientifique.edf.fr/index.php?curid=%PAGEID%&action=edit Modifier]] %USER% le %DATE%

,

I'm sure theres a better workaround for this but i ran out of time

DPL3 3.4.6
Mediawiki 1.35.7 ( old LTS )
Postgresql base

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant