SitePoint Sponsor

User Tag List

Results 1 to 4 of 4

Threaded View

  1. #1
    SitePoint Member
    Join Date
    Sep 2010
    0 Post(s)
    0 Thread(s)

    move inline script into external js file

    Hi there,

    the logic as outlined in the attached file is working however I would like to move the inline script (line 8 to 354) into an external js file. only how ?

    if I move the above to dtree.js, adjust function dTree(objName) for function dTree(objName, path) and adjust $path for path under icons and use
    $jsfile = $baselink.$this->template.'/js/dtree.js';
    <script type="text/javascript" src="$jsfile"></script>
    how am I to pass $path to the script?

    I am sorry if this is majorly basic but I'm only starting with learning js

    could somebody please help me figure how to achieve that?
    Attached Files Attached Files


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts