[wp-hackers] store all revisions of user metadata in wordpress - possible?
Jamie Currie
jamie at wunderdojo.com
Fri Aug 9 22:22:59 UTC 2013
Best bet is probably just adding a custom table. No matter how you
tackle it you're not going to be able to store / retrieve chronological
usermeta using the built in WP functions -- it's just not set up for
that.
I built a member management platform on WP that is used by various
businesses (health clubs, things like that) to manage member
registration, payments, front desk check in, etc. I opted to go with a
few custom tables for just this reason -- made it way easier to track
info. and you can optimize with db indexes, etc.
Jamie Currie
Founder / CEO
wunderdojo
wunderdojo.com <http://www.wunderdojo.com> | twitter.com/wunderdojo
<http://twitter.com/#!/wunderdojo>
tel: 949-734-0758
23 Corporate Plaza Drive, Suite 100
Newport Beach, CA 92660
Master web & app developers
------ Original Message ------
From: "Gregory Lancaster" <greglancaster71 at gmail.com>
To: "wp-hackers at lists.automattic.com" <wp-hackers at lists.automattic.com>
Sent: 8/9/2013 3:19:23 PM
Subject: Re: [wp-hackers] store all revisions of user metadata in
wordpress - possible?
>or- if there is a more effecient method of storing userdata? An
>external
>database seems like it might be easier to manage than this, but I dont
>know
>if its possible to hook the logged in users username to their
>information
>and have it displayed back for them.
>
>On Friday, August 9, 2013, Jamie Currie wrote:
>
>> I've wondered before why the meta tables don't timestamp -- would
>>make a
>> world of things easier if they did and seems like it has a ton of
>>practical
>> application.
>>
>> Jamie Currie
>> Founder / CEO
>> wunderdojo
>> wunderdojo.com <http://www.wunderdojo.com> | twitter.com/wunderdojo <
>> http://twitter.com/#!/**wunderdojo
>><http://twitter.com/#!/wunderdojo>>
>> tel: 949-734-0758
>> 23 Corporate Plaza Drive, Suite 100
>> Newport Beach, CA 92660
>> Master web & app developers
>>
>>
>>
>>
>> ------ Original Message ------
>> From: "Nicholas Ciske" <nl at thoughtrefinery.com>
>> To: wp-hackers at lists.automattic.com
>> Sent: 8/9/2013 3:05:13 PM
>> Subject: Re: [wp-hackers] store all revisions of user metadata in
>> wordpress - possible?
>>
>>> Yes, my approach would only really work if you already knew the user
>>>id
>>> (or were looping through users) and just wanted to display history.
>>>Finding
>>> a user whose email used to be X would be difficult and hacky.
>>>
>>> I was going for simple ;-)
>>>
>>> A separate table would be far more flexible, but a lot more overhead
>>>code
>>> wise.
>>>
>>> _________________________
>>> Nick Ciske
>>> http://thoughtrefinery.com/
>>> @nciske
>>>
>>> On Aug 9, 2013, at 5:00 PM, Jamie Currie wrote:
>>>
>>> Interesting approach, wouldn't have thought to do it that way.
>>>Wouldn't
>>>> it make it challenging to do any kind of searching / filtering on
>>>>the
>>>> metadata though?
>>>>
>>>> Jamie Currie
>>>> Founder / CEO
>>>> wunderdojo
>>>> wunderdojo.com <http://www.wunderdojo.com> |
>>>>twitter.com/wunderdojo <
>>>> http://twitter.com/#!/**wunderdojo
>>>><http://twitter.com/#!/wunderdojo>>
>>>> tel: 949-734-0758
>>>> 23 Corporate Plaza Drive, Suite 100
>>>> Newport Beach, CA 92660
>>>> Master web & app developers
>>>>
>>>>
>>>>
>>>>
>>>> ------ Original Message ------
>>>> From: "Nicholas Ciske" <nl at thoughtrefinery.com>
>>>> To: wp-hackers at lists.automattic.com
>>>> Sent: 8/9/2013 2:40:15 PM
>>>> Subject: Re: [wp-hackers] store all revisions of user metadata in
>>>> wordpress - possible?
>>>>
>>>>> Try storing all meta data for that user in a serialized array --
>>>>>add
>>>>> entries indexed by meta key & timestamp whenever something
>>>>>changes, then
>>>>> query the history array to display change history for all or one
>>>>>item.
>>>>>
>>>>> Make sure you avoid recursion and don't track the history of the
>>>>> history meta data (or store it in an option with the user_id in
>>>>>the key
>>>>> name).
>>>>>
>>>>> _________________________
>>>>> Nick Ciske
>>>>> http://thoughtrefinery.com/
>>>>> @nciske
>>>>>
>>>>
>>> ______________________________**_________________
>>> wp-hackers mailing list
>>> wp-hackers at lists.automattic.com
>>>
>>>http://lists.automattic.com/**mailman/listinfo/wp-hackers<http://lists.automattic.com/mailman/listinfo/wp-hackers>
>>>
>>
>> ______________________________**_________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>>
>>http://lists.automattic.com/**mailman/listinfo/wp-hackers<http://lists.automattic.com/mailman/listinfo/wp-hackers>
>>
>_______________________________________________
>wp-hackers mailing list
>wp-hackers at lists.automattic.com
>http://lists.automattic.com/mailman/listinfo/wp-hackers
More information about the wp-hackers
mailing list