10
10
<!--[if IE]><meta http-equiv='X-UA-Compatible' content='IE=edge,chrome=1'><![endif]-->
11
11
< title > Glayzzle - The union between PHP and NodeJS</ title >
12
12
< meta name ="viewport " content ="width=device-width, initial-scale=1.0 ">
13
- < meta name ="description " content ="Run PHP with nodejs ">
13
+ < meta name ="description " content ="Parse PHP and extract AST with javascript ">
14
14
< meta name ="author " content ="Ioan CHIRIAC ">
15
15
16
16
<!--stylesheets-->
79
79
< div class ="nav-collapse ">
80
80
< ul class ="nav ">
81
81
< li class ="current "> < a href ="#demo "> Demo</ a > </ li >
82
- < li > < a href ="https://github.com/glayzzle/php-parser/wiki "> Documentation</ a > </ li >
82
+ < li > < a href ="https://github.com/glayzzle/php-parser/tree/master/docs "> Documentation</ a > </ li >
83
83
< li > < a href ="https://github.com/glayzzle/php-parser/issues "> Issues</ a > </ li >
84
84
< li > < a href ="/index.html#support "> Contact</ a > </ li >
85
85
< li >
107
107
< a href ="https://gitter.im/glayzzle/Lobby "> < img src ="https://camo.githubusercontent.com/9e4e89c5b3434b12e74867c52ce897fc1380abcc/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4749545445522d6a6f696e253230636861742d677265656e2e737667 " alt ="Gitter " data-canonical-src ="https://img.shields.io/badge/GITTER-join%20chat-green.svg "> </ a >
108
108
</ p >
109
109
< p >
110
- Parse PHP code from NodeJS and convert it to AST.
111
- This library is a standalone module of a larger
112
- project named < a href ="http://glayzzle.com/ "> Glayzzle</ a > .
110
+ Parse PHP code with javascript and convert it to AST.
113
111
</ p >
114
112
</ div >
115
113
</ div >
@@ -167,13 +165,13 @@ <h1>Try it online</h1>
167
165
</ div >
168
166
< p id ="options ">
169
167
< label >
170
- < input type ="checkbox " data-opt ="locations "> Include positions
168
+ < input type ="checkbox " data-key =" ast " data- opt ="withPositions "> Include positions
171
169
</ label >
172
170
< label >
173
- < input type ="checkbox " data-opt ="extractDoc "> Extract comments
171
+ < input type ="checkbox " data-key =" parser " data- opt ="extractDoc "> Extract comments
174
172
</ label >
175
173
< label >
176
- < input type ="checkbox " data-opt ="suppressErrors "> Graceful errors
174
+ < input type ="checkbox " data-key =" parser " data- opt ="suppressErrors "> Graceful errors
177
175
</ label >
178
176
</ p >
179
177
< div id ="jsoneditor " style ="width: 100%; height: 400px; "> </ div >
@@ -196,7 +194,7 @@ <h1>Try it online</h1>
196
194
< script type ="text/javascript " src ="/js/main.js?v=1 "> </ script >
197
195
< script type ="text/javascript " src ="https://cdnjs.cloudflare.com/ajax/libs/gist-embed/2.4/gist-embed.min.js "> </ script >
198
196
< script type ="text/javascript " src ="https://cdnjs.cloudflare.com/ajax/libs/ace/1.2.6/ace.js "> </ script >
199
- < script type ="text/javascript " src ="https://rawgit.com/glayzzle/php-parser/master /dist/php-parser.min.js "> </ script >
197
+ < script type ="text/javascript " src ="https://rawgit.com/glayzzle/php-parser/develop /dist/php-parser.min.js "> </ script >
200
198
< script type ="text/javascript " src ="https://cdn.rawgit.com/josdejong/jsoneditor/master/dist/jsoneditor-minimalist.min.js "> </ script >
201
199
< script >
202
200
var parser = require ( 'php-parser' ) ;
@@ -225,7 +223,7 @@ <h1>Try it online</h1>
225
223
editor . on ( "change" , refreshAst ) ;
226
224
refreshAst ( ) ;
227
225
$ ( '[data-opt]' ) . on ( 'click' , function ( ) {
228
- options . parser [ $ ( this ) . attr ( 'data-opt' ) ] = $ ( this ) . is ( ':checked' ) ;
226
+ options . [ $ ( this ) . attr ( 'data-key' ) ] [ $ ( this ) . attr ( 'data-opt' ) ] = $ ( this ) . is ( ':checked' ) ;
229
227
refreshAst ( ) ;
230
228
} ) ;
231
229
</ script >
0 commit comments