에러 메세지는 using $this when not in object context in ... 등등 하고 나온다.
신기하게도 회사에서의 우분투환경에서는 에러가 발생하지 않는데 집에서 새로 구성한 우분투에서는 위하고 똑같은 에러가
발생한다. 코드는 단 한줄도 한자도 수정하지 않았는데.
해서 구글링을.. 오랜 시간 하다보니... 버젼 문제였다.
PHP 5.4.10 is not available in the Ubuntu repositories for 12.04.
You have two options:
(1) try and find a PPA with a backported version of PHP 5.4.10 (such as ondrej's oldstable PPA)
a) Run this command:
sudo apt-get install python-software-properties
b) Run this command:sudo add-apt-repository ppa:ondrej/php5-oldstable
c) Runsudo apt-get update; sudo apt-get install php5
d) This should allow you to use PHP 5.4.10 (or whatever the most recent "Old Stable PHP" is).
(2) download PHP from source, and compile it.
Otherwise, you'll have to wait for Saucy to be released, so that you can get PHP 5.5.3. 5.4.10 does not exist in the repositories for any version of Ubuntu, apparently.
(I can try and backport 5.4.10 from Debian if you would like, but it would be in a PPA, so you'd have to trust that I'm not giving you malware, although I wouldn't do that ever.)
등등이라고 스택오버플로우에서 나옴.
그러고 보니 집에서 구성해놓은 우분투에는 PHP 5.3 인데 회사에서는 5.4 였다.
위처럼 해서 터미널에서 실행하니 잘 됨. ㅠㅠ;; 이런 삽질 싫다..ㅡㅡ;
'Development > PHP' 카테고리의 다른 글
서브라임텍스트로 PHP 개발환경 구축 (0) | 2014.12.10 |
---|---|
AJAX 요청시 XHR 요청 확인하는 PHP 환경변수 (0) | 2014.09.16 |
PHP 자료형 비교 (0) | 2014.01.29 |
나만의 PHP MVC 프레임워크 (0) | 2014.01.22 |
PHP include & include_once & require & require_once (0) | 2014.01.22 |
댓글