PHP   发布时间:2022-04-04  发布网站:大佬教程  code.js-code.com
大佬教程收集整理的这篇文章主要介绍了php-Laravel:如何包含一个库?大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。

我要使用以下内容
文件夹中的Holmes:

http://paste.laravel.com/Em

    // Determine if request is from a mobile device
Holmes::is_mobile(); // returns Boolean

// Determine the type of device
$device = Holmes::get_device(); // returns String

// Determine if a specific device is being used
// Any supported device below is acceptable
// lowercased no spaces, obvIoUsly. <3
Holmes::is_ipad();
Holmes::is_blackBerrytablet();

我在哪里放置什么?

在路线上:

视图:

@if(Holmes::is_iphone())
{{ 'this is an iphone' }}
@endif

我也得到这个错误
Holmes库文件中的第25行应仅通过引用传递变量

我正在尝试从程序混乱中过渡;)

解决方法:

Chris Fidao(Fideloper)撰写了一篇很棒的文章,其中包含有关如何在Laravel 4中加载库的说明:
http://fideloper.com/laravel-4-application-setup-app-library-autoloading

大佬总结

以上是大佬教程为你收集整理的php-Laravel:如何包含一个库?全部内容,希望文章能够帮你解决php-Laravel:如何包含一个库?所遇到的程序开发问题。

如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。

本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。
标签: