title: how to include js file using script tag in jquery codes?
body: <p>I want to include js file in jQuery scripts, when data is fetched from database using <code>$.ajax</code> and do something without refreshing the page</p>
  
  <p>for example:</p>
  
  <pre><code>$.ajax({
    type: 'POST',
    url: "content.php",
    data: {vals: "value"},
    success : function(response) { 
      $(body).append(response)
      showScrollStyle();
    }
  }); 
  
  function showScrollStyle() {
   // here should include 3 js file for change scroll style
  }
  </code></pre>
  
  <p>response will show a div with <code>500px height</code> and width that have <code>overflow:auto;</code> style and if text of div will be more than of <code>500px;</code> vertical scroll will be show automatially, I have 3 js file that I should include there for change scroll styles and type.</p>
  
  <p>I tried <code>$.getScrpit()</code> function but it will refresh the page and will show just a white page.</p>
  
  <p>how can I do this? thank you </p>
  
  <p>EDIT 1:</p>
  
  <p>I created some codes that i think can explain what i want</p>
  
  <p>HTML CODE</p>
  
  <pre><code>&lt;!doctype html&gt;
  &lt;html&gt;
  &lt;head&gt;
  &lt;meta charset="utf-8"&gt;
  &lt;title&gt;Untitled Document&lt;/title&gt;
  &lt;script type="text/javascript" src="https://code.jquery.com/jquery-1.10.2.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="jquery.mCustomScrollbar.concat.min.js"&gt;&lt;/script&gt;
  &lt;script&gt;
  $(document).ready(function(e) {
      textScroll()
     function textScroll() {
  
          $.ajax({
            type: 'POST',
            url: "content.php",
            data: {val: "text_div"},
            success : function(response) { 
              $("body").append(response);
              showScrollStyle()
            }
          }); 
      }
  
      });
  
      function showScrollStyle() {
          // jquery.mCustomScrollbar.concat.min.js should import in here for work with new elemnts
      }
  &lt;/script&gt;
  &lt;link rel="stylesheet" href="style/scroll_style.css"&gt;
  
  &lt;style&gt;
  body {
  
      background-color:#369;
  }
  &lt;/style&gt;
  
  &lt;/head&gt;
  
  &lt;body&gt;
  
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>PHP CODE </p>
  
  <pre><code>&lt;?php 
  
      include 'Connections.php';  // connect to database
  
      $val =  $_POST['val'];
      $query = "SELECT contains FROM textarea WHERE name='".$val."' LIMIT 1";
              //  echo $query;
      if ($result = $mysqli-&gt;query($query)) {
          while ($row = $result-&gt;fetch_assoc()) {
              echo $row['contains'];  
          }
      }   
      else
      {
          echo $mysqli-&gt;error;
      }
  
  ?&gt;
  </code></pre>
  
  <p>SOMETHING STORED IN textarea TABLE</p>
  
  <pre><code>&lt;div style=" display:inline-block; margin:auto; width:800px; height:400px; overflow:auto;" id="rulesScroll" class="font c_blue_dark mCustomScrollbar interfo_section"&gt;
    &lt;span style=" display:inline-block; margin:30px; font-size:44px;" id="newsContain"&gt;
                 text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text text 
    &lt;/span&gt; 
  &lt;/div&gt;
  </code></pre>
  
  <p>Note: if you need to jquery.mCustomScrollbar.concat.min.js you can download scroll bar plugIn in here <a href="http://manos.malihu.gr/jquery-custom-content-scroller/" rel="nofollow">http://manos.malihu.gr/jquery-custom-content-scroller/</a></p>