Yii Framework Forum: Freshly Installed Yii2 2.0.12 - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Freshly Installed Yii2 2.0.12 Rate Topic: -----

#1 User is offline   carn4ge 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 63
  • Joined: 04-January 17

Posted 06 March 2018 - 09:09 AM

I've installed Yii2 advanced at my localhost and after installing it and connecting to database I've already encountering an error:

Quote

Fatal error: Uncaught Error: Using $this when not in object context in C:\XAMPP\htdocs\ndrrmc\advanced\frontend\views\site\index.php:5 Stack trace: #0 {main} thrown in C:\XAMPP\htdocs\ndrrmc\advanced\frontend\views\site\index.php on line 5


But I didn't do anything yet, at the line 5

$this->title = 'My Yii Application';


This is the first time I've installed an advanced app, been using the basic app for learning and I decided to move on and use the advanced app. Did I miss something else in the installation?
0

#2 User is offline   carn4ge 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 63
  • Joined: 04-January 17

Posted 07 March 2018 - 12:59 AM

Nevermind, I got it now. I've read the documentation and I forgot to do the php init on the terminal.
1

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users