#36928 closed defect (bug) (wontfix)
GUID prepended with http://
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 4.5.2 |
| Component: | Feeds | Keywords: | |
| Focuses: | Cc: |
Description
I noticed that when I update/save a post with a non-url guid, that wordpress prepends http:// to the front of the guid. However, I have not found a mechanism for changing this behavior. When found ticket #31080 I hoped that would fix the issue. I am also confused since reading the docs it says nothing about the guid needing to be a url.
I tried the the suggested snippet of code with slight variations to no avail.
remove_filter( 'the_guid', 'esc_url' );
function escape_the_guid($guid){
//tried other things before returning.
return $guid;
}
add_filter( 'the_guid', 'escape_the_guid' );
Lastly, why is there not a unique constraint on the guid column?
Change History (3)
Note: See
TracTickets for help on using
tickets.
You might be looking at unhooking
esc_url_rawon thepre_post_guidfilter as well. There's alsopost_guidfor display in certain contexts. You can find several default filters with guids included inwp-includes/default-filters.php.