What does it mean to use ":" before a variable ?
For example, :userId
in this code:
public function removeUser($userId)
{
$command = Yii::app()->db->createCommand();
$command->delete(
'tbl_project_user_assignment',
'user_id=:userId AND project_id=:projectId',
array(':userId'=>$userId,':projectId'=>$this->id));
}
This is PHP,MySQL code in Yii framework.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…