Changing ajax parameters

I am modifying an existing Yii program using Eclipse on Apache 2.2. I have modified the code to change the parameters of an existing ajax call. I was using one integer field from my database table but now I need to use a different field.

Here’s the code:

    $url = array('dailyProgressByTrack', 'studentId'=> $student->id);


    $url['curriculumTrackId'] = $curriculumTrack->id;


    $url['CollectionProgressPreferencesForm[startDate]'] = $prefsForm->startDate;


    $url['CollectionProgressPreferencesForm[stopDate]'] = $prefsForm->stopDate;


	$tabcontent[$tabTitle] = array('ajax' => $url);

In the second line, I changed ‘lessonTypeId’ to ‘curriculumTrackId’. That’s the only change I made.

I’m getting the following error: “NetworkError: 400 CHttpException - .../studentProgress/dailyProgressByTrack?studentId=630&curriculumTrackId=2&CollectionProgressPreferencesForm%5BstartDate%5D=09%2F01%2F11&CollectionProgressPreferencesForm%5BstopDate%5D=07%2F01%2F12”

I’m new to Yii and PHP so I need help identifying the problem. Thanks.

So, code worked okay before this change and works okay if you revert change to other parameter?

Which arguments your studentProgress/dailyProgressByTrack method accepts?

Your comment got me to look at the action function. I’d missed converting the variable there. Thanks for the help.