How to implement Laravel 4 Partial Views - Binding data to partial views

前端 未结 3 1217
心在旅途
心在旅途 2021-01-06 07:11

I am debating whether I should use Laravel to build an online store.

Requirement - Show a shopping cart in sidebar with product listing in main area. i need to bind

3条回答
  •  日久生厌
    2021-01-06 07:48

    for me create a abstract class ShopController extends BaseController

    and in constructor() write View::composer

    and you can use DB::table('products')->remember(100)->get(); vs all() for the cache

提交回复
热议问题