How can I pass data through my URL ?
I need to pass, an email, client_id, etc.
Client.aspx?Email='teste@gmail.com'
Nowadays I have an Javascript Function, but I think would be better via Code-Behind
$('.btIncluirAtendimento').live('click', function () {
idCliente = $(this).attr('id').replace('cad_', '');
popup = openPopup('../Cliente/AtendimentoNew.aspx?Cliente_Id=' + idCliente, 'IncluirAtendimento', 'toolbar=no,directories=no,status=no,menubar=no, scrollbars=yes,resizable=no', '720', '600', 'true');
});
function openPopup(theURL, winName, features, myWidth, myHeight, isCenter) {
if (window.screen) if (isCenter) if (isCenter == "true") {
var myLeft = (screen.width - myWidth) / 2;
var myTop = (screen.height - myHeight) / 2;
features += (features != '') ? ',' : '';
features += ',left=' + myLeft + ',top=' + myTop;
}
popup = window.open(theURL, winName, features + ((features != '') ? ',' : '') + 'width=' + myWidth + ',height=' + myHeight);
return popup;
}
Can anyone help me ?
You need to encode the url string and than you can pass data easily.
Example :