$(".voteView").click(function () { var voteTitle = $(this).attr("rel"); chart = $('.chart').html(); $.fancybox.open(chart); jQuery.jqplot('chart2', [datachart], { // title: voteTitle, seriesDefaults: { shadow: false, renderer: jQuery.jqplot.PieRenderer, rendererOptions: {padding: 2, sliceMargin: 2, showDataLabels: true} }, legend: { show: true, location: 'e', renderer: $.jqplot.EnhancedPieLegendRenderer }, grid: { drawBorder: false, drawGridlines: false, background: '#ffffff', shadow: false } } ); }); $(".regisenew").click(function () { $("input[name='Enews[email]']").val($("input[name='valueEnewEmail']").val()); });