-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathajax.html
173 lines (144 loc) · 8.8 KB
/
ajax.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
<!DOCTYPE html>
<html xmlns= xml:lang="en-US" lang="en-US">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="description" contect="A visual representation of Javascript variables, funtions and loops. This one is Ajax calls"
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/prism/1.5.0/themes/prism.min.css"
/>
<title>Ajax movie</title>
<style>
code[class*=language-], pre[class*=language-] {
white-space: pre-line;
word-wrap: break-word;
}
</style>
</head>
<body class="header-sticky">
<!-- Header -->
<header id="header" class="header clearfix" style="margin-bottom: 20px;">
<div class="container">
<div class="row">
<div class="col-md-6">
<div class="header-wrap clearfix">
<div id="logo" class="logo">
<a href="index.html" rel="home">
<img src="images/video/script.jpg" style= "width: 20%" alt="sesame script logo">
</a>
</div><!-- /.logo -->
</div>
</div>
<div class="col-md-6">
<div class="page-title-heading">
<h1 class="title" style="font-size: 3em;">Ajax calls in Javascript</h1>
</div><!-- /.page-title-captions -->
</div><!-- /.col-md-12 -->
</div><!-- /.row -->
</div><!-- /.container -->
</div><!-- /.page-title -->
</header><!-- /.header -->
<!-- Blog single -->
<section class="blog blog-single without-sidebar">
<div class="container">
<div class="row">
<div class="col-md-12">
</div>
<div class="col-md-12">
<div class="post-wrap">
<article class="entry">
<div class="entry-wrapper">
<div class="entry-content">
<pre><code class="language-javascript" style="width: 100%;">
$("button").click(function(){
$.ajax({url: "demo_test.txt", success: function(result){
$("#div1").html(result);
}});
});
</code></pre>
<div class="embed-responsive embed-responsive-16by9">
<iframe class="embed-responsive-item" src="https://www.youtube.com/embed/E-jxg7Ef3j0"></iframe>
</div>
<p><span class="dropcap">A </span> synchronous JavaScript And XML.
AJAX is not a programming language. AJAX just uses a combination of:
A browser built-in XMLHttpRequest object (to request data from a web server)
JavaScript and HTML DOM (to display or use the data)
</p>
</div><!-- /entry-content -->
</div>
</article><!-- /.entry -->
</div><!-- /.post-wrap -->
</div>
</div><!-- /.row -->
</div><!-- /.container -->
</section>
</div><!-- /.site-wrapper -->
<!-- Canvas -->
<div class="flat-footer">
<div class="footer-widgets">
<div class="container">
<div class="row">
<div class="col-md-12">
<div id="text-3" class="widget widget_text">
<div class="textwidget">
<img src="images/video/script.jpg" style="width: 10%;" alt="Sesame Script Logo">
</div>
</div>
</div>
</div><!-- /.row -->
</div><!-- /.container -->
</div><!-- /#page-footer -->
<div class="footer-content">
<div class="container">
<div class="row">
<div class="col-md-12">
<div class="social-links">
<a href="https://linkedin.com/in/katharrislink"><i class="fa fa-linkedin"></i></a>
<a href="https://github.com/katophelix"><i class="fa fa-github"></i></a>
<a href="mailto:katharrismail@gmail.com"><i class="fa fa-envelope"></i>
<a href="https://katophelix.github.io/resume/"><i class="fa fa-laptop"></i></a>
<a href=" https://www.youtube.com/channel/UCrO9ZWdhs-jQrMg1b_eng1g"><i class="fa fa-youtube"></i></a>
</div>
</div>
</div>
<div class="row">
<div class="col-md-12">
</div>
</div>
<div class="col-md-12">
<div class="copyright">
<div class="copyright-content">Sesame Script <span>•</span> Kat Harris<br>
</div><!-- /.copyright-content -->
</div><!-- /.copyright -->
</div>
</div> <!-- /.row -->
</div><!-- /.container -->
</div>
<!-- Go Top -->
<a class="go-top">
</a>
<!-- Javascript -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.5.0/prism.min.js"></script>
<script type="text/javascript" src="javascript/jquery.min.js"></script>
<script type="text/javascript" src="javascript/bootstrap.min.js"></script>
<script type="text/javascript" src="javascript/owl.carousel.js"></script>
<script type="text/javascript" src="javascript/jquery.flexslider-min.js"></script>
<script type="text/javascript" src="javascript/jquery.magnific-popup.min.js"></script>
<script type="text/javascript" src="javascript/jquery.easing.js"></script>
<script type="text/javascript" src="javascript/parallax.js"></script>
<script type="text/javascript" src="javascript/jquery.cookie.js"></script>
<script type="text/javascript" src="javascript/main.js"></script>
</body>
</html>
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.5.0/prism.min.js"></script>
<script src="https://code.jquery.com/jquery-3.4.1.slim.min.js" integrity="sha384-J6qa4849blE2+poT4WnyKhv5vZF5SrPo0iEjwBvKU7imGFAV0wwj1yYfoRSJoZ+n" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/popper.js@1.16.0/dist/umd/popper.min.js" integrity="sha384-Q6E9RHvbIyZFJoft+2mJbHaEWldlvI9IOYy5n3zV9zzTtmI3UksdQRVvoxMfooAo" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/js/bootstrap.min.js" integrity="sha384-wfSDF2E50Y2D1uUdj0O3uMBJnjuUD4Ih7YwaYd1iqfktj0Uod8GCExl3Og8ifwB6" crossorigin="anonymous"></script>
</body>
</html>