Skip to main content

Thread: externally loading javascript ?


when use <script src......> load external javascript, not loading?
pgm1.js
code:
<script language="javascript">  var mes="message goes here......"  </script>
this pgm3.html
code:
<html>  <title> display</title>  <head>  <script src="/home/abhilash/pgm1.js"> </script>  </head>    <body>  <script language="javascript">  document.write("<p>"+mes+"</p>");  </script>  </body>    </html>
what problem?

pgm1.js
php code:
var message "message from javascript"
pgm3.html
php code:
<script type="text/javascript">
    
document.write("<p>" message "</p>");
</script> 
p.s. - <title> in wrong place


Forum The Ubuntu Forum Community Ubuntu Specialised Support Development & Programming Programming Talk externally loading javascript ?


Ubuntu

Comments

Popular posts from this blog

VIDIOC_S_FMT error 16, Device or resource busy - Raspberry Pi Forums

using a laptop skeleton to build a pi laptop - Raspberry Pi Forums

Forum for Joomla? - Joomla! Forum - community, help and support