dso89762 2014-10-05 19:20
浏览 14
已采纳

需要链接Laravel中的页面

Im a newbie in laravel. I went though the route documentation on the Laravel site. Thing I want to create a new tab in my menu, I have added the tab but cannot seem to link it. When i Read on the laravels site, it said you need to edit routes.php file, and so I did, but it didnt seem to work. Im sure im missing something out. Could you please help me? The website is on jfgfestival.com I want to add the tab after Press.

Im running Laravel 4.1

This is what I have added to routes.php

Route::get('videos', function()
{
    $featured_images = Featured::get();
    $categories = Category::get();
    return View::make('home.videos')->with(compact('featured_videos', 'categories'));
});

Also this new page that Im creating is for a video gallery. Does any one know how to create a video gallery in laravel? I cannot seem to find any good references/ tutorials for the same.

Thank you again

  • 写回答

1条回答 默认 最新

  • donglei7152 2014-10-05 20:03
    关注

    Make sure that you have the view file you specified set up. For this route it should be in:

    app/views/home/videos.blade.php
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥100 支付宝网页转账系统不识别账号
  • ¥15 基于单片机的靶位控制系统
  • ¥15 AT89C51控制8位八段数码管显示时钟。
  • ¥15 真我手机蓝牙传输进度消息被关闭了,怎么打开?(关键词-消息通知)
  • ¥15 下图接收小电路,谁知道原理
  • ¥15 装 pytorch 的时候出了好多问题,遇到这种情况怎么处理?
  • ¥20 IOS游览器某宝手机网页版自动立即购买JavaScript脚本
  • ¥15 手机接入宽带网线,如何释放宽带全部速度
  • ¥30 关于#r语言#的问题:如何对R语言中mfgarch包中构建的garch-midas模型进行样本内长期波动率预测和样本外长期波动率预测
  • ¥15 ETLCloud 处理json多层级问题