Is it possible to replace this using a CHtml::ajaxLink



    <a href="#" 


      onclick="


      jQuery.ajax({'url':'<?php echo $this->createUrl('next',array('reference'=>''))


               ?>'+jQuery('.mainBody .galleryImage .image img').attr('src'),


               'cache':false,


               'success':function(html){


                    jQuery('.mainBody').html(html)}


                });


                return false;"


       


      class="galleryNext">Next</a>


The key issue being that the response is based on a value being returned by jQuery('.mainBody .galleryImage .image img').attr('src'). This value is not static so it must be read when the link is clicked.

I have tried a few different variations but it always appears that the "calculated" url gets encoded.

Thoughts welcome

nz

What is "calculated" url?

For the url parameter I tried to pass in

array("next", "reference"=>"jQuery('.mainBody .galleryImage .image img').attr('src')")

Prefix it with 'js:' to avoid being encoded.

Excellent,

thanks !

nz