I’m currently doing some testing on wordpress.
In a recent test I found out that when changing the site url in the settings menu from domain a, to domain b.
In the actual mysql table, the guid attribute in the posts table doesnt change.
example:
site created on url: http://10.0.0.31/wptest1, original GUID example:
http://10.0.0.31/wptest1/?p=1
changed to: http://wptest1.com/wptest1, GUID is unchanged: http://10.0.0.31/wptest1/?p=1
We are afraid that this could cause trouble in the future and my boss and I are agreeing that this would be a major bug.
My question is: What is the GUID used for and why is it unchanged after changing the main url.
So far we havn’t found any issues on the user side, but if plugins were to use the guid then we’re going to run into problems…
I hope you guys can help.
Grtz, Thomas
This is not a bug. It is by design. GUIDs are only used as an internal globally unique identifier for a post. Users should never see them. See Important GUID note for more info.