title: Script function not found: doGet (AGAIN !!! )
body: <p>So I've read just about every article and thread I could about getting this to work and it seems to be a common issue with a varying range of causes. I couldn't find the solution so I'm hoping you guys can help.</p>
  <p>I published the script and got the typical (Script function not found: doGet).</p>
  <p>Here's the script and html script code. I've uploaded the new published link to the html file. I was sure to make a &quot;New&quot; version instead of updating the old version. I'm assuming there's some syntax somewhere that I haven't called out properly. I just don't know what or where. Hoping you can help.</p>
  <p>Here's the script code:</p>
  <pre><code>    var sheetName = 'Sheet1'
      var scriptProp = PropertiesService.getScriptProperties()
  
      function intialSetup () {
        var activeSpreadsheet = SpreadsheetApp.getActiveSpreadsheet()
        scriptProp.setProperty('key', activeSpreadsheet.getId())
      }
  
      function doPost (e) {
        var lock = LockService.getScriptLock()
        lock.tryLock(10000)
  
        try {
          var doc = SpreadsheetApp.openById(scriptProp.getProperty('key'))
          var sheet = doc.getSheetByName(sheetName)
  
          var headers = sheet.getRange(1, 1, 1, sheet.getLastColumn()).getValues()[0]
          var nextRow = sheet.getLastRow() + 1
  
          var newRow = headers.map(function(header) {
            return header === 'timestamp' ? new Date() : e.parameter[header]
          })
  
          sheet.getRange(nextRow, 1, 1, newRow.length).setValues([newRow])
  
          return ContentService
            .createTextOutput(JSON.stringify({ 'result': 'success', 'row': nextRow }))
            .setMimeType(ContentService.MimeType.JSON)
        }
  
        catch (e) {
          return ContentService
            .createTextOutput(JSON.stringify({ 'result': 'error', 'error': e }))
            .setMimeType(ContentService.MimeType.JSON)
        }
  
        finally {
          lock.releaseLock()
        }
      }
          
  </code></pre>
  <p>Here's the script inside the HTML code</p>
  <pre><code>    &lt;script&gt;
          const scriptURL = 'https://script.google.com/macros/s/AKfycbwzy6qtuvcOpOrl9ELoy6lM9k5CFhZWGbb-XriD1SyofDeZ6tU/exec'
          const form = document.forms['google-sheet']
        
          form.addEventListener('submit', e =&gt; {
            e.preventDefault()
            fetch(scriptURL, { method: 'POST', body: new FormData(form)})
              .then(response =&gt; alert(&quot;Thanks for Contacting us..! We Will Contact You Soon...&quot;))
              .catch(error =&gt; console.error('Error!', error.message))
          })
        &lt;/script&gt;
  
      &lt;script src=&quot;https://maxcdn.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js&quot;&gt;&lt;/script&gt;
      &lt;script src=&quot;https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js&quot;&gt;&lt;/script&gt;
  </code></pre>