From cf48cb0021989b5fa206923aae766ec973696f1b Mon Sep 17 00:00:00 2001 From: Coleman Watts Date: Tue, 2 Jun 2015 16:58:57 -0400 Subject: [PATCH] CRM-16310 - Fix inline link handling with dynamic content --- js/crm.ajax.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/js/crm.ajax.js b/js/crm.ajax.js index 8d266e38bd..8edebab812 100644 --- a/js/crm.ajax.js +++ b/js/crm.ajax.js @@ -462,13 +462,16 @@ }, settings.ajaxForm)); if (settings.openInline) { settings.autoClose = $el.crmSnippet('isOriginalUrl'); - $(settings.openInline, this).not(exclude + ', .crm-popup').click(function(event) { + $(this).on('click', settings.openInline, function(e) { + if ($(this).is(exclude + ', .crm-popup')) { + return; + } if ($(this).hasClass('open-inline-noreturn')) { // Force reset of original url $el.data('civiCrmSnippet')._originalUrl = $(this).attr('href'); } $el.crmSnippet('option', 'url', $(this).attr('href')).crmSnippet('refresh'); - return false; + e.preventDefault(); }); } // Show form buttons as part of the dialog -- 2.25.1