User:Robert W King/Sandbox: Difference between revisions
imported>Robert W King |
imported>Robert W King |
||
Line 121: | Line 121: | ||
<br/><br/><br/><br/><br/><br/> | <br/><br/><br/><br/><br/><br/> | ||
==New thing== | ==New thing== |
Revision as of 14:56, 9 February 2008
Section 4 - Timeline Table Template (documented in HTML comments)
History of Computing Timeline | |||||||
+ | ?? BC | Slamis Tablet | |||||
|
|||||||
---|---|---|---|---|---|---|---|
|
300 BC-500 AD | Roman Hand Abacus | |||||
|
|||||||
|
~1200 AD | Modern Chinese Abacus | |||||
|
|||||||
|
?? | Leonardo Da Vinci writes the "Codex Madrid" | |||||
|
Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken Chicken
test using Template:Timeline_Table
New thing
Thing from excel
http://en.citizendium.org/wiki/Fire var wgPageName "Fire" var wgTitle "Fire" var wgArticleId "100023366" var wgCurRevisionId "100193030" http://en.citizendium.org/wiki?title=Fire&diff=prev&oldid=100193030 var wgPageName "Fire" var wgTitle "Fire" var wgArticleId "100023366" var wgCurRevisionId "100193030" <table class='diff'> <td colspan='2' class='diff-otitle'> <div id="mw-diff-otitle1"> <a href='/wiki?title=Fire&oldid=100192579'> <div id="mw-diff-otitle2"> <a href="/wiki/User:Hayford_Peirce" title="User:Hayford Peirce" <td colspan="2" class="diff-lineno"> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'>- <td class='diff-deletedline'> <del class="diffchange"> <td class='diff-marker'>+ <td class='diff-addedline'> <ins class="diffchange"> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <!-- diff cache key cz:diff:version:1.11a:oldid:100192579:newid:100193030 --> http://en.citizendium.org/wiki?title=Fire&diff=prev&oldid=100192579 var wgPageName "Fire" var wgTitle "Fire" var wgArticleId "100023366" var wgCurRevisionId "100193030" <td colspan='2' class='diff-otitle'> <div id="mw-diff-otitle1"> <a href='/wiki?title=Fire&oldid=100192564'> <div id="mw-diff-otitle2"> <a href="/wiki/User:Hayford_Peirce" title="User:Hayford Peirce"> <td colspan='2' class='diff-ntitle'> <div id="mw-diff-ntitle1"> <a href='/wiki?title=Fire&oldid=100192579'> <div id="mw-diff-ntitle2"> <a href="/wiki/User:Hayford_Peirce" title="User:Hayford Peirce"> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-deletedline'> <del class="diffchange"> <del class="diffchange"> <td class='diff-marker'>+ <td class='diff-addedline'> <ins class="diffchange"> <ins class="diffchange"> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <!-- diff cache key cz:diff:version:1.11a:oldid:100192564:newid:100192579 --> http://en.citizendium.org/wiki?title=Fire&diff=prev&oldid=100192432 var wgPageName "Fire" var wgTitle "Fire" var wgArticleId "100023366" var wgCurRevisionId "100193030" <td colspan='2' class='diff-otitle'> <div id="mw-diff-otitle1"> <a href='/wiki?title=Fire&oldid=100192314'> <div id="mw-diff-otitle2"> <a href="/wiki/User:Aleta_Curry" title="User:Aleta Curry"> <td colspan='2' class='diff-ntitle'> <div id="mw-diff-ntitle1"> <a href='/wiki?title=Fire&oldid=100192432'> <div id="mw-diff-ntitle2"> <a href="/wiki/User:Jeffrey_Scott_Bernstein" title="User:Jeffrey Scott Bernstein"> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'>- <td class='diff-deletedline'> <del class="diffchange"> <td class='diff-marker'>+ <td class='diff-addedline'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td colspan="2" class="diff-lineno"> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'>- <td class='diff-deletedline'> <del class="diffchange"> <td class='diff-marker'>+ <td class='diff-addedline'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> http://en.citizendium.org/wiki?title=Fire&diff=prev&oldid=100192314 var wgPageName "Fire" var wgTitle "Fire" var wgArticleId "100023366" var wgCurRevisionId "100193030" <td colspan='2' class='diff-otitle'> <div id="mw-diff-otitle1"> <a href='/wiki?title=Fire&oldid=100192191'> <div id="mw-diff-otitle2"> <a href="/wiki/User:Robert_W_King" title="User:Robert W King"> <td colspan='2' class='diff-ntitle'> <div id="mw-diff-ntitle1"> <a href='/wiki?title=Fire&oldid=100192314'> <div id="mw-diff-ntitle2"> <a href="/wiki/User:Aleta_Curry" title="User:Aleta Curry"> <td colspan="2" class="diff-lineno"> <td colspan="2" class="diff-lineno"> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'>+ <td class='diff-addedline'> <td class='diff-marker'>+ <td class='diff-addedline'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'> <td class='diff-marker'> <td class='diff-context'>
Thing 2
Module Module1 Dim url Dim CZ Dim wikipath Dim totalcdata Dim title Dim currentid Dim articleid Dim oldid Dim latestid Dim diffclass Sub Main() Dim T T = 0 initCZ() title = "fire" url = wikipath + "/" + title CZ.navigate(url) Do Until CZ.readyState = 4 Loop getcdata() articleid = Right(Mid(totalcdata, InStr(totalcdata, "wgArticleId"), 24), 9) currentid = Right(Mid(totalcdata, InStr(totalcdata, "CurRevisionId"), 26), 9) navtorecentdiff() Do getoldid() If latestid <> oldid Then getinsdiffchange() getdeldiffchange() navolddiff() End If Loop While latestid <> oldid End Sub Function initCZ() wikipath = "http://en.citizendium.org/wiki" CZ = CreateObject("InternetExplorer.Application") CZ.Toolbar = 0 CZ.Visible = 1 CZ.navigate(wikipath) Do Until CZ.readyState = 4 Loop Return CZ End Function Function getcdata() Dim tags Dim thing Dim x Dim test x = 0 tags = CZ.document.getElementsbyTagName("script") For Each Items In tags thing = tags.Item(x).innerHtml test = InStr(thing, "CDATA") If test <> 0 Then totalcdata = thing Exit For End If x = x + 1 Next Return totalcdata End Function Function navtorecentdiff() url = wikipath + "?title=" + title + "&diff=prev&oldid=" + (Right(currentid, 9)) CZ.navigate(url) Do Until CZ.readystate = 4 Loop Return url End Function Function getoldid() Dim tags Dim thing Dim x Dim test x = 0 tags = CZ.document.getElementsbyTagName("a") For Each Items In tags thing = tags.Item(x).outerHtml test = InStr(thing, "oldid") If test <> 0 Then latestid = oldid oldid = Mid(thing, test + 6, 9) Exit For End If x = x + 1 Next Return oldid End Function Function navolddiff() url = wikipath + "?title=" + title + "&diff=prev&oldid=" + oldid CZ.navigate(url) Do Until CZ.readystate = 4 Loop Return url End Function Function getinsdiffchange() Dim tags Dim thing Dim x Dim test Dim totalwrite x = 0 tags = CZ.document.getElementsbyTagName("ins") For Each Items In tags thing = tags.Item(x).innerHtml test = InStr(thing, "class=diffchange") If thing <> Nothing Then diffclass = diffclass + "+" + "'" + thing + "'" + "; " End If x = x + 1 Next totalwrite = title + " | " + articleid + " | " + latestid + " | " + diffclass + vbCrLf IO.File.AppendAllText(("c:\" + title + "_insdiffchange.txt"), totalwrite) diffclass = Nothing Return diffclass End Function Function getdeldiffchange() Dim tags Dim thing Dim x Dim test Dim totalwrite x = 0 tags = CZ.document.getElementsbyTagName("del") For Each Items In tags thing = tags.Item(x).innerHtml test = InStr(thing, "class=diffchange") If thing <> Nothing Then diffclass = diffclass + "-" + "'" + thing + "'" + "; " End If x = x + 1 Next totalwrite = title + " | " + articleid + " | " + latestid + " | " + diffclass + vbCrLf IO.File.AppendAllText(("c:\" + title + "_deldiffchange.txt"), totalwrite) diffclass = Nothing Return diffclass End Function End Module
Excel VB Script version
Function grabdiffdata() Dim url Dim CZ Dim wikipath Dim totalcdata Dim title Dim currentid Dim articleid Dim oldid Dim latestid Dim diffclass Dim T Dim tags Dim thing Dim x Dim test Dim totalwrite T = 0 wikipath = "http://en.citizendium.org/wiki" Set CZ = CreateObject("InternetExplorer.Application") CZ.Toolbar = 0 CZ.Visible = 1 CZ.navigate (wikipath) Do Until CZ.readyState = 4 Loop title = "fire" url = wikipath + "/" + title CZ.navigate (url) Do Until CZ.readyState = 4 Loop x = 0 Set tags = CZ.document.getElementsByTagName("script") For Each Items In tags thing = tags.Item(x).innerHTML test = InStr(thing, "CDATA") If test <> 0 Then totalcdata = thing Exit For End If x = x + 1 Next articleid = Right(Mid(totalcdata, InStr(totalcdata, "wgArticleId"), 24), 9) currentid = Right(Mid(totalcdata, InStr(totalcdata, "CurRevisionId"), 26), 9) url = wikipath + "?title=" + title + "&diff=prev&oldid=" + (Right(currentid, 9)) CZ.navigate (url) Do Until CZ.readyState = 4 Loop Do x = 0 Set tags = CZ.document.getElementsByTagName("a") For Each Items In tags thing = tags.Item(x).outerHTML test = InStr(thing, "oldid") If test <> 0 Then latestid = oldid oldid = Mid(thing, test + 6, 9) Exit For End If x = x + 1 Next If latestid <> oldid Then x = 0 Set tags = CZ.document.getElementsByTagName("ins") For Each Items In tags thing = tags.Item(x).innerHTML test = InStr(thing, "class=diffchange") If thing <> Empty Then diffclass = diffclass + "+" + "'" + thing + "'" + "; " End If x = x + 1 Next totalwrite = title + " | " + articleid + " | " + latestid + " | " + diffclass + vbCrLf 'IO.File.AppendAllText(("c:\" + title + "_insdiffchange.txt"), totalwrite) diffclass = Empty x = 0 Set tags = CZ.document.getElementsByTagName("del") For Each Items In tags thing = tags.Item(x).innerHTML test = InStr(thing, "class=diffchange") If thing <> Empty Then diffclass = diffclass + "-" + "'" + thing + "'" + "; " End If x = x + 1 Next totalwrite = title + " | " + articleid + " | " + latestid + " | " + diffclass + vbCrLf 'IO.File.AppendAllText(("c:\" + title + "_deldiffchange.txt"), totalwrite) diffclass = Empty url = wikipath + "?title=" + title + "&diff=prev&oldid=" + oldid CZ.navigate (url) Do Until CZ.readyState = 4 Loop End If Loop While latestid <> oldid End Function