在.htaccess的帮助下,我将新模板创建为根目录
RewriteEngine on
RewriteCond %{REQUEST_URI} !new/
RewriteRule (.*) /new/$1 [L]
但我有一个问题,所有的产品图片都在默认的public_html上。我如何访问它,如果我想上传产品图片,我会收到这个错误
Not Found
The requested URL /new/pimgs/ was not found on this server.
Additionally, a 404 Not Found error was encountered while tryin
这是我的产品模型:
class Product extends Model
{
protected $primaryKey = 'product_id';
public $guarded = ['created_at', 'updated_at'];
public function product_pics ()
{
return $this->hasMany('App\ProductPics');