This file contains 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(){ | |
'use strict'; | |
angular.module('App') | |
.controller('AboutFormCtrl',['$scope','$log',function($scope,$log){ | |
$log.debug('AboutFormCtrl'); | |
$scope.age = null; | |
$scope.generateAges = function(){ | |
var ages = []; |
This file contains 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
<section> | |
<p> | |
<p> | |
<span ng-class="{'label-success':focus}" class="label label-default">Focus!</span> | |
<span ng-class="{'label-warning':!focus}" class="label label-default">Blur!</span> | |
</p> | |
<input ng-model="title" class="form-control" ng-focus="focus=true" ng-blur="focus=false" placeholder="Enter a title for your book"/> | |
<div class="panel"> | |
<p> <h1> [[ focus ]]</h1> The title of your book is [[ title.length ? title : "No Name" ]] </p> | |
</div> |
This file contains 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
<section> | |
<h2>ngInclude</h2> | |
<script type="text/ng-template" id="other.html"> | |
<div>Other Template</div> | |
</script> | |
<nav> | |
<button class="btn btn-primary" ng-click="tpl='other.html'"> | |
load other.html | |
</button> | |
<button class="btn btn-primary" ng-click="tpl=null"> |
This file contains 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
.directive('myCircle',function(){ | |
return { | |
templateUrl: 'circle.html', | |
replace: true, | |
controller: ['$scope','$rootScope',function($scope,$rootScope){ | |
$scope.afterClick = function(){ | |
console.log('clicked'); | |
$rootScope.$broadcast('clicked'); | |
} | |
}], |
This file contains 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
.controller('homeListCtrl',['$scope','$rootScope','$http','homeService', | |
function($scope,$rootScope,$http,homeService){ | |
$scope.selectUser = function(user){ | |
homeService.setCurrentUser(user); | |
$rootScope.$broadcast('userChanged'); | |
} | |
}]) |
This file contains 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 ng-init="customers=[{name:'abc',city:'defg'},{name:'def',city:'helo'}]"> | |
<input type="text" ng-model="customerFilter.name"/> | |
<table> | |
<tr> | |
<th ng-click="sortBy='name';reverse=!reverse">Name</th> | |
<th ng-click="sortBy='city';reverse=!reverse">City</th> | |
</tr> | |
<tr ng-repeat="cust in customers | filter:customerFilter.name | orderBy:sortBy:reverse" > | |
<td>[[ cust.name | uppercase ]]</td> | |
<td>[[ cust.city | uppercase ]]</td> |
This file contains 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
sysbench --test=cpu --cpu-max-prime=20000 run | |
sysbench --test=fileio --num-threads=16 --file-rw-ratio=5 \ | |
--file-total-size=300M --file-test-mode=rndrw prepare | |
sysbench --test=fileio --num-threads=16 --file-rw-ratio=5 \ | |
--file-total-size=300M --file-test-mode=rndrw run | |
sysbench --test=memory --num-threads=16 \ | |
--memory-block-size=8192 --memory-total-size=1G run |
This file contains 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
1. alpha release | |
example 1.2a1 | |
unstable missing features | |
2. beta release | |
example 2.3.1b2 | |
feature complete still buggy | |
3. release candidate |
This file contains 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
-- The Head Section -- | |
-- https://thesprawl.org/research/writing-nse-scripts-for-vulnerability-scanning/ | |
description = [[Sample script to detect a fictional vulnerability | |
in a fictional ArcticFission 1.0 web server]] | |
--- | |
-- @usage | |
-- nmap --script http-vuln-check <target> | |
-- @output | |
-- PORT STATE SERVICE |
This file contains 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
description = [[ Attempt to get App ]] | |
author = "wcc526 <949409306@qq.com>" | |
license = "Same as Nmap" | |
categoriese = {"default","discovery","safe"} | |
local shortport = require "shortport" | |
local http = require "http" | |
portrule = shortport.port_or_service({80,8081},{"http"}) |
OlderNewer