laravel關於上一篇下一篇

上一篇下一篇的實質就是獲取本條記錄的上下兩個id,經過sql語句實現以下:php 上一篇:select id,title where id < id order by id desc limit(1);html 下一篇:select`id`,`title` where `id` > id order by `id` asc limit 1laravel 而在laravel Eloquent 中實現
相關文章
相關標籤/搜索