Jump to content

Recommended Posts

Posted

Can't believe I don't know this but is there any way of accessing a date/time of when a field was added/modified as opposed to the page itself?

Or would I need to create an additional field to map times to another field's events?

Thanks.

Posted

Maybe I am not getting your point, but I just tested this:

$p=$pages->get("/about/");
$p->headline = "test";
$p->of(false);
$p->save("headline");

and the page's modified date gets changed, just like it would if you saved the entire page. Are you getting different results, or am I off base on what you are trying to do?

Posted

Adrian, I think Andre wants the date when the field (not the page) was added or modified. So, when was 'headline' added, for instance :-). The page could change subsequent times before and after, but he wants the time for this one particular field. I don't think this is possible out of the box?

  • Like 1
Posted

That makes sense - I thought I must have been missing something :)

Yeah, most fields don't have created/modified db fields. Files/Images fields do - if you look at the DB structure they have both created/modified fields, although interestingly those fields don't exist on a new install - they get added the first time the field is used.

So yeah, I think the easiest option would be to create another field to store that.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...