diff --git a/Application/Common/Common/function.php b/Application/Common/Common/function.php index 1c86b10b5..4d3b136fa 100644 --- a/Application/Common/Common/function.php +++ b/Application/Common/Common/function.php @@ -1011,25 +1011,25 @@ function get_cover($cover_id, $field = null, $root = 1, $flag = true) if (!empty($picture['oss_url'])) { return $picture['oss_url']; } else { - return 'http://' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; + return '//' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; } } elseif (get_tool_status("qiniu_storage") == 1) { if (!empty($picture['url'])) { return $picture['url']; } else { - return 'http://' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; + return '//' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; } } elseif (get_tool_status("cos_storage") == 1) { if (!empty($picture['url'])) { return $picture['url']; } else { - return 'http://' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; + return '//' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; } } elseif (get_tool_status("bos_storage") == 1) { if (!empty($picture['bos_url'])) { return $picture['bos_url']; } else { - return 'http://' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; + return '//' . $_SERVER['HTTP_HOST'] . __ROOT__ . $picture['path']; } } else { if ($field == 'path') {