|
| 26 Mar 2015 05:54 PM |
KIDDIES YOU NEED TO LEARN A REAL LANGUAGE LIKE ENGLISH OR JAVASCRIPT, NOT THIS WANNABE LANGUAGE OF LUA!
HAVE A LOOK AT HOW THE MASTERS DO IT!
function pasteHTML() {
var dataPackageView = Windows.ApplicationModel.DataTransfer.Clipboard.getContent();
if (dataPackageView.contains(Windows.ApplicationModel.DataTransfer.StandardDataFormats.html)) {
// Get the HTML Format (CF_HTML) from DataPackageView. dataPackageView.getHtmlFormatAsync().done(function (htmlFormat) {
// Extract the HTML fragment. var htmlFragment = Windows.ApplicationModel.DataTransfer.HtmlFormatHelper.getStaticFragment(htmlFormat);
// Add the fragment to the DOM. document.getElementById("htmlOutput").innerHTML = htmlFragment;
// Replace local image file URLs, if any, with the contents of the resourceMap. var images = document.getElementById("htmlOutput").getElementsByTagName("img");
// Check first if there are any images (img tags) in the fragment, because // calling the getResourceMapAsync method can be resource intensive. if (images.length > 0) { dataPackageView.getResourceMapAsync().done(function (resourceMap) {
// Check whether the resourceMap contains any items. if (resourceMap.size > 0) { for (var i = 0, len = images.length; i < len; i++) { var imageElement = images[i]; // Look up RandomAccessStreamReference value corresponding to this // image's SRC property. var streamRef = resourceMap.lookup(imageElement.getAttribute("src")); if (streamRef) { // Generate blob URL, and replace contents of the SRC property. replaceSrcURL(imageElement, streamRef); } } } });
}
}, function (e) { displayError("Error retrieving HTML format from Clipboard: " + e); }); } else { document.getElementById("scenario1HtmlOutput").innerText = "HTML format is not available in clipboard"; } }
function replaceSrcURL(imageElement, streamRef) { // Map the image element's src to a corresponding blob URL generated from the streamReference. streamRef.openReadAsync().done(function (imageStream) { var blobObject = window.MSApp.createBlobFromRandomAccessStream(imageStream.contentType, imageStream); var blobUrl = window.URL.createObjectURL(blobObject, { oneTimeOnly: true }); imageElement.src = blobUrl; }, function (e) { displayError("Error opening stream corresponding to the image element with SRC=\"" + imageElement.getAttribute("src") + "\". Error: " + e); }); } |
|
|
| Report Abuse |
|
|
tecno15
|
  |
| Joined: 10 Sep 2009 |
| Total Posts: 1372 |
|
|
| 26 Mar 2015 05:55 PM |
| the war shall go on, march, my lua friends |
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
| |
|
| |
|
Funse
|
  |
| Joined: 11 Jun 2012 |
| Total Posts: 7887 |
|
| |
|
IIIIIIlII
|
  |
| Joined: 06 Jan 2011 |
| Total Posts: 710 |
|
|
| 26 Mar 2015 05:58 PM |
| lol coding java for food, ain't nobody got time for clothas |
|
|
| Report Abuse |
|
|
| |
|
|
| 26 Mar 2015 05:59 PM |
| JavaScript is love, javascript is life!! |
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 26 Mar 2015 05:59 PM |
class gtfo{ public static void main(String[] args){ String gtfo = "gtfo"; while(true){ System.out.println("gtfo"); gtfo += " gtfo"; } } { |
|
|
| Report Abuse |
|
|
vat21s
|
  |
| Joined: 07 Jun 2010 |
| Total Posts: 2508 |
|
|
| 26 Mar 2015 06:00 PM |
Lua is good for calculations thats about it, You can't beat those awesome classes in Java e.e
and yes LUA sucks but Lua is alright. |
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 26 Mar 2015 06:00 PM |
| ...how the hell did I mess up that bracket |
|
|
| Report Abuse |
|
|
|
| 26 Mar 2015 06:01 PM |
^ Was just about to say...
"gtfo += " gtfo";"??? |
|
|
| Report Abuse |
|
|
|
| 26 Mar 2015 06:01 PM |
Plagiarism is fun. Not really. It's just lame. If you can't come up with your own code, your argument is invalid. |
|
|
| Report Abuse |
|
|
| |
|
|
| 26 Mar 2015 06:06 PM |
WAIT... WTH IS THAT A T-SHIRT I MADE???? |
|
|
| Report Abuse |
|
|
anaIyze
|
  |
| Joined: 29 May 2014 |
| Total Posts: 2048 |
|
|
| 26 Mar 2015 06:07 PM |
| Lol script kiddie ^ Bahahah |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 26 Mar 2015 06:07 PM |
OP you're stupid. Lua and Javascript can't be compared, considering they are usually (almost always) used for different purposes. It's like comparing C with PHP, you don't.
|
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 26 Mar 2015 06:07 PM |
>"gtfo += " gtfo";"???
'value1 += value2' is the equivalent of 'value1 = value1 + value2'
In the case of strings, it concatenates them. I think you lose. |
|
|
| Report Abuse |
|
|
|
| 26 Mar 2015 06:08 PM |
@anaize how am I a script kitty? |
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 26 Mar 2015 06:09 PM |
| ^ I think you ninja'd him and he meant OP |
|
|
| Report Abuse |
|
|
|
| 26 Mar 2015 06:10 PM |
@not ah, okay
still surprised that this wannabe is wearing one of my t-shirts -.- |
|
|
| Report Abuse |
|
|
kert109
|
  |
| Joined: 31 Dec 2009 |
| Total Posts: 681 |
|
|
| 26 Mar 2015 06:23 PM |
I feel OP copied and pasted.
And I think someone is getting Java and JavaScript confused..
Btw, don't compare javascript and lua. As that other guy said, it's like comparing php and C++. |
|
|
| Report Abuse |
|
|
|
| 26 Mar 2015 06:57 PM |
| I already said the OP copied and pasted. |
|
|
| Report Abuse |
|
|
|
| 26 Mar 2015 07:34 PM |
| Just wanna add that that was probably copied and pasted. Someone with a high enough IQ to understand and learn java wouldn't be as stupid to troll here like that. xd |
|
|
| Report Abuse |
|
|
anaIyze
|
  |
| Joined: 29 May 2014 |
| Total Posts: 2048 |
|
|
| 27 Mar 2015 01:08 PM |
http://www.getcodesamples.com/src/53EDC212/55DB6D0B
Dumbass skid LOl |
|
|
| Report Abuse |
|
|