博文

Metacharacter: Meaning of UNIX

Recognizing metacharacters ~  Home directory `  Command substitution(old style) # Command $ Variable expression & Background job * String wildcard (  Start of subshell )  End of subshell \  Escape next character |  Pipe [  Start of wildcard set ]  End of wildcard set { Start of command block } End of command block ;  Pipeline command separator '  Quote mark (strong) " Quote mark (weak) < Redirect input > Redirect output /  Pathname address separator ?  Single-character wildcard !  Pipeline logical  NOT ---------------------------------------- ps $$ bash --version whoami type clear type exit echo  $SHELL echo $BASH_VERSION pwd ls ------------------- Dealing wildcard Wildcard   Matches ?                Any single character                 ls...

jquery ajax 'Authorization' 'Bearer' 'Basic'

https://stackoverflow.com/questions/5507234/use-basic-authentication-with-jquery-and-ajax Method 1: var uName = "abc" ; var passwrd = "pqr" ; $ . ajax ({ type : '{GET/POST}' , url : '{urlpath}' , headers : { "Authorization" : "Basic " + btoa ( uName + ":" + passwrd ); }, success : function ( data ) { //Success block }, error : function ( xhr , ajaxOptions , throwError ){ //Error block }, }); Method 2: var uName = "abc" ; var passwrd = "pqr" ; $ . ajax ({ type : '{GET/POST}' , url : '{urlpath}' , beforeSend : function ( xhr ){ xhr . setRequestHeader ( 'Authorization' , "Basic " + btoa ( uName + ":" + passwrd )); }, success : function ( data ) { //Success block }, error : function ( xhr , ajaxOptions , throwEr...

SprintBoot start

#The 3 ways to run Spring Boot application 1. In IntelliJ IDEA Ultimate @SpringBootApplication pubic class TestApplication{...} @RestController public class otherController{  @RequestMapping(value="/hello", method=RequestMethod.Get)  public String say(){return "test";} run 'TestApplicaton' 2. mvn spring-boot.run cd projectfolder mvn spring-boot.run 3. java -jar mvn install cd target  > java -jar  projectname-0.0.1-SNAPSHOT.jar #Springboot2.4.4 and Log4j2 --------------------------------------------------------------------------- ##1.1 For console color text, set disableAnsi="false" ; ##1.2  log4j conflict, using <exclusions>; ##1.3 no showing in console,  must be run after SpringApplication.run(MailApplication.class, args); <Console name="Console" target="SYSTEM_OUT">             <PatternLayout disableAnsi="false"          ...

You're Offline

图片
You're Offline July 12, 2017 ⋅ Code From : https://mxb.at/blog/youre-offline/?imm_mid=0f47f9&cmp=em-web-na-na-newsltr_20170719 A truly responsive website should adapt to all kinds of situations. Besides different viewport sizes, there are other factors to consider. A change in connectivity is one of them. Earlier this week, I was sitting in a train on my way to speak at a local meetup. InterCity trains in Austria all have WIFI now, so I was doing some last-minute work on my slides online. Train WIFI being what it is though, the network wasn’t exactly reliable. The connection kept dropping everytime we went through a tunnel or too many passengers were logged on. This is quite a common scenario. People are on the move, network coverage can be poor, internet connections fail. Luckily, we can prepare our websites for this and make them more resilient by building them offline-first . Offline support is awesome, however your users might not be aware of thes...

Wijmo FlexGrid / Drag and Drop

Ref: http://wijmo.com/topic/flexgrid-drag-and-drop/ http://wijmo.com/topic/wijgrid-and-draggable-rows/ http://jsfiddle.net/Wijmo5/0z1ou6cn/ http://jsfiddle.net/tzd95q74/ //=================== <div class="container">   <h1>     Dragging Rows from the FlexGrid   </h1>   <p>     You can use the HTML5 drag/drop API to implement row dragging     from, into, or between FlexGrid controls.</p>   <p>     This simple example shows how you can drag rows from the     grid into arbitrary elements. You can easily extend this     to support move operations (by removing the row from the     source grid when the operation is completed) or dropping     into grids (by detecting the drop position and inserting     new rows into the target grid).</p>   <p>     Drag r...

142857 (number)

1 × 142,857 = 142,857 2 × 142,857 = 285,714 3 × 142,857 = 428,571 4 × 142,857 = 571,428 5 × 142,857 = 714,285 6 × 142,857 = 857,142 7 × 142,857 = 999,999 (= 142857 + 857142) 9/7      =1.2857142857142857142857142857143 99/7    =14.142857142857142857142857142857 999/7  =142.71428571428571428571428571429 9999/7=1428.4285714285714285714285714286 Ref: https://en.wikipedia.org/wiki/142857_(number) 123456789*9  =1111111101 123456789*18=2222222202 123456789*243=29999999727 123456789*108=13333333212 柯斯特利金的优秀教材《 代数学引论 》 Alexei I Kostrikin (1929~2000). 1929年2月生于大莫雷斯。1952年毕业于莫斯科大学 数学 力学系,1959年获数理科学博士学位。1972年任莫斯科大学高等 代数 《 拓扑与几何 》  是2008年1月1日出版 作者是(美国) Bredon 布里 登    

CSV & javascript

<a href="data:application/csv;charset=utf-8,test,tes,1,encodeURIComponent()" download="test.csv" target="_blank"> CSV</a> Reference: http://wijmo.com/topic/wijgrid-in-csv/ <!DOCTYPE html> < html xmlns =" http://www.w3.org/1999/xhtml "> < head > < title ></ title > <!--jQuery References--> < script src =" http://code.jquery.com/jquery-1.9.1.min.js " type =" text/javascript "></ script > < script src =" http://code.jquery.com/ui/1.10.1/jquery-ui.min.js " type =" text/javascript "></ script > <!--Theme--> < link href =" http://cdn.wijmo.com/themes/aristo/jquery-wijmo.css " rel =" stylesheet " type =" text/css " /> <!--Wijmo Widgets CSS--> < link href =" http://cdn.wijmo.com/jquery.wijmo-pro.all.3.20132.9.min.css " rel =" styles...