skip to Main Content

js not connecting to html

<head> <title></title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" type="text/css" href="../css/style-index.css"> <script type="text/javascript" src="../js/script.js"></script> </head> in javascript is: alert('test') external js is not connecting to html structure: https://cdn.discordapp.com/attachments/1027105980900708442/1232712295893827635/image.png?ex=662a744a&is=662922ca&hm=5e90d125df3525f31584806fbdc41e91941442f596890bd8c0266e4ab76ca4b4& edit: I also tried to rename project folder to remove all…

VIEW QUESTION

Using this script on an input tag but it removes the entered text slightly after a letter is entered – Html

function formatPhoneNumber(value) { if (!value) return value; const phoneNumber = value.replace(/[^d]/g, ''); const phoneNumberLength = phoneNumber.length; if (phoneNumberLength < 4) return phoneNumber; if (phoneNumberLength < 7) { return `(${phoneNumber.slice(0, 3)}) ${phoneNumber.slice(3)}`; } return `(${phoneNumber.slice(0, 3)}) ${phoneNumber.slice( 3, 6 )}-${phoneNumber.slice(6, 9)}`;…

VIEW QUESTION
Back To Top
Search