I want to start out with, that im a noob to AJAX, jquery and that kinda stuff. But im currently working on a project, where i have a calender, where a substitute can specify if he is available a given day and the time period etc. Now im just struggling with the problem that then they click on a day, to specify that they are available, that i need a pop up window to show, where they can specify the time they are available. I have found several guides on Yii's forum on how to do it, the problem is though that the pop up window never opens.
Here is the code with the link specified, but when i check it on the homepage it says ../offer/calendar# <-- each link on a day links to the calendar not the pop up window
$url = CHtml::ajaxLink(Yii::t('job', 'Ledig'), Yii::app()->createUrl('offer/createOffer'), array(
'onclick' => '$("#offerDialog").dialog("open"); return false;',
'update' => '#offerDialog'
), array('id' => 'showOfferDialog'));
/** You can query the database for an entry for this day if you like or print out a message on each day. Uncomment these two lines. * */
$this->calendar.= '<div class="' . $this->style . '-normal">'. $url . '</div><br/>';
$this->calendar.= str_repeat('<p> </p>', 2);