This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <DHT22.h> | |
| // Only used for sprintf | |
| #include <stdio.h> | |
| // Data wire is plugged into port 7 on the Arduino | |
| // Connect a 4.7K resistor between VCC and the data pin (strong pullup) | |
| #define DHT22_PIN 7 | |
| // Setup a DHT22 instance | |
| DHT22 myDHT22(DHT22_PIN); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python | |
| import sys, getopt | |
| from sklearn.feature_extraction.text import TfidfVectorizer | |
| from sklearn.metrics.pairwise import cosine_similarity | |
| import mysql.connector | |
| from mysql.connector import errorcode | |
| SID = sys.argv[1] | |
| cnx = mysql.connector.connect(user = 'cuser', password = 'Test*', database = 'SPdb') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Server.js | |
| * Author: Lifang Zhang | |
| * Date: 11.10.2015 | |
| */ | |
| var express = require('express'); | |
| var bodyParser = require('body-parser'); | |
| var app = express(); | |
| var Event = require('./models/event'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var express = require('express'); | |
| var app = express(); | |
| var httpProxy = require('http-proxy'); | |
| var redis = require("redis"); | |
| var redisclient = redis.createClient(); | |
| // Create a proxy server | |
| var proxy = httpProxy.createProxyServer({}); | |
| app.listen(443, function () { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdint.h> | |
| #include <stdio.h> | |
| #include <string.h> | |
| #include <stdlib.h> | |
| #include "aescopa.h" | |
| #include "aes128e.h" | |
| #define NUM_BYTES 16 | |
| #define DEBUG 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdint.h> | |
| #include <stdlib.h> | |
| #include <stdio.h> | |
| #include <string.h> | |
| #include "aes128e.h" | |
| void matrixtransform(unsigned char *to, const unsigned char *from); | |
| void matrixhexprint(unsigned char *arr, int length); | |
| void addroundkey(unsigned char *key, unsigned char *c); | |
| void keyexpansion(unsigned char *roundkey, int roundindex); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Licensed to the Apache Software Foundation (ASF) under one | |
| * or more contributor license agreements. See the NOTICE file | |
| * distributed with this work for additional information | |
| * regarding copyright ownership. The ASF licenses this file | |
| * to you under the Apache License, Version 2.0 (the | |
| * "License"); you may not use this file except in compliance | |
| * with the License. You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div class="jumbotron well well-lg"> | |
| <h4 class="text-center"><strong>Welcome to our address book</strong></h4> | |
| <p>With our address book, you can see all the contacts by clicking </strong>Show contacts</strong>, and you can edit your contacts which includes <strong> add </strong>, <strong> modify </strong>, <strong> delete </strong>. Moreoever, you can load your <strong> google </strong> contacts to your contacts. Use it, it is easy and fun, you will definitely enjoy it :)</p> | |
| </div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| jQuery.noConflict(); | |
| jQuery( document ).ready(function() { | |
| // http://stackoverflow.com/questions/901115/how-can-i-get-query-string-values-in-javascript | |
| function getParameterByName(name) { | |
| name = name.replace(/[\[]/, "\\[").replace(/[\]]/, "\\]"); | |
| var regex = new RegExp("[\\?&]" + name + "=([^&#]*)"), | |
| results = regex.exec(location.search); | |
| return results === null ? "" : decodeURIComponent(results[1].replace(/\+/g, " ")); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Image_page =1; | |
| var Image_add = 'http://api.flickr.com/services/rest/?'; | |
| var query_str = 'method=flickr.photos.search&per_page=12&api_key=be59384d594d726d0f05c3d3d75045f0&format=rest&tags='; | |
| var Key_word = ''; | |
| var url = ''; | |
| $(document).ready(function () { | |
| $(document).on('click', '.btn.btn-primary.searchbtn', function (){ | |