#24057 closed defect (bug) (worksforme)
wp_list_bookmarks links target=""
Reported by: | moscar09 | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | minor | Version: | 3.5.1 |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
When adding links via the add links function in WordPress, the default target of the link is _none.
The problem is, the code generated for that code is
<a href="..." target="">, target being an empty string. This is not HTML5 compliant, as target has to have at least 1 character.
Change History (4)
Note: See
TracTickets for help on using
tickets.
Could not reproduce neither in 3.5.1 nor in 3.6-beta1.
This is what I see in HTML with the default Links widget:
In the Target meta box,
_none
option corresponds to an empty value:http://core.trac.wordpress.org/browser/tags/3.5.1/wp-admin/includes/meta-boxes.php#L779
In
_walk_bookmarks()
,target
attribute is only added if it's not empty:http://core.trac.wordpress.org/browser/tags/3.5.1/wp-includes/bookmark-template.php#L94
Your theme or some plugin is probably hooking into
wp_list_bookmarks
filter to change the output.