Forums / Developer / Cronjob hide.php timestamp problem

"Please Note:
  • At the specific request of Ibexa we are changing this projects name to "Exponential" or "Exponential (CMS)" effective as of August, 11th 2025.
  • This project is not associated with the original eZ Publish software or its original developer, eZ Systems or Ibexa".

Cronjob hide.php timestamp problem

Author Message

laurent le cadet

Thursday 02 August 2007 4:22:49 am

Hi,

I want to use the hide.php script to hide contents.
Everything seems to be ok but contents are not hide.

Athe end of the script we've got this :

...
$date = $dateAttribute->content();
            $retractDate = $date->attribute( 'timestamp' );
			mail("laurent@lestudiot.com","dateAttributeName","{$retractDate} - {$currrentDate}");
            if ( $retractDate > 0 && $retractDate < $currrentDate )
			
            {
                eZContentObjectTreeNode::hideSubTree( $node );
                if ( !$isQuiet )
                {
                    $cli->output( 'Hiding node : ' . $node->attribute( 'node_id' ) );
                }
            }
...

And it appears in my tracking email that $retractDate is always greater than the $currrentDate variable.

It doesn't make sense to me because I have contents with an older date than the current date + I have more than 150 contents but recieved less than 50 mails.

Any idea?

Regards.

Laurent