Yii Framework Forum: Install yii 1.1.0 in vista with xampp webserver package - Yii Framework Forum

Jump to content

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

Install yii 1.1.0 in vista with xampp webserver package Rate Topic: *---- 1 Votes

#1 User is offline   andritjia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 7
  • Joined: 17-February 10
  • Location:Jakarta, Indonesia

Posted 17 February 2010 - 10:01 PM

Guys, I need a help. I just downloaded yii-1.1.0.r1700 into my pc with windows vista n i have xampp webserver package. I tried to install from the instruction http://blog.dmcinsig...-yii-framework/ and it doesnt work. it returned the error "'php' is not recognized as an internal or external command, operable program or batch file." I placed the framework in "C:\xampp\" so become "C:\xampp\yiiframework". is it must in "C:\xampp\htdocs\" so become "C:\xampp\htdocs\yiiframework"?

Regrads,
Andri
0

#2 User is offline   Maurizio Domba 

  • Yii - Yesss It Is !!!
  • Yii
  • Group: Yii Dev Team
  • Posts: 4,230
  • Joined: 12-October 09
  • Location:Croatia

Posted 18 February 2010 - 02:40 AM

View Postandritjia, on 17 February 2010 - 10:01 PM, said:

error "'php' is not recognized as an internal or external command, operable program or batch file."


This is not YII related... it's a problem with running PHP from command prompt...I think you don't have it in the PATH?
Find more about me.... btw. Do you know your WAN IP?
0

#3 User is offline   dimis283 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 276
  • Joined: 24-January 09

Posted 18 February 2010 - 02:56 AM

I write the full path of php.exe at bat files and it works for me.
Posted Image
0

#4 User is offline   andritjia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 7
  • Joined: 17-February 10
  • Location:Jakarta, Indonesia

Posted 18 February 2010 - 03:49 AM

well, the here the step why do i get the error. after unzip yii-1.1.0.r1700.zip, I see folder framework and I move this folder to C:\xampp and rename it to yiiframework so it becomes C:\xampp\yiiframework.

then i go to cmd prompt then runing "cd C:\xampp\yiiframework" then
if I run "yiic webapp c:xampp\php;c:xampp\yiiframework" I got error "'yiic' is not recognized as an internal or external command, operable program or batch file."
if I run "php yiic webapp c:xampp\php;c:xampp\yiiframework" I got error "'php' is not recognized as an internal or external command, operable program or batch file."
0

#5 User is offline   Maurizio Domba 

  • Yii - Yesss It Is !!!
  • Yii
  • Group: Yii Dev Team
  • Posts: 4,230
  • Joined: 12-October 09
  • Location:Croatia

Posted 18 February 2010 - 04:00 AM

View Postandritjia, on 18 February 2010 - 03:49 AM, said:

if I run "php yiic webapp c:xampp\php;c:xampp\yiiframework" I got error "'php' is not recognized as an internal or external command, operable program or batch file."


You should run as "php yiic ..."... but php need to be in the %path% !

Or you can type the path to PHP... eg. c:\xampp\php\php.exe

* note that I don't know where PHP.EXE is located in XAMPP, this is just to show you what you have to look for..

So you have to find where is located PHP.EXE and then that location add to PATH or use in the command line...
Find more about me.... btw. Do you know your WAN IP?
0

#6 User is offline   dimis283 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 276
  • Joined: 24-January 09

Posted 18 February 2010 - 04:03 AM

At yiic.bat you may set the full path of php.exe .
if "%PHP_COMMAND%" == "" set PHP_COMMAND=C:\xampp\php\php.exe

C:\xampp\htdocs/framework/yiic webapp  C:\xampp\htdocs/templates


cd C:\xampp\htdocs\eshop
C:\xampp\php\php.exe protected/yiic shell

Posted Image
0

#7 User is offline   andritjia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 7
  • Joined: 17-February 10
  • Location:Jakarta, Indonesia

Posted 18 February 2010 - 04:39 AM

View Postmdomba, on 18 February 2010 - 04:00 AM, said:

You should run as "php yiic ..."... but php need to be in the %path% !

Or you can type the path to PHP... eg. c:\xampp\php\php.exe

* note that I don't know where PHP.EXE is located in XAMPP, this is just to show you what you have to look for..

So you have to find where is located PHP.EXE and then that location add to PATH or use in the command line...




I changed the yiic.bat to be alike this :


@setlocal

set YII_PATH=C:\xampp\yiiframework

if "%PHP_COMMAND%" == "" set PHP_COMMAND=C:\xampp\php\php.exe

%PHP_COMMAND% "%YII_PATH%yiic" %*

@endlocal


then from cmd prompt, I run
php yiic webapp c:\xampp\php\;c:\xampp\yiiframework\
I still got error
'php' is not recognized as an internal or external command, operable program or batch file
0

#8 User is offline   andritjia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 7
  • Joined: 17-February 10
  • Location:Jakarta, Indonesia

Posted 18 February 2010 - 04:47 AM

View Postdimis283, on 18 February 2010 - 04:03 AM, said:

At yiic.bat you may set the full path of php.exe .
if "%PHP_COMMAND%" == "" set PHP_COMMAND=C:\xampp\php\php.exe

C:\xampp\htdocs/framework/yiic webapp  C:\xampp\htdocs/templates


cd C:\xampp\htdocs\eshop
C:\xampp\php\php.exe protected/yiic shell



if I see this line "C:\xampp\htdocs/framework/yiic webapp C:\xampp\htdocs/templates", it means i need to create one application folder named "templates" then compile "C:\xampp\htdocs/framework/yiic webapp C:\xampp\htdocs/templates" this one from cmd prompt?
0

#9 User is offline   dimis283 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 276
  • Joined: 24-January 09

Posted 18 February 2010 - 04:56 AM

View Postandritjia, on 18 February 2010 - 04:47 AM, said:

if I see this line "C:\xampp\htdocs/framework/yiic webapp C:\xampp\htdocs/templates", it means i need to create one application folder named "templates" then compile "C:\xampp\htdocs/framework/yiic webapp C:\xampp\htdocs/templates" this one from cmd prompt?


The C:\xampp\htdocs/templates is just the folder that yii will create the webapp, it may be your application folder.
Posted Image
0

#10 User is offline   Maurizio Domba 

  • Yii - Yesss It Is !!!
  • Yii
  • Group: Yii Dev Team
  • Posts: 4,230
  • Joined: 12-October 09
  • Location:Croatia

Posted 18 February 2010 - 04:57 AM

View Postandritjia, on 18 February 2010 - 04:39 AM, said:

'php' is not recognized as an internal or external command, operable program or batch file


Untill you solve the PHP not recognized... forget Yii...

Have you checked where PHP.EXE is located?

if you have the path to PHP.EXE you can add it to the PATH variable... and than in the command prompt when you enter PHP -? it will display help instead of what you are getting now.
Find more about me.... btw. Do you know your WAN IP?
0

#11 User is offline   andritjia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 7
  • Joined: 17-February 10
  • Location:Jakarta, Indonesia

Posted 18 February 2010 - 05:19 AM

View Postdimis283, on 18 February 2010 - 04:56 AM, said:

The C:\xampp\htdocs/templates is just the folder that yii will create the webapp, it may be your application folder.


I just copied folder helloworld from the yii-1.1.0.r1700.zip in folder demo. then from cdm prompt
I run "cd c:\xampp\yiiframework" then I run "c:\xampp\yiiframework webapp c:\xampp\htdocs\helloworld"
I got error "'c:\xampp\yiiframework' is not recognized as an internal or external command, operable program or batch file"
0

#12 User is offline   andritjia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 7
  • Joined: 17-February 10
  • Location:Jakarta, Indonesia

Posted 18 February 2010 - 05:23 AM

View Postmdomba, on 18 February 2010 - 04:57 AM, said:

Untill you solve the PHP not recognized... forget Yii...

Have you checked where PHP.EXE is located?

if you have the path to PHP.EXE you can add it to the PATH variable... and than in the command prompt when you enter PHP -? it will display help instead of what you are getting now.



ok, here the php.exe location "C:\xampp\php\php.exe"
0

#13 User is offline   bettor 

  • Master Member
  • PipPipPipPip
  • Yii
  • Group: Members
  • Posts: 707
  • Joined: 02-February 09

Posted 18 February 2010 - 06:12 AM

View Postandritjia, on 17 February 2010 - 10:01 PM, said:

Guys, I need a help. I just downloaded yii-1.1.0.r1700 into my pc with windows vista n i have xampp webserver package. I tried to install from the instruction http://blog.dmcinsig...-yii-framework/ and it doesnt work. it returned the error "'php' is not recognized as an internal or external command, operable program or batch file." I placed the framework in "C:\xampp\" so become "C:\xampp\yiiframework". is it must in "C:\xampp\htdocs\" so become "C:\xampp\htdocs\yiiframework"?

Regrads,
Andri



I suggest you enter your php paths here:
start -> My computer(right click!) -> Advanced Tab -> Environment Variables -> Click Path in System variables -> Edit

Have you looked at this cookbook?

hope this help

bettor
0

#14 User is offline   logos010 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 61
  • Joined: 12-November 10
  • Location:VietNam

Posted 13 September 2011 - 02:52 AM

View Postandritjia, on 18 February 2010 - 05:23 AM, said:

ok, here the php.exe location "C:\xampp\php\php.exe"

Hi,
I had faced this problem too, but I have solved it

Look it simple! if you have an error when try to use "yiic webapp website", and this always return a messages like "php.exe is not ecognized as an internal or external command,...." --> that mean the php.exe file is not really redicted in right path.

Ok, just do it, it works for me:
Step 1:Open command line
Step 2:Go to the C:/ folder (with me, I setup xampp server in C:/) by command: "cd.. C:/"
Step 3:type the following command:
C:/xampp/php/php.exe C:/xampp/htdocs/yii/framework/yiic webapp yourWebsite

And if you command is not error, you with see the Yii ask you confim to create project, and then, every thing I think you can solve by yourself :lol:
good luck
0

#15 User is offline   sonam 

  • Junior Member
  • Pip
  • Yii
  • Group: Members
  • Posts: 79
  • Joined: 10-September 11

Posted 01 October 2011 - 02:04 AM

i have uploaded yii main folder(after download) on the server but unable to run the requirement test as the browser is not able to find the path and redirect it to yahoo serach ......please help
0

#16 User is offline   Maurizio Domba 

  • Yii - Yesss It Is !!!
  • Yii
  • Group: Yii Dev Team
  • Posts: 4,230
  • Joined: 12-October 09
  • Location:Croatia

Posted 01 October 2011 - 05:55 AM

Do you have a webserver installed ?

If you have a webserver did you put the yii framework in the webserver directory?
Find more about me.... btw. Do you know your WAN IP?
0

#17 User is offline   blackcanabiz 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 2
  • Joined: 13-March 12

Posted 13 March 2012 - 01:41 AM

View Postmdomba, on 01 October 2011 - 05:55 AM, said:

Do you have a webserver installed ?

If you have a webserver did you put the yii framework in the webserver directory?


just copy your web application folder that generated by yii to your web root.ie.c:\xampp\htdocs\[web application folder]
0

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