On May 6, 5:33 pm, TomRossi7
<t...-5bxIUPmzHicFraO2wh7vUA@public.gmane.org>
wrote:> When my controller renders js along with a status other than 200, the
> js is not executed.
>
> So
>
> render :status => 400, :js =>
%{"alert(''Error!'')"}
>
> Will not do anything, but
>
> render :status => 200, :js =>
%{"alert(''Error!'')"}
>
Is the content type getting set appropriately ?
Fred> Will work just fine.
>
> I can understand the reasoning since an error has occurred, but
> shouldn''t it be an option somewhere to have it eval the
> request.responseText? For now I am doing it in the :failure callback,
> I was just wondering if I was missing a more elegant solution.
>
> Thanks,
> Tom