Trusted Sehr gut 4.89 / 5.00
function runAfterElementExists(jquery_selector, callback) {var checker = window.setInterval(function() {if ($(jquery_selector).length) {clearInterval(checker);callback();}}, 200);} function prepareQuestionModal() { $('#Varianten-ID').val('17-15055'); $('#Artikel-ID').val('15055'); $('#Artikel-Name').val($('h1.title').text().trim()); $('#Artikel-ID,#Varianten-ID,#Artikel-Name').prop('readonly',true); }; prepareQuestionModal();