Code for Thought
I code flying cool stuff.
Home
Yii Framework
Netbeans vs Eclipse as a PHP IDE a brief review
How to install Sun Java on Ubuntu Server
Yii Framework in Ubuntu/Linux Quick start guide
Posted on December 18, 2010 by sumwai
About
Hi, I am Sum-Wai, an Information Technologist based in Malaysia. This is where I share earth shattering programming tips, you should subscribe to my blog now. Yes, dooo it.
First download Yii from the Yiis download page on the website. Recommended to choose a stable version to start with. Uncompress the package somewhere comfy, lets just say your username is rajamal(I am using non English names for demo for a change!) and youve extracted it to the following example path
/home/rajamal/source/yii-1.1.5.r2654
Contact Me Recent Comments
s
rename the folder to just yii to make our life easier
s
mv yii-1.1.5.r2654 yii
s
sweet, our folder name is yii now, then we create a symlink in ~/bin directly so we can use yiic anywhere. Create a bin folder inside your home directory if it is not already created, and make sure the bin directory is added to $PATH.
Fery on Yii radio button list example, or how to remove the line break separator IT Cui Bap on Yii unit testing passing new ar object between dependent test case gotcha asdf on Using Virtualbox 3.2.2 in full screen on second monitor resurtm on Customize Yii CGridView and CListView pagers label fery on Changing/setting the viewPath in Yii
Tags
auth
closure controller cpanel
mkdir /home/rajamal/bin
database debug d j a n g o Drupal
eclipse form functional test git
g m a i l h a m l jEdit j Q u e r y json
model m u t t MySQL Netbeans n l t k pencil r b a c render review
Make sure the bin directory is added to $PATH
r s y n c Selenium sendmail setup shell ubuntu unit test v i r t u a l b o x
yii
gedit ~/.profile
s s
Categories
CMS Database s Editor s Google s IDE s Java s JavaScript s Linux s NLP s PHP s Prototype Generated by www.PDFonFly.com at 8/15/2011 4:40:27 AM s Python
Add this to .profile
if [ -d "$HOME/bin" ] ; then PATH="$HOME/bin:$PATH" fi
URL: http://tipstank.com/2010/12/18/yii-framework-in-ubuntulinux-quick-start-guide/
s s s s
Scala Version Control Virtualization WordPress
then inside of bin, create a symlink to yiic like this. (yiic help us do routine stuff like creating a new webapp or creating a new migration)
Good to know
ln -s /home/rajamal/source/yii/framework/yiic yiic
open up a new terminal window, now you can just use
yiic webapp yourappname
to create a new web application! (UPDATE: added step to include ~/bin into $PATH variable)
This entry was posted in PHP and tagged yii. Bookmark the permalink.
Post related to this (Generated)
s s s
Yii how to register jQuery UIs JavaScript and CSS Yii findByAttributes example Yii CDbCriterias condition and param notation
How to install Sun Java on Ubuntu Server
Netbeans vs Eclipse as a PHP IDE a brief review
6 Responses to Yii Framework in Ubuntu/Linux Quick start guide
seal trip says:
March 12, 2011 at 12:40 am
Nice tutorial!
Reply
seal trip says:
March 12, 2011 at 12:47 am
Just moved over to linux / ubuntu (from windows)And I followed your tutorial. yiic webapp myAppname Did not work for me The response I got was; Command not found Did you have to set any path variables?
Reply
Artis says:
June 14, 2011 at 11:45 pm
Try running the command:
Generated by www.PDFonFly.com at 8/15/2011 4:40:27 AM URL: http://tipstank.com/2010/12/18/yii-framework-in-ubuntulinux-quick-start-guide/
source ~/.profile It should come into effect after running it. If it does not work after a reboot or losing a bash session, add the command to ~/.bashrc file. Hope this helps!
Reply
prettyscripts says:
March 17, 2011 at 8:55 am
ive been typing the full path to do that thanks for the tip. this is makes my life easier.
Reply
Pingback: Artis Avotins blog PHP Yii framework tip on Ubuntu (and other) Linuxes
henry says:
June 26, 2011 at 11:59 am
thank you
Reply
Leave a Reply
Your email address will not be published. Required fields are marked *
Name
Email
Website
Comment 5
You may use these HTML tags and attributes: <a href="" title=""> <abbr title="">
<acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">
Post Comment
Fresh from my oven.
s s s
How to change input field size in Drupal 7 Drupal 7 Submitted by customization Yii how to register jQuery UIs JavaScript and CSS
Generated by www.PDFonFly.com at 8/15/2011 4:40:27 AM URL: http://tipstank.com/2010/12/18/yii-framework-in-ubuntulinux-quick-start-guide/
s s
Yii findByAttributes example Yii CDbCriterias condition and param notation
To success in life, we have to take one step further.
Code for Thought
Proudly powered by WordPress.
Generated by www.PDFonFly.com at 8/15/2011 4:40:27 AM URL: http://tipstank.com/2010/12/18/yii-framework-in-ubuntulinux-quick-start-guide/