Recherches récentes


Pas de recherche récente

Strange Subject ID in the Help Center V4



Publication le 23 août 2024

Hi everyone,

 

I'm certain there is an easy solution, but I'm simply trying to auto fill the subject on the help center for a specific form selected.

Inspecting the field shows an id of:  #3--input.StyledTextInput-sc-k12n8x-0.egmjoO

 

An older version of the HC the subject id shows #request_subject.

 

This is probably why the form's subject is blank when I have this at the bottom of the script.js file. The date part is to confirm the code continues on the proper form.

 

  var now = new Date();
 
 var ticketForm = location.search.split('ticket_form_id=')[1];
 if(ticketForm == 28485134800795) {
   console.log('Datetime.'+now);
   $('label[for=request_subject]').html("Custom Label");
        $('#3--input').val('Custom subject'); // Autofill subject
    }
 

All feedback is greatly appreciated.

 


0

0

0 commentaire

Vous devez vous connecter pour laisser un commentaire.

Vous ne trouvez pas ce que vous cherchez ?

Nouvelle publication