Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Advanced Search


  • Content Count

  • Joined

  • Last visited

  1. Thank you, works great. Do you know of a way to force it back to the thumbnail? Also, when the video starts, there is occasionally a small ad that appears on the left bottom. It can be x-ed out, but is there a way to stop it from appearing in the first place?
  2. I don’t know if this will help you, because I don’t do the commerce thing. After I changed the Last Name First Name in the Contact Form, I then realized that I ran into the same problem in a survey form, I needed to translate the Agree/Disagree choices. Not being a coder, @groundcontact’s answer from August 24 was too complex, so I played with the August 19 answer and changed the LastName/First Name as I had done in my Contact Form, pasting the code to handle the response translations. By looking for the ClassName in the page source, I then changed it to the class name I had found for the survey, and also changed the numbers in each “paragraph”.Notice that each class name starts in numbering from 0 and then continues on, when you move onto the next class name, you start re-numbering from 0, for example (classes and numbers are bolded): sqsFirstName = document.getElementsByClassName("caption")[0].innerHTML;[ … ]document.getElementsByClassName("caption")[0].innerHTML = myFirstName; sqsLastName = document.getElementsByClassName("caption")[1].innerHTML;[ … ]document.getElementsByClassName("caption")[1].innerHTML = myLastName; [ We are now targeting a different class, "option", so the numbering begins from "0" ]sqsRadio = document.getElementsByClassName("option")[0].innerHTML;[ … ]document.getElementsByClassName("option")[0].innerHTML = myRadio; The result worked like a charm, hope it works for you. Go to the page where your form is located. Open the Settings > Advanced tab. Paste the following code in the Page Header Code Injection area: <script> function addLoadEvent(func) { var oldonload = window.onload; if (typeof window.onload != 'function') { window.onload = func; } else { window.onload = function() { if (oldonload) { oldonload(); } func(); } } } addLoadEvent(function() { sqsFirstName = document.getElementsByClassName("caption")[0].innerHTML; myFirstName = sqsFirstName.replace("First Name", "Prénom"); document.getElementsByClassName("caption")[0].innerHTML = myFirstName; sqsLastName = document.getElementsByClassName("caption")[1].innerHTML; myLastName = sqsLastName.replace("Last Name", "Nom"); document.getElementsByClassName("caption")[1].innerHTML = myLastName; sqsRadio = document.getElementsByClassName("option")[0].innerHTML; myRadio = sqsRadio.replace("Strongly Disagree", "Fortement Désaccord"); document.getElementsByClassName("option")[0].innerHTML = myRadio; sqsRadio = document.getElementsByClassName("option")[1].innerHTML; myRadio = sqsRadio.replace("Disagree", "Désaccord"); document.getElementsByClassName("option")[1].innerHTML = myRadio; sqsRadio = document.getElementsByClassName("option")[2].innerHTML; myRadio = sqsRadio.replace("Neutral", "Neutre"); document.getElementsByClassName("option")[2].innerHTML = myRadio; sqsRadio = document.getElementsByClassName("option")[3].innerHTML; myRadio = sqsRadio.replace("Agree", "d'Accord"); document.getElementsByClassName("option")[3].innerHTML = myRadio; sqsRadio = document.getElementsByClassName("option")[4].innerHTML; myRadio = sqsRadio.replace("Strongly Agree", "Fortement d'Accord"); document.getElementsByClassName("option")[4].innerHTML = myRadio; }); </script>
  3. Thank you. Been busy so had no time to reply. Not being a programmer, I don’t know why this is better, since the Last Name First Name were corrected with your first solution, HOWEVER. this appears to be attacking the second area where I need to change the un-changeable, and that’s on a BLOG page where the publish date appears. I tried using your first solution, and instead of using “caption” I used “published” and invented sqsdate and mydate instead of names. I used 0,1,2. It works on the first date only. Problem is in French I need to change May 1 2014 to “le 1 mai 2014” Does new code fix? This is how the entry for the 2nd date looks like after I tried modifying your first code from the Last/FirstName: sqsDate1 = document.getElementsByClassName("published")[1].innerHTML; myDate1 = sqsDate1.replace("August 7, 2014", "le 7 aout, 2014"); document.getElementsByClassName("published")[1].innerHTML = myDate1; IT WORKED, but only on first entry (the [0]) I thought that I could just keep adding a [1] [2] [3] etc. each time I published. Does your new code address this? (By now it must be obvious that I am not a programmer!) Thanks
  4. WOW! -- THANK YOU SO MUCH !!!!! It worked like a charm. I substituted the Spanish for Prénom and Nom in French. At first I had copy pasted into WORD to transfer to a second profile on my computer, and that did not work, so I copy pasted into NOTEPAD, saved it, switched profiles, and copy pasted from NOTEPAD into the Code injection area. I seem to remember other pages that have "un-editable" areas, and will try to modify this script to adapt those. Thanks again !!!! - Cragg
  • Create New...