Hi
I suspect I'm just being dense here, and I apologise if so.
I'm simply trying to return the timestamp for a Date CCK field in a hook_nodeapi() function.
My field is called field_need_date_value.
I've tried:
$date = strtotime($node->content['field_need_date_value'];
and
$date = strtotime($node->field_need_date_value);
and
$date = strtotime($node->field_need_date_value[0]['view'];
but I can't get any of these to work.....
Thanks
Comments
Comment #1
glennnz commentedSolved
It's:
Comment #2
arlinsandbulte commentedComment #4
RobW commentedYou can also create a custom date format with U as the format parameter string, and then set your field to your custom format in the manage display tab. This returns a unix timestamp.