现在我们的图片地址是//fec-img.gan-hai.com/media/catalog/category/X/lP/XlP032_BACKPACK_2016-08-11_955x200_2857.jpg 但是app识别不了,要加http或者https。请问有配置key来配置吗?还是只有改代码
安装fecshop,有配置图片的步骤
就是文件:@common/config/fecshop_local_services/Image.php
当然,这个设置是全局的,各个入口统一的设置,如果你想你的某个入口进行单独的设置,那么你在
@app/config/fecshop_local_services/Image.php 中配置,这里的配置就会覆盖@common的
如果@app没有这个文件,创建,从common复制过去内容覆盖,然后修改就行了
<?php /** * FecShop file. * * @link http://www.fecshop.com/ * * @copyright Copyright (c) 2016 FecShop Software LLC * @license http://www.fecshop.com/license/ */ return [ 'image' => [ 'appbase' => [ 'appfront' => [ 'basedir' => '@appimage/appfront', 'basedomain' => '//img.appfront.fancyecommerce.com', ], 'apphtml5' => [ 'basedir' => '@appimage/apphtml5', 'basedomain' => '//img.apphtml5.fancyecommerce.com', ], //'appadmin' => [ // 'basedir' => '@appimage/appadmin', // 'basedomain' => '//img.appadmin.fancyecommerce.com', //], 'common' => [ 'basedir' => '@appimage/common', 'basedomain' => '//img.fancyecommerce.com', ], ], ], ];
将 //img.appfront.fancyecommerce.com 改成 https://img.appfront.fancyecommerce.com
//img.appfront.fancyecommerce.com
https://img.appfront.fancyecommerce.com
目前的这种方式可以很好的兼顾浏览器下的http和https,但是app是没网址的,只能加http了
http
感谢