Laravel 安装
打赏作者

Kirits

感觉还不错

JellyBool

@Kirits 谢谢,后续有来

moonline 回复 JellyBool

你好 在使用composer下载的时候一直提示这个错误 求教
’’’
[Composer\Downloader\TransportException]
Your configuration does not allow connections to http://packagist.org/packa
ges.json. See https://getcomposer.org/doc/06-config.md#secure-http for deta
ils.

create-project [-s|–stability STABILITY] [–prefer-source] [–prefer-dist] [–repository REPOSITORY] [–repository-url REPOSITORY-URL] [–dev] [–no-dev] [–no-custom-installers] [–no-scripts] [–no-progress] [–no-secure-http] [–keep-vcs] [–no-install] [–ignore-platform-reqs] [–] [] [] []
’’’

JellyBool 回复 moonline

找个好的梯子,科学上网

moonline 回复 JellyBool

OK梯子到期就换

vue-女神 回复 JellyBool

怎么我不能观看视频

JellyBool 回复 vue-女神

你直接看应该是可以的

lyon

得改一下链接。。。 点图点了半天。。才记得得点标题。
不符合直觉

JellyBool

@lyon 好的,我修改一下吧

carpho
MacBook-Pro:~ ** mv composer.phar /usr/local/bin/composer
mv: rename composer.phar to /usr/local/bin/composer: No such file or directory

我用sudo也不行 不知道为啥啊

JellyBool

是否下载了 composer.phar,再检查你的/usr/local/bin目录是否存在,看看 PATH 环境变量有没有设置/usr/local/bin/优先

carpho

我下载了composer.phar 在os 10.10.5上就没有问题 我安装了10.11 os x ei capitan 我用前往文件夹看/usr/local 里面只有一个sbin 没有bin目录 我该怎么创建啊 还有如何设置bin目录优先

JellyBool

手动创建一个bin目录试一下,然后在 ~/.zshrc里面(如果你用zshell)添加:

export PATH="/usr/local/bin/usr/bin/bin/usr/sbin/sbin"

不用zshell的话就在~/.bashrc加吧

JellyBool

@carpho 看看上面这个

carpho

我用sudo mkdir创建了这个目录 现在弄好了 谢谢大神哦

JellyBool

@carpho OK,常来看看

carpho

@JellyBool 大神 可否提供一下laravist.com 的源码程序 我想做个像这样的轻cms 可以发布自己喜欢的东西 我自己一个人写的话 写不出来呢

JellyBool

@carpho 目前并没有开源的打算

lixun7

博主好! 请问你的 Mac终端 里的代码配色很漂亮,是有特别的配置吗?

JellyBool

用的是iTerm 2;哈哈,

http://www.iterm2.com/

@lixun7

t2036999602

楼主问一下,我在mac下桌面安装composer,也把移在bin目录下了,可以全局使用,为什么安装laravel框架,就报错了

Desktop tongxibing composer create-project laravel/laravel laravel5
Failed to decode response: zlib_decode(): data error
Retrying with degraded mode, check https://getcomposer.org/doc/articles/troubleshooting.md#degraded-mode 
for more info
JellyBool

首先,以后有代码的地方请使用markdown格式,这样对双方都有好处。
第二,这种问题请使用VPN @t2036999602

t2036999602

楼主,能分别举个markdown格式,和vpn使用,谢谢。

JellyBool

markdown格式看这里,https://laravist.com/discussion/21

要尝试的话,直接在这里练手: https://laravist.com/discussion/create

@t2036999602

t2036999602

谢谢楼主这么热情的解答,后续继续关注。

JellyBool

你发起的讨论是练手的吧?我隐藏了 @t2036999602

t2036999602

主要学习laravel框架思想,刚好公司有个项目要用到啊,刚好看到博主视频很适合教程,所以就来学习下。

t2036999602

突然发现学个耗大量时间,也只能是学到皮毛啊

JellyBool

看个人吧 @t2036999602 时间都是相对的

t2036999602

所以自己要付出,才能学得更扎实啊,顺便问一下,我在mac下开发 就开一个 php artisan serve 服务启动就可以了吗,不需要配置吗 ,这个内置的服务是包含了php是吗,后期要用到nginx 或者mysql都得自己配置吗。

JellyBool

对,是可以说是包括了php,应该说php版本达到要求的话,不需要配置。如果使用nginx,需要自己配置。这个php artisan serve跟mysql没有关系 @t2036999602

zghack

@JellyBool 这个网站是你写的吗?

JellyBool

是的 @zghack

pemako

支持楼主 赞

nigelvon

项目名字起错了,强迫症有点扛不住
Larvavel5->Laravel5

Python

有问题请教:

[Illuminate\Database\QueryException]                                                             
  SQLSTATE[42000]: Syntax error or access violation: 1067 Invalid default value for 'created_at'   
  (SQL: create table `site_statuses` (`id` int unsigned not null auto_increment primary key, `day  
  ` varchar(255) not null, `register_count` int not null default '0', `topic_count` int not null   
  default '0', `reply_count` int not null default '0', `image_count` int not null default '0', `c  
  reated_at` timestamp default 0 not null, `updated_at` timestamp default 0 not null) default cha  
  racter set utf8 collate utf8_unicode_ci)     

部署phphub 填充数据就这样是哪里错了呢

JellyBool

这个问题你可以直接到phphub提issue,我没有安装过phphub,也没使用过laravel 4的版本 @Python

Python

@JellyBool issue 没人理我 跟着你的教程 timstamps 都是正常的 4.2的这个不知道啥问题

18369905258

谢谢分享!已受教。

JellyBool

哈哈哈,常来看看呗 @18369905258

samerway

非常棒,刚开始接触laravel,有这些教学视频参考,一下子清楚多了。

霸气战苍穹

mac 命令行显示这个当前文件夹所用的路径是啥插件啊

JellyBool

这不用插件啊 @霸气战苍穹

噼里啪啦小蛋哥

这真的是极好的

crazw

Jelly 你的终端怎么配置的会半透明提示命令的 装的什么插件吗

yangbaojan

@JellyBool 视频很好,虽然这节的懂,但听听挺好的,

JellyBool

谢谢,常来看看呗 @yangbaojan

丸丸娃娃菜

@JellyBool 创建的时候出现以下提示,弹出提示安装git,安装后还是这种提示,请问这是为什么?

Could not fetch https://api.github.com/repos/symfony/css-selector/zipball/4613311fd46e146f506403ce2f8a0c71d402d2a3, please create a GitHub OAuth token to go over the API rate limit
Head to https://github.com/settings/tokens/new?scopes=repo&description=Composer+on+wanwandeMacBook-Pro.local+2016-01-09+1408
to retrieve a token. It will be stored in "/Users/wanwan/.composer/auth.json" for future use by Composer.
Token (hidden):

JellyBool

你去github 设置一下token呗,提示这里就有链接地址了 @丸丸娃娃菜

遍地黄玫瑰

感觉好难懂的框架,先看看symfony2是不是更容易上手一点如果差不多,再决定选择哪一个框架细心沉淀吧

JellyBool

看你自己的选择呗 @遍地黄玫瑰

-杨晓锋-

请问你用的什么编辑器,这么强大

JellyBool 回复 -杨晓锋-

PhpStorm ,我眼中 最好的 PHP IDE

DevinZhong

如果内存不是太小,用 Homestead 也不错。

harverychina

非常感谢分享,学到不少东西!

zy812415556

vpn的账号密码怎么获取的?有没有vpn搭建的文章@JellyBool

JellyBool 回复 zy812415556

额。。这个自己去找一个付费的就可以

Plzzzzg

composer 新建laravel项目真的很慢, 最后是配置了packagist 镜像就可以了。 感觉很棒。

sangda

我这里为什么看不到视频,显示“视频加载出了一点问题”?

深圳邦道营销管理咨询公司

最后 laravel5 命令为什么写成 larvavel5 也能运行,这一点不是很明白,明显多了个v字母

xuanchangbo

Route::get(’/’, function () {
return ‘aaaaaaaaaaaaaa’;//view(‘welcome’);
});
我刚装好之后,输出aaaaaaa没有问题,但是后面的模板却找不到。这是怎么回事啊?

JellyBool 回复 xuanchangbo

你有这个 welcome 视图文件么?

xuanchangbo 回复 JellyBool

嗯嗯,有的。找到问题了。是没有开启缓存权限的原因。多谢了,老师!

sfabric2016

我想问一下,window7系统 laravel new laravel时提示:
[GuzzleHttp\Exception\ConnectException]
cURL error 7: Failed to connect to 127.0.0.1 port 1080: Connection refused
(see http://curl.haxx.se/libcurl/c/libcurl-errors.html)
怎么解决啊,怎么是连接127.0.0.1呢,环境变量我也加进去了

JellyBool 回复 sfabric2016

是否设置过代理或者你改了你的 hosts,修改了 laravel.com 的ip?

sfabric2016 回复 JellyBool

之前设置过一个ssh91,
hosts里面就设置过这个:
127.0.0.1 localhost
127.0.0.1 sfabric.dev
127.0.0.1 laravel.dev
127.0.0.1 smart.dev
127.0.0.1 zhihu.dev
其他就没有了,这样会有什么影响吗

JellyBool 回复 sfabric2016

Failed to connect to 127.0.0.1 port 1080: Connection refused

这个总感觉是代理的问题

Nixus

@JellyBool 老师好!看到你用的终端是 zsh,于是就查了一下,安装了 oh-my-zsh。
但是装好后发现,没有 tab 标签,请问这个 tab 标签是要另外配置的吗

JellyBool 回复 Nixus

你的人iterm 2 的偏好设置

Nixus 回复 JellyBool

嗯,已经找到了!不过 iterm2的字体渲染,有点儿粗糙

ma5694

看了最新的视频,在看这期,生涩的感觉_

JellyBool 回复 ma5694

刚开始录视频的时候,,,,,

ma5694 回复 JellyBool

后期会不会有node.js的教程

dajiyuanzi

妈的瞧不起用win的,我就是没钱买mac咋地

sdfcurry30

很棒!就是 有点卡

JellyBool 回复 sdfcurry30

怎么卡?具体描述一下,我排除一下

sdfcurry30 回复 JellyBool

问题不大,可能我网卡

tkin1992

执行composer create-project laravel/laravel Laravel5
出了这个问题Your requirements could not be resolved to an installable set of packages.
Problem 1
- laravel/framework v5.4.9 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- laravel/framework v5.4.8 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- laravel/framework v5.4.7 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
To enable extensions, verify that they are enabled in your .ini files:
- /etc/php/7.0/cli/php.ini
- /etc/php/7.0/cli/conf.d/10-opcache.ini
You can also run php --ini inside terminal to see which files are used by PHP in CLI mode.

JellyBool 回复 tkin1992

安装 php7.0-mbstring 扩展

tkin1992 回复 JellyBool

安装了还是不行,php-mbstring 已经是最新版 (1:7.0+35ubuntu6)。
但问题变了一些: Problem 1
- phpunit/phpunit 5.7.9 requires ext-dom * -> the requested PHP extension dom is missing from your system.

tkin1992 回复 JellyBool

我查资料又安装了 php-xml好了,哈哈

tkin1992

不会上图片啊

tkin1992 回复 JellyBool

好的,知道了谢谢

kvcr945a 回复 tkin1992

不错,不错。感谢分享

雾霾公司

嘿 @jellybool 从 5.2到5.5的新特性都要看一遍吗 还是只需要看最新版就可以了

JellyBool 回复 雾霾公司

我觉得看了是最好的

longge

老哥!这个怎么解决!求助Exception
DateTime::__construct(): Failed to parse time string (2018-03-12 01:10:58.-159808) at position 24 (8): Unexpected character

JellyBool 回复 longge

感觉是有什么非法字符

acai2046

提示:需要登录
D:\laravel>composer create-project laravel/laravel test
Installing laravel/laravel (v5.5.28)

  • Installing laravel/laravel (v5.5.28): Loading from cache
    Created project in test

@php -r "file_exists(’.env’) || copy(’.env.example’, ‘.env’);"
Loading composer repositories with package information
Updating dependencies (including require-dev)

Authentication required (packagist.phpcomposer.com):
  Username:
acai2046

There is an arrear problem with this JSS account that prevents the operation from completing successfully