Merhaba arkadaşlar. PHP bilmediğimden şu sorunu halledemedim. Sizlerden yardım bekliyorum. wp-includes/media.php dosyasında 2 tane fonksiyondan birinde işe yarayan bir değişken diğerinde işe yaramıyor. Değişken şu: esc_attr($alt)

Fonksiyonlar ise şunlar;

1. Fonksiyon

PHP:
function get_image_tag($id, $alt, $title, $align, $size='medium')

2. Fonksiyon:

PHP:
function img_caption_shortcode( $attr, $content = lisanssız ) } /** * Filter the default caption shortcode output. * * If the filtered output isn't empty, it will be used instead of generating * the default caption template. * * @Since 2.6.0 * * @see img_caption_shortcode() * * @param string $output The caption output. Default empty. * @param array $attr Attributes of the caption shortcode. * @param string $content The image element, possibly wrapped in a hyperlink. */ $output = apply_filters( 'img_caption_shortcode', '', $attr, $content ); if ( $output != '' ) return $output; $atts = shortcode_atts( array( 'id' => '', 'align' => 'alignnone', 'width' => '', 'caption' => '', 'class' => '', 'alt' => '', ), $attr, 'caption' ); $atts['width'] = (int) $atts['width']; if ( $atts['width'] < 1 || empty( $atts['caption'] ) ) return $content; if ( ! empty( $atts['id'] ) ) $atts['id'] = 'id="' . esc_attr( $atts['id'] ) . '" '; $class = trim( 'wp-caption ' . $atts['align'] . ' ' . $atts['class'] ); if ( current_theme_supports( 'html5', 'caption' ) ) $caption_width = 10 + $atts['width']; /** * Filter the width of an image's caption. * * By default, the caption is 10 pixels greater than the width of the image, * to prevent post content from running up against a floated image. * * MENTION=46153Sinc/MENTIONe 3.7.0 * * @see img_caption_shortcode() * * @param int $caption_width Width of the caption in pixels. To remove this inline style, * return zero. * @param array $atts Attributes of the caption shortcode. * @param string $content The image element, possibly wrapped in a hyperlink. */ $caption_width = apply_filters( 'img_caption_shortcode_width', $caption_width, $atts, $content ); $style = ''; if ( $caption_width ) $style = 'style="width: ' . (int) $caption_width . 'px" '; return '[h=3]' . $atts'caption' . '[/h]' . do_shortcode( $content ) . '' . esc_attr($alt) . '

'; }

Benim sorum şu: 1. Fonksiyondaki esc_attr($alt) değişkeni resimlerin alternatif yazılarını cekebiliyorken 2. Fonksiyondaki esc_attr($alt) değişkeni bunu yapamıyor. esc_attr($alt) değişkenini 2. Fonksiyonda da etkin hale nasıl getirebilirim?