阅读背景:

从最后一个数组值中删除逗号

来源:互联网 

PHP

PHP

$meta = get_post_custom($post->ID); 
$images = $meta['img1'][0];    // urls separated with comma
$images = explode(',', $images);
foreach ($images as $image) {
    echo '{image : '.$image.', title : "Credit: x"},'; 
};
$meta = get_post_custom($post->ID);



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: