You are using a framework, you do not have to do something manually if the framework already do everything!!! If you do what are you trying to do, you’ll get off from the framework coding standard. My question is: why?
@sensorario, I don’t like Yii including jQuery on my behalf either, especially because I use CDN and want to include it at the bottom of the page, not in the head section.
I’ve extended CClientScript this way:
class ClientScript extends CClientScript {
public function renderCoreScripts() {
return;
}
}
Can i ask one more question. I’m sending my form via AJAX (using ajaxSubmitButton) . But when user click the submit button i want to show a message like “Record added to database” . Which way should i follow for this?
public function actionCreate()
{
// code to save model attributes from POST var
if($model->save())
echo "Record Added to database";
else
echo new CHhtpException(500);
}
i have just given example code. Please adjust according to your requirements