-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjavascript.html
More file actions
205 lines (144 loc) · 7.87 KB
/
Copy pathjavascript.html
File metadata and controls
205 lines (144 loc) · 7.87 KB
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
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Pocket Survival Guide - javascript</title>
<link rel="stylesheet" href="psg.css" type="text/css">
<LINK REL="SHORTCUT ICON" HREF="favicon.ico" type="image/x-icon"/>
<META NAME="description" content="System Administrator Pocket Survival Guide - A series of notes for Sys Admin"/>
<META NAME="keyword" content="Sys Admin, System Administrator, Solaris, HP-UX, AIX, Linux, Note, Notes, Pocket, Survival, Guide, psg, data center, power, electrical, plug, LYS, LKS, LAPPLAPP"/>
<META NAME="Robots" CONTENT="all"/>
<META NAME="Author" CONTENT="Tin Ho"/>
<!-- old google analytics tracker at bottom, which is likely reg to dropbox posting -->
<!-- Global site tag (gtag.js) - Google Analytics - t6@g new property for psg-github site -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-4515095-6"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-4515095-6');
</script>
</head>
<body>
<div class="navheader">
<table summary="Navigation header" width="100%">
<tbody>
<tr>
<th colspan="4" align="center">
<A HREF="http://psg.ask-margo.com/">Sys Admin Pocket Survival Guide - JavaScript</A>
</th>
</tr>
<tr>
<td align="left"><a accesskey="h" href="psg.html">Home</a></td>
<td align="center"><a accesskey="y" href="python.html">Python</a></td>
<td align="center"><a accesskey="j" href="javascript.html">javascript</a></td>
<td align="center"><a accesskey="p" href="php.txt">PHP</a></td>
<td align="center"><a accesskey="l" href="perl.html">Perl</a></td>
<td align="right"><a accesskey="s" href="shellScript.txt">shellScript</a></td>
</tr>
</tbody>
</table>
<hr></div>
<div class="chapter" lang="en">
<div class="titlepage">
</div>
</div>
<div align="CENTER">
<A HREF="http://www.explainxkcd.com/wiki/index.php/1854"><IMG SRC="fig/xkcd_refresh_types.png" title="The hardest refresh requires both a Mac keyboard and a Windows keyboard as a security measure, like how missile launch systems require two keys to be turned at once." alt="Refresh Types"></A><BR>
</div>
<H1>JavaScript</H1>
<H2>101</H2>
<PRE>
aka Ecma Script.
ES5? ES6? ES7?
may still want to move it back to psg as javascript.html
tba
Hash:
* http://www.mojavelinux.com/articles/javascript_hashes.html
* https://stackoverflow.com/questions/1208222/how-to-do-associative-array-hashing-in-javascript
Object:
- {}
- var myObj = {};
</PRE>
<A ID="output"></A>
<H2>Quick Output</H2>
<PRE>
Quick output
- alert( "Hello World"); // this is a dialog pop up
- console.log("Hello Debugger"); // ^I in chrome opens debugger, go to console tab. (ctrl-sh-i)
- https://stackoverflow.com/questions/1208222/how-to-do-associative-array-hashing-in-javascript
- document.getElementById(id).innerHTML = "Hello Internet"; // id would be the id tag in a <div> etc.
</PRE>
<BR><HR><BR>
<H2>Refs/Links</H2>
<UL>
<LI><A HREF="script/javascript_eg.html">javascript_eg</A> (my own examples)</LI>
<LI><A HREF="script/javascript_date.html">javascript_date</A> (simple script print current date/time)</LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/eg-code/eg-js.html">eg-code/eg-js</A>ajax eg, prob not working anymore</LI>
<LI></LI>
<LI><A HREF="https://github.com/tin6150/inet-dev-class/tree/master/mapbox">mapbox examples</A>. See Examples section, most have javascript in them.</LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/mapbox/smelly_polyg.html">Smelly</A>Mapbox JS app for ETA collaboration about garbage/energy sites and odor dispersion simulation info</LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/mapbox/ZWEDC_jq_slider.html">mapbox with jQuery slider</A>slider that i didn't end up using, but good example of jQuery usage with Mapbox GL JS</LI>
<LI></LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/js/">inet-dev-class/js</A> (eg I tried before getting Mapbox GL JS working) ::</LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/js/helloWorld.js">helloWorld.js</A>var, const, console.log()</LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/js/mapFromFile.js">mapFromFile.js</A>(better to look at smelly above)</LI>
<LI><A HREF=""></A></LI>
<LI></LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/jQuery/">jQuery</A>
(<A HREF="jquery_class/">alt loc in jquery_class</A>) :: </LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/jQuery/main.html">jQuery class homework toc</A>(don't seems to be working after dropbox cut off html web hosting)</LI>
<LI><A HREF="https://tin6150.github.io/taxonomy_reporter/taxorpt_sample_output.html">taxonomy_reporter</A>data table jQuery for highlight, sectioning and sorting. yet html remains very clean for even text-based viewing.</LI>
<LI><A HREF=""></A></LI>
<LI></LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/css/">css</A> :: </LI>
<LI><A HREF="https://tin6150.github.io/inet-dev-class/css/ho-embeded.html">ho-embeded.html</A> simple page with embeded css</LI>
<LI>See psg2.html/psg2.css for example used for the Pocked SysAdmin Guide pages, done after taking the css class.</LI>
<LI>psg2.html, psg1.html both have various javascript thing for g+, translate, and other stuff in it </LI>
<LI><A HREF=""></A></LI>
<LI></LI>
</UL>
<BR>
<A ID="validator"></A>
<H1>Validator</H1>
Old school HTML badge icon buttons :) <BR>
HTML validator: http://validator.w3.org/ <BR>
<!--(no more badge icon?)-->
<A HREF="https://validator.w3.org/check?uri=https%3A%2F%2Ftin6150.github.io%2Fpsg%2Fjavascript.html&charset=%28detect+automatically%29&doctype=HTML+2.0&group=0&user-agent=W3C_Validator%2F1.3+http%3A%2F%2Fvalidator.w3.org%2Fservices">(for this page)</A> <BR>
<BR>
(see simple.html for easier test first)
<BR>
Hmm for css... need new link from blue icon. <BR>
CSS validator:
<a href="http://jigsaw.w3.org/css-validator/">http://jigsaw.w3.org/css-validator/</A>
<BR>
<a href="http://jigsaw.w3.org/css-validator/check/referer">
<img style="border:0; width:88px; height:31px"
src="http://jigsaw.w3.org/css-validator/images/vcss"
alt="CSS validity icon" />
</a>
<-- This version said to work with HTML/XML, but don't seems to work no more for me.
<BR>
<a href="http://jigsaw.w3.org/css-validator/validator?uri=https%3A%2F%2Ftin6150.github.io%2Fpsg%2Fjavascript.html&profile=css3svg&usermedium=all&warning=1&vextwarning=">
<img style="border:0;width:88px;height:31px"
src="https://jigsaw.w3.org/css-validator/images/vcss-blue"
alt="Valid CSS!" />
</a>
<-- This version with embeded uri works
<BR><BR><HR>
<div align="CENTER">
[Doc URL: <A HREF="http://tin6150.github.io/psg/psg/javascript.html">
http://tin6150.github.io/psg/psg/javascript.html</A>]
<BR>
(cc) Tin Ho. See
<A HREF=psg.html#cc>main page</A>
for copyright info. <BR>
<HR>
<A HREF="http://www.taos.com"><IMG SRC="banner/taos_banner1.gif" width="728" height="98"></A>
</div>
<div class="sig"><BR>
hoti1<BR>
bofh1</div>
</body>
<!-- Google analytics new tracking code ga.js. Will actually need to add this code to every page for full tracking! (still the case in 2011?) Using my gmail login 2011.0617 updated with code for http://tin6150.github.io/psg/psg.html --> <script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-4515095-4']); _gaq.push(['_trackPageview']); (function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script>
</html>