Replace the last usage of ctype_digit with is_numeric. Fixes #6534 for trunk props mtekk.
git-svn-id: https://develop.svn.wordpress.org/trunk@7588 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
15490b8df5
commit
414be415cd
@ -179,7 +179,7 @@ function get_attachment_link($id = false) {
|
||||
$parentlink = _get_page_link( $object->post_parent ); // Ignores page_on_front
|
||||
else
|
||||
$parentlink = get_permalink( $object->post_parent );
|
||||
if ( ctype_digit($object->post_name) || false !== strpos(get_option('permalink_structure'), '%category%') )
|
||||
if ( is_numeric($object->post_name) || false !== strpos(get_option('permalink_structure'), '%category%') )
|
||||
$name = 'attachment/' . $object->post_name; // <permalink>/<int>/ is paged so we use the explicit attachment marker
|
||||
else
|
||||
$name = $object->post_name;
|
||||
|
Loading…
Reference in New Issue
Block a user