[wp-hackers] Post URL

Omry Yadan omry at yadan.net
Fri Sep 14 22:22:15 GMT 2007

I am extending FireStats to support post title of urls.

for this I am maintaining the post title as a metadata of the url inside
a table in FireStats.

I hooked to publish_post and to edit_post, and I update my metadata there.

so far so good.

during the installation/upgrade, I want to go through all the posts and
do the same.

I see two options:

1. iterate on all the posts, and call my function that update the title
for each one. this can be pretty slow and is not desirable.

2. create some big update sql statement, that will use the post guid as
a url link.

the big question is, can I trust the post guid? what happens if the user
changes the permalink structure? will the post guid be changed with it?

what do you guys think would be a better solution here?


More information about the wp-hackers mailing list