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
| if not exist "reports\" (mkdir reports) | |
| cd reports | |
| if exist report.xml ( | |
| del "report.xml" | |
| ) | |
| type nul >report.xml | |
| echo ^<?xml version="1.0" encoding="UTF-8"?> >> report.xml |
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
| function HtmlParser(){} | |
| function Stack(){ | |
| this.stac = []; | |
| this.pop = function(){ | |
| return this.stac.pop(); | |
| }; | |
| this.push = function(item){ | |
| this.stac.push(item); | |
| }; | |
| this.peek = 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
| var a = document.getElementByTagName('view') | |
| for(var i = 0; i < a.length; i++){ | |
| var b = a[i].id; | |
| c = b.split('-'); | |
| for(var j = 0; j < c.length; j++){ | |
| c[j] = c[j].replace(/^./, c[j][0].toUpperCase()); | |
| } | |
| var d = c.join(''); | |
| console.log(d) |
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
| module.exports = function(grunt) { | |
| require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks); | |
| grunt.initConfig({ | |
| pkg: grunt.file.readJSON('package.json') | |
| }); | |
| grunt.registerTask('default', []); | |
| }; |
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
| { | |
| "name": "", | |
| "version": "0.1.0", | |
| "author": "Shihuan Shao", | |
| "devDependencies": { | |
| "grunt": "~0.4.1", | |
| "matchdep": "^1.0.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
| ############# | |
| # Support multiple xml files | |
| ############# | |
| input | |
| { | |
| file{ | |
| path => ["C:/inetpub/logs/FailedReqLogFiles/*/*.xml"] | |
| start_position => "beginning" | |
| # filter is not thread safe, so have to move the multiline into the input | |
| codec => multiline{ |
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 c = [{'32059': 'true'}, {'32074': 'true'}, {'32062': 'true'}, {'32065': 'true'}, {'32068': 'true'}, {'32071': 'true'}]; | |
| var keys = []; | |
| for(var k in c){ | |
| var a = c[k]; | |
| keys.push(parseInt((Object.keys(a))[0])); | |
| } | |
| keys.join(", ") |
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 fs = require('fs'); | |
| function readLines(input, func){ | |
| var remaining = ''; | |
| var array = []; | |
| input.on('data', function(data){ | |
| remaining += data; | |
| var index = remaining.indexOf('\n'); | |
| while(index > -1){ | |
| var line = remaining.substring(0, index); |
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
| $.ajax({ | |
| type:"POST", | |
| url: "https://salesproducts.api.test-godaddy.com/v1/pl/1/cart/packages", | |
| contentType: "application/json", | |
| data: "requestData=" + JSON.stringify({ | |
| pkgid: "office365migration_tier3_012mo", | |
| qty: 1, | |
| itc: "eml_365_workspace", | |
| ci: "86495" | |
| }), |
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
| $('#addrBox').on('mouseup keyup', function(){ | |
| var $this = $(this); | |
| var val = $this.val(); | |
| val = val.length; | |
| if(val === 0){ | |
| $this.attr('autocomplete', 'on'); | |
| } | |
| else{ | |
| $this.attr('autocomplete', 'off'); | |
| } |
OlderNewer