diff --git a/.htaccess b/.htaccess new file mode 100644 index 0000000..cfdc9c4 --- /dev/null +++ b/.htaccess @@ -0,0 +1,9 @@ +options -multiviews +options -indexes + + + RewriteEngine on + RewriteRule ^includes/.+\.(json|php)$ 404 + RewriteRule ^generate/([a-z0-9\-]{1,100})$ generate.php?slug=$1&%{QUERY_STRING} + RewriteRule ^generate/([a-z0-9\-]{1,100})/ajax$ ajax.php?slug=$1&%{QUERY_STRING} + \ No newline at end of file diff --git a/ajax.php b/ajax.php new file mode 100644 index 0000000..be2c18f --- /dev/null +++ b/ajax.php @@ -0,0 +1,10 @@ + \ No newline at end of file diff --git a/assets/css/styles.css b/assets/css/styles.css new file mode 100644 index 0000000..cc676e7 --- /dev/null +++ b/assets/css/styles.css @@ -0,0 +1,456 @@ +/* keyframe styles */ +@keyframes hero-scroll { + 0% { + background-position: 50% 0; + } + + 100% { + background-position: 50% 750px; + } +} + +@-webkit-keyframes hero-scroll { + 0% { + background-position: 50% 0; + } + + 100% { + background-position: 50% 750px; + } +} + +/* default styles */ +*, +*:before, +*:after { + position: relative; + font: inherit; + line-height: inherit; + color: inherit; + padding: 0; + margin: 0; + box-sizing: border-box; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; +} + +*:focus { + outline: 0; +} + +html, +body, +div, +h1, +h2, +p { + display: block; +} + +a, +b, +span, +input, +button, +textarea { + display: inline-block; +} + +html, +body { + height: 100%; +} + +body { + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-size: 16px; + line-height: 26px; + color: #333333; + word-break: break-word; + background: #f5f5f5; +} + +div { + width: initial; + overflow: hidden; +} + +h1, +h2 { + font-weight: bold; + text-transform: capitalize; +} + +h1 { + font-size: 42px; + line-height: 52px; +} + +h2 { + font-size: 30px; + line-height: 40px; +} + +p:first-letter { + text-transform: uppercase; +} + +a { + text-decoration: none; +} + +a:hover { + text-decoration: underline; +} + +b, +button { + font-weight: bold; +} + +input, +button, +textarea { + width: 100%; + padding: 10px; + border: none; + border-radius: 4px; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; +} + +input, +textarea { + background: #eeeeee; + border: 1px solid #dddddd; +} + +input:focus, +textarea:focus { + background: #e8e8e8; +} + +button { + text-transform: capitalize; + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; + cursor: pointer; +} + +/* reusable classes */ +.row { + padding: 0; + margin: -1%; +} + +.row, +.row:after { + clear: both; + zoom: 1; +} + +.row:before, +.row:after { + content: ""; + display: table; +} + +.row>div { + float: left; + padding: 1%; +} + +.row>.col1 { + width: 8.33%; +} + +.row>.col2 { + width: 16.66666%; +} + +.row>.col3 { + width: 24.99%; +} + +.row>.col4 { + width: 33.33%; +} + +.row>.col5 { + width: 33.33%; +} + +.row>.col6 { + width: 50%; +} + +.row>.col7 { + width: 58.333%; +} + +.row>.col8 { + width: 66.66666664%; +} + +.row>.col9 { + width: 74.999997%; +} + +.row>.col10 { + width: 83.33%; +} + +.row>.col11 { + width: 91.666663%; +} + +.row>.col12 { + width: 100%; +} + +.green-btn, +.blue-btn { + color: #ffffff; +} + +.green-btn { + background: #43a047; +} + +.green-btn:hover { + background: #4caf50; +} + +.blue-btn { + background: #039be5; +} + +.blue-btn:hover { + background: #03a9f4; +} + +.container { + width: 80%; + max-width: 1200px; + margin: 0 auto; +} + +/* header & hero background styles */ +#header, +#hero { + background: #111111; +} + +#header:before, +#hero:before, +#hero:after { + content: ""; + display: block; + position: absolute; +} + +#header:before, +#hero:before { + top: 0; + left: 0; + width: 100%; + height: 100%; + opacity: 0.25; + background-image: url("../img/hero.png"); + background-repeat: repeat; + background-position: top left; + background-attachment: fixed; + animation: hero-scroll 30s linear 0s infinite normal; + -webkit-animation: hero-scroll 30s linear 0s infinite normal; + -moz-animation: hero-scroll 30s linear 0s infinite normal; +} + +#hero:after { + bottom: 0; + left: 0; + width: 100%; + height: 80px; + background-image: url("../img/hero.svg"); + background-position: bottom left; + background-size: 100% 100%; +} + +/* header styles */ +#header { + padding: 20px 0; +} + +/* hero styles */ +#hero { + padding: 100px 0 180px 0; +} + +#hero>div>div>* { + color: #ffffff; + text-align: center; +} + +#hero>div>div>p { + margin: 10px 0 0 0; + font-size: 20px; + line-height: 30px; + opacity: 0.4; +} + +/* main styles */ +#main>div { + padding: 60px 0; + border-bottom: 1px solid #dddddd; +} + +#main>div:last-of-type { + border: none; +} + +/* statistics styles */ +#main>#statistics>div>div>* { + text-align: center; +} + +#main>#statistics>div>div>span { + display: block; + text-transform: capitalize; + font-weight: bold; + font-size: 24px; + line-height: 34px; +} + +#main>#statistics>div>div>p { + margin: 10px 0 0 0; + font-size: 18px; + line-height: 28px; +} + +#main>#statistics>div>div>span>b { + color: #43a047; +} + +/* character set styles */ +#main>#character-sets>div>div>a { + display: block; + padding: 20px 10px; + text-decoration: none; + background: #eeeeee; + border: 1px solid #dddddd; + border-radius: 4px; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; +} + +#main>#character-sets>div>div>a>span { + display: block; + text-transform: capitalize; + font-weight: bold; + font-size: 20px; + line-height: 30px; +} + +#main>#character-sets>div>div>a>p { + margin: 10px 0 0 0; +} + +#main>#character-sets>div>div>a:hover>span { + color: #43a047; +} + +#main>#character-sets>div>div>a>* { + text-align: center; + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; +} + +/* generation form styles */ +#main>#generation-form>div>div>textarea { + min-width: 100%; + max-width: 100%; + min-height: 240px; + max-height: 240px; +} + +/* footer styles */ +#footer { + background: #111111; +} + +#footer>div:nth-of-type(1) { + padding: 60px 0; +} + +#footer>div:nth-of-type(2) { + padding: 20px 0; + background: rgba(0, 0, 0, 0.2); +} + +#footer>div:nth-of-type(1)>div>div>span, +#footer>div:nth-of-type(1)>div>div>div>*, +#footer>div:nth-of-type(2)>div>div>p { + color: #ffffff; + text-transform: capitalize; +} + +#footer>div:nth-of-type(1)>div>div>div>*, +#footer>div:nth-of-type(2)>div>div>p { + opacity: 0.4; +} + +#footer>div:nth-of-type(1)>div>div>span { + font-weight: bold; + font-size: 20px; + line-height: 30px; +} + +#footer>div:nth-of-type(1)>div>div>div>* { + display: block; + float: left; + clear: left; + margin: 10px 0; +} + +#footer>div:nth-of-type(1)>div>div>div>*:first-child { + margin-top: 20px; +} + +#footer>div:nth-of-type(1)>div>div>div>*:last-child { + margin-bottom: 0; +} + +/* responsive styles */ +@media (max-width: 800px) { + #footer>div:nth-of-type(2) { + display: none; + } + + #header>div>div, + #statistics>div>div, + #character-sets>div>div, + #generation-form>div>div, + #footer>div:first-of-type>div>div { + width: 100%; + } + + #header>div>div:first-of-type, + #main>#character-sets>div>div.col12, + #footer>div:first-of-type { + text-align: center; + } + + #statistics>div>div, + #footer>div:first-of-type, + #footer>div:first-of-type>div>div { + margin: 30px 0; + } + + #footer>div:first-of-type>div>div>div>* { + float: none; + clear: none; + } +} + +/*# sourceMappingURL=styles.css.map */ \ No newline at end of file diff --git a/assets/css/styles.css.map b/assets/css/styles.css.map new file mode 100644 index 0000000..759c510 --- /dev/null +++ b/assets/css/styles.css.map @@ -0,0 +1 @@ +{"version":3,"sources":["styles.scss","styles.css"],"names":[],"mappings":"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","file":"styles.css"} \ No newline at end of file diff --git a/assets/css/styles.min.css b/assets/css/styles.min.css new file mode 100644 index 0000000..e6a6624 --- /dev/null +++ b/assets/css/styles.min.css @@ -0,0 +1 @@ +@keyframes hero-scroll{0%{background-position:50% 0}100%{background-position:50% 750px}}@-webkit-keyframes hero-scroll{0%{background-position:50% 0}100%{background-position:50% 750px}}*,:after,:before{position:relative;font:inherit;line-height:inherit;color:inherit;padding:0;margin:0;box-sizing:border-box;-webkit-box-sizing:border-box;-moz-box-sizing:border-box}:focus{outline:0}body,div,h1,h2,html,p{display:block}a,b,button,input,span,textarea{display:inline-block}body,html{height:100%}body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:16px;line-height:26px;color:#333;word-break:break-word;background:#f5f5f5}div{width:initial;overflow:hidden}h1,h2{font-weight:700;text-transform:capitalize}h1{font-size:42px;line-height:52px}h2{font-size:30px;line-height:40px}p:first-letter{text-transform:uppercase}a{text-decoration:none}a:hover{text-decoration:underline}b,button{font-weight:700}button,input,textarea{width:100%;padding:10px;border:none;border-radius:4px;-webkit-border-radius:4px;-moz-border-radius:4px}input,textarea{background:#eee;border:1px solid #ddd}input:focus,textarea:focus{background:#e8e8e8}button{text-transform:capitalize;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;cursor:pointer}.row{padding:0;margin:-1%}.row,.row:after{clear:both;zoom:1}.row:after,.row:before{content:"";display:table}.row>div{float:left;padding:1%}.row>.col1{width:8.33%}.row>.col2{width:16.66666%}.row>.col3{width:24.99%}.row>.col4{width:33.33%}.row>.col5{width:33.33%}.row>.col6{width:50%}.row>.col7{width:58.333%}.row>.col8{width:66.66666664%}.row>.col9{width:74.999997%}.row>.col10{width:83.33%}.row>.col11{width:91.666663%}.row>.col12{width:100%}.blue-btn,.green-btn{color:#fff}.green-btn{background:#43a047}.green-btn:hover{background:#4caf50}.blue-btn{background:#039be5}.blue-btn:hover{background:#03a9f4}.container{width:80%;max-width:1200px;margin:0 auto}#header,#hero{background:#111}#header:before,#hero:after,#hero:before{content:"";display:block;position:absolute}#header:before,#hero:before{top:0;left:0;width:100%;height:100%;opacity:.25;background-image:url(../img/hero.png);background-repeat:repeat;background-position:top left;background-attachment:fixed;animation:hero-scroll 30s linear 0s infinite normal;-webkit-animation:hero-scroll 30s linear 0s infinite normal;-moz-animation:hero-scroll 30s linear 0s infinite normal}#hero:after{bottom:0;left:0;width:100%;height:80px;background-image:url(../img/hero.svg);background-position:bottom left;background-size:100% 100%}#header{padding:20px 0}#hero{padding:100px 0 180px 0}#hero>div>div>*{color:#fff;text-align:center}#hero>div>div>p{margin:10px 0 0 0;font-size:20px;line-height:30px;opacity:.4}#main>div{padding:60px 0;border-bottom:1px solid #ddd}#main>div:last-of-type{border:none}#main>#statistics>div>div>*{text-align:center}#main>#statistics>div>div>span{display:block;text-transform:capitalize;font-weight:700;font-size:24px;line-height:34px}#main>#statistics>div>div>p{margin:10px 0 0 0;font-size:18px;line-height:28px}#main>#statistics>div>div>span>b{color:#43a047}#main>#character-sets>div>div>a{display:block;padding:20px 10px;text-decoration:none;background:#eee;border:1px solid #ddd;border-radius:4px;-webkit-border-radius:4px;-moz-border-radius:4px}#main>#character-sets>div>div>a>span{display:block;text-transform:capitalize;font-weight:700;font-size:20px;line-height:30px}#main>#character-sets>div>div>a>p{margin:10px 0 0 0}#main>#character-sets>div>div>a:hover>span{color:#43a047}#main>#character-sets>div>div>a>*{text-align:center;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}#main>#generation-form>div>div>textarea{min-width:100%;max-width:100%;min-height:240px;max-height:240px}#footer{background:#111}#footer>div:nth-of-type(1){padding:60px 0}#footer>div:nth-of-type(2){padding:20px 0;background:rgba(0,0,0,.2)}#footer>div:nth-of-type(1)>div>div>div>*,#footer>div:nth-of-type(1)>div>div>span,#footer>div:nth-of-type(2)>div>div>p{color:#fff;text-transform:capitalize}#footer>div:nth-of-type(1)>div>div>div>*,#footer>div:nth-of-type(2)>div>div>p{opacity:.4}#footer>div:nth-of-type(1)>div>div>span{font-weight:700;font-size:20px;line-height:30px}#footer>div:nth-of-type(1)>div>div>div>*{display:block;float:left;clear:left;margin:10px 0}#footer>div:nth-of-type(1)>div>div>div>:first-child{margin-top:20px}#footer>div:nth-of-type(1)>div>div>div>:last-child{margin-bottom:0}@media (max-width:800px){#footer>div:nth-of-type(2){display:none}#character-sets>div>div,#footer>div:first-of-type>div>div,#generation-form>div>div,#header>div>div,#statistics>div>div{width:100%}#footer>div:first-of-type,#header>div>div:first-of-type,#main>#character-sets>div>div.col12{text-align:center}#footer>div:first-of-type,#footer>div:first-of-type>div>div,#statistics>div>div{margin:30px 0}#footer>div:first-of-type>div>div>div>*{float:none;clear:none}} \ No newline at end of file diff --git a/assets/css/styles.scss b/assets/css/styles.scss new file mode 100644 index 0000000..c2b272a --- /dev/null +++ b/assets/css/styles.scss @@ -0,0 +1,457 @@ +/* keyframe styles */ +@keyframes hero-scroll { + 0% { + background-position: 50% 0; + } + 100% { + background-position: 50% 750px; + } +} + +@-webkit-keyframes hero-scroll { + 0% { + background-position: 50% 0; + } + 100% { + background-position: 50% 750px; + } +} + +@-moz-keyframes hero-scroll { + 0% { + background-position: 50% 0; + } + 100% { + background-position: 50% 750px; + } +} + +/* default styles */ +*, +*:before, +*:after { + position: relative; + font: inherit; + line-height: inherit; + color: inherit; + padding: 0; + margin: 0; + box-sizing: border-box; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; +} + +*:focus { + outline: 0; +} + +html, +body, +div, +h1, +h2, +p { + display: block; +} + +a, +b, +span, +input, +button, +textarea { + display: inline-block; +} + +html, +body { + height: 100%; +} + +body { + font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; + font-size: 16px; + line-height: 26px; + color: #333333; + word-break: break-word; + background: #f5f5f5; +} + +div { + width: initial; + overflow: hidden; +} + +h1, +h2 { + font-weight: bold; + text-transform: capitalize; +} + +h1 { + font-size: 42px; + line-height: 52px; +} + +h2 { + font-size: 30px; + line-height: 40px; +} + +p:first-letter { + text-transform: uppercase; +} + +a { + text-decoration: none; +} + +a:hover { + text-decoration: underline; +} + +b, +button { + font-weight: bold; +} + +input, +button, +textarea { + width: 100%; + padding: 10px; + border: none; + border-radius: 4px; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; +} + +input, +textarea { + background: #eeeeee; + border: 1px solid #dddddd; +} + +input:focus, +textarea:focus { + background: #e8e8e8; +} + +button { + text-transform: capitalize; + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; + cursor: pointer; +} + +/* reusable classes */ +.row { + padding: 0; + margin: -1%; +} + +.row, +.row:after { + clear: both; + zoom: 1; +} + +.row:before, +.row:after { + content: ''; + display: table; +} + +.row > div { + float: left; + padding: 1%; +} + +.row > .col1 { + width: 8.33%; +} + +.row > .col2 { + width: 16.66666%; +} + +.row > .col3 { + width: 24.99%; +} + +.row > .col4 { + width: 33.33%; +} + +.row > .col5 { + width: 33.33%; +} + +.row > .col6 { + width: 50%; +} + +.row > .col7 { + width: 58.333%; +} + +.row > .col8 { + width: 66.66666664%; +} + +.row > .col9 { + width: 74.999997%; +} + +.row > .col10 { + width: 83.33%; +} + +.row > .col11 { + width: 91.666663%; +} + +.row > .col12 { + width: 100%; +} + +.green-btn, +.blue-btn { + color: #ffffff; +} + +.green-btn { + background: #43a047; +} + +.green-btn:hover { + background: #4caf50; +} + +.blue-btn { + background: #039be5; +} + +.blue-btn:hover { + background: #03a9f4; +} + +.container { + width: 80%; + max-width: 1200px; + margin: 0 auto; +} + +/* header & hero background styles */ +#header, +#hero { + background: #111111; +} + +#header:before, +#hero:before, +#hero:after { + content: ''; + display: block; + position: absolute; +} + +#header:before, +#hero:before { + top: 0; + left: 0; + width: 100%; + height: 100%; + opacity: 0.25; + background-image: url('../img/hero.png'); + background-repeat: repeat; + background-position: top left; + background-attachment: fixed; + animation: hero-scroll 30s linear 0s infinite normal; + -webkit-animation: hero-scroll 30s linear 0s infinite normal; + -moz-animation: hero-scroll 30s linear 0s infinite normal; +} + +#hero:after { + bottom: 0; + left: 0; + width: 100%; + height: 80px; + background-image: url('../img/hero.svg'); + background-position: bottom left; + background-size: 100% 100%; +} + +/* header styles */ +#header { + padding: 20px 0; +} + +/* hero styles */ +#hero { + padding: 100px 0 180px 0; +} + +#hero > div > div > * { + color: #ffffff; + text-align: center; +} + +#hero > div > div > p { + margin: 10px 0 0 0; + font-size: 20px; + line-height: 30px; + opacity: 0.4; +} + +/* main styles */ +#main > div { + padding: 60px 0; + border-bottom: 1px solid #dddddd; +} + +#main > div:last-of-type { + border: none; +} + +/* statistics styles */ +#main > #statistics > div > div > * { + text-align: center; +} + +#main > #statistics > div > div > span { + display: block; + text-transform: capitalize; + font-weight: bold; + font-size: 24px; + line-height: 34px; +} + +#main > #statistics > div > div > p { + margin: 10px 0 0 0; + font-size: 18px; + line-height: 28px; +} + +#main > #statistics > div > div > span > b { + color: #43a047; +} + +/* character set styles */ +#main > #character-sets > div > div > a { + display: block; + padding: 20px 10px; + text-decoration: none; + background: #eeeeee; + border: 1px solid #dddddd; + border-radius: 4px; + -webkit-border-radius: 4px; + -moz-border-radius: 4px; +} + +#main > #character-sets > div > div > a > span { + display: block; + text-transform: capitalize; + font-weight: bold; + font-size: 20px; + line-height: 30px; +} + +#main > #character-sets > div > div > a > p { + margin: 10px 0 0 0; +} + +#main > #character-sets > div > div > a:hover > span { + color: #43a047; +} + +#main > #character-sets > div > div > a > * { + text-align: center; + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; +} + +/* generation form styles */ +#main > #generation-form > div > div > textarea { + min-width: 100%; + max-width: 100%; + min-height: 240px; + max-height: 240px; +} + +/* footer styles */ +#footer { + background: #111111; +} + +#footer > div:nth-of-type(1) { + padding: 60px 0; +} + +#footer > div:nth-of-type(2) { + padding: 20px 0; + background: rgba(0, 0, 0, 0.2); +} + +#footer > div:nth-of-type(1) > div > div > span, +#footer > div:nth-of-type(1) > div > div > div > *, +#footer > div:nth-of-type(2) > div > div > p { + color: #ffffff; + text-transform: capitalize; +} + +#footer > div:nth-of-type(1) > div > div > div > *, +#footer > div:nth-of-type(2) > div > div > p { + opacity: 0.4; +} + +#footer > div:nth-of-type(1) > div > div > span { + font-weight: bold; + font-size: 20px; + line-height: 30px; +} + +#footer > div:nth-of-type(1) > div > div > div > * { + display: block; + float: left; + clear: left; + margin: 10px 0; +} + +#footer > div:nth-of-type(1) > div > div > div > *:first-child { + margin-top: 20px; +} + +#footer > div:nth-of-type(1) > div > div > div > *:last-child { + margin-bottom: 0; +} + +/* responsive styles */ +@media (max-width: 800px) { + #footer > div:nth-of-type(2) { + display: none; + } + #header > div > div, + #statistics > div > div, + #character-sets > div > div, + #generation-form > div > div, + #footer > div:first-of-type > div > div { + width: 100%; + } + #header > div > div:first-of-type, + #main > #character-sets > div > div.col12, + #footer > div:first-of-type { + text-align: center; + } + #statistics > div > div, + #footer > div:first-of-type, + #footer > div:first-of-type > div > div { + margin: 30px 0; + } + #footer > div:first-of-type > div > div > div > * { + float: none; + clear: none; + } +} diff --git a/assets/img/hero.png b/assets/img/hero.png new file mode 100644 index 0000000..11fb9c5 Binary files /dev/null and b/assets/img/hero.png differ diff --git a/assets/img/hero.svg b/assets/img/hero.svg new file mode 100644 index 0000000..73f1958 --- /dev/null +++ b/assets/img/hero.svg @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/assets/img/logo.png b/assets/img/logo.png new file mode 100644 index 0000000..df300f1 Binary files /dev/null and b/assets/img/logo.png differ diff --git a/assets/js/javascript.js b/assets/js/javascript.js new file mode 100644 index 0000000..84bfa15 --- /dev/null +++ b/assets/js/javascript.js @@ -0,0 +1,77 @@ +(function () { + /* + REUSABLE FUNCTIONS. + */ + var numberFormat = function (number) { + number = String(number); + return number.replace(/\B(?=(\d{3})+(?!\d))/g, ','); + }; + + var animateNumber = function (element) { + var self = this; + self.element = element; + self.number = self.element.getAttribute('data-number'); + self.duration = self.element.getAttribute('data-duration'); + self.updateRate = 1000 / 60; + self.totalUpdates = Math.ceil(self.duration / self.updateRate); + self.updates = 0; + self.update = function () { + self.element.innerText = numberFormat(Math.round((self.number / self.totalUpdates) * self.updates)); + if (self.updates < self.totalUpdates) { + ++self.updates; + setTimeout(self.update, self.updateRate); + } + }; + self.update(); + }; + + var httpRequest = function (method, url, headers, post, callback) { + var request = new XMLHttpRequest(); + request.onreadystatechange = function () { + this.readyState == 4 && callback(this.responseText); + }; + request.open(method, url, true); + for (var i = 0; i < headers.length; i += 2) { + request.setRequestHeader(headers[i], headers[i + 1]); + } + request.send(post); + }; + + var postRequest = function (url, post, callback) { + httpRequest( + 'POST', + url, + ['X-Requested-With', 'XMLHttpRequest', 'Content-Type', 'application/x-www-form-urlencoded; charset=UTF-8'], + post, + callback + ); + }; + + /* + MAIN FUNCTIONS. + */ + var generateText = function (input, output) { + postRequest(window.location.href + '/ajax', 'text=' + input.value, function (data) { + output.value = data; + }); + }; + + var clearText = function (input, output) { + input.value = output.value = ''; + }; + + window.setGeneratorEvents = function (generateId, clearId, inputId, outputId) { + document.getElementById(generateId).onclick = function () { + generateText(document.getElementById(inputId), document.getElementById(outputId)); + }; + document.getElementById(clearId).onclick = function () { + clearText(document.getElementById(inputId), document.getElementById(outputId)); + }; + }; + + window.animateNumbers = function (className) { + for (var elements = document.getElementsByClassName(className), i = 0; i < elements.length; i++) { + new animateNumber(elements[i]); + } + }; +})(); diff --git a/assets/js/javascript.min.js b/assets/js/javascript.min.js new file mode 100644 index 0000000..1561193 --- /dev/null +++ b/assets/js/javascript.min.js @@ -0,0 +1 @@ +!function(){var numberFormat=function(number){return(number=String(number)).replace(/\B(?=(\d{3})+(?!\d))/g,",")},animateNumber=function(element){var self=this;self.element=element,self.number=self.element.getAttribute("data-number"),self.duration=self.element.getAttribute("data-duration"),self.updateRate=1e3/60,self.totalUpdates=Math.ceil(self.duration/self.updateRate),self.updates=0,self.update=function(){self.element.innerText=numberFormat(Math.round(self.number/self.totalUpdates*self.updates)),self.updates + + + + + + + + <?php echo $website['name'];?> - <?php echo $set['name'];?> + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/includes/config.php b/includes/config.php new file mode 100644 index 0000000..0814c44 --- /dev/null +++ b/includes/config.php @@ -0,0 +1,22 @@ + \ No newline at end of file diff --git a/includes/html/footer.php b/includes/html/footer.php new file mode 100644 index 0000000..3b394b3 --- /dev/null +++ b/includes/html/footer.php @@ -0,0 +1,37 @@ + + \ No newline at end of file diff --git a/includes/html/header.php b/includes/html/header.php new file mode 100644 index 0000000..fb3b638 --- /dev/null +++ b/includes/html/header.php @@ -0,0 +1,12 @@ + + \ No newline at end of file diff --git a/includes/html/hero.php b/includes/html/hero.php new file mode 100644 index 0000000..fa81acf --- /dev/null +++ b/includes/html/hero.php @@ -0,0 +1,22 @@ + +
+
+ + + +
+

text generator

+

convert your text into text using our text generator!

+
+ + + +
+

+

generate cool text what can be used on Youtube, Twitter, Instagram, Discord and more!

+
+ + + +
+
\ No newline at end of file diff --git a/includes/html/main.php b/includes/html/main.php new file mode 100644 index 0000000..aa48f36 --- /dev/null +++ b/includes/html/main.php @@ -0,0 +1,78 @@ + +
+ + + + +
+
+
+ +
+
+ +
+
+ +
+
+ +
+
+
+ + +
+
+
+

more text generators

+

here are some more text generators for you to try out.

+
+ + + +
+
+ + + + +
+
+
+ 0 text generators +

we have different text generators for you to choose from

+
+
+ 0 times +

our text generators have been used times and counting

+
+
+ 0 characters +

we have converted characters into cool text and counting

+
+
+
+ + + + + + +
\ No newline at end of file diff --git a/includes/json/character-sets.json b/includes/json/character-sets.json new file mode 100644 index 0000000..9e4af27 --- /dev/null +++ b/includes/json/character-sets.json @@ -0,0 +1,859 @@ +[ + { + "name": "aesthetic", + "characters": { + "0": "0", + "1": "1", + "2": "2", + "3": "3", + "4": "4", + "5": "5", + "6": "6", + "7": "7", + "8": "8", + "9": "9", + "a": "a", + "b": "b", + "c": "c", + "d": "d", + "e": "e", + "f": "f", + "g": "g", + "h": "h", + "i": "i", + "j": "j", + "k": "k", + "l": "l", + "m": "m", + "n": "n", + "o": "o", + "p": "p", + "q": "q", + "r": "r", + "s": "s", + "t": "t", + "u": "u", + "v": "v", + "w": "w", + "x": "x", + "y": "y", + "z": "z", + "A": "A", + "B": "B", + "C": "C", + "D": "D", + "E": "E", + "F": "F", + "G": "G", + "H": "H", + "I": "I", + "J": "J", + "K": "K", + "L": "L", + "M": "M", + "N": "N", + "O": "O", + "P": "P", + "Q": "Q", + "R": "R", + "S": "S", + "T": "T", + "U": "U", + "V": "V", + "W": "W", + "X": "X", + "Y": "Y", + "Z": "Z", + " ": " " + } + }, + { + "name": "bold", + "characters": { + "0": "𝟎", + "1": "𝟏", + "2": "𝟐", + "3": "𝟑", + "4": "𝟒", + "5": "𝟓", + "6": "𝟔", + "7": "𝟕", + "8": "𝟖", + "9": "𝟗", + "a": "𝐚", + "b": "𝐛", + "c": "𝐜", + "d": "𝐝", + "e": "𝐞", + "f": "𝐟", + "g": "𝐠", + "h": "𝐡", + "i": "𝐢", + "j": "𝐣", + "k": "𝐤", + "l": "𝐥", + "m": "𝐦", + "n": "𝐧", + "o": "𝐨", + "p": "𝐩", + "q": "𝐪", + "r": "𝐫", + "s": "𝐬", + "t": "𝐭", + "u": "𝐮", + "v": "𝐯", + "w": "𝐰", + "x": "𝐱", + "y": "𝐲", + "z": "𝐳", + "A": "𝐀", + "B": "𝐁", + "C": "𝐂", + "D": "𝐃", + "E": "𝐄", + "F": "𝐅", + "G": "𝐆", + "H": "𝐇", + "I": "𝐈", + "J": "𝐉", + "K": "𝐊", + "L": "𝐋", + "M": "𝐌", + "N": "𝐍", + "O": "𝐎", + "P": "𝐏", + "Q": "𝐐", + "R": "𝐑", + "S": "𝐒", + "T": "𝐓", + "U": "𝐔", + "V": "𝐕", + "W": "𝐖", + "X": "𝐗", + "Y": "𝐘", + "Z": "𝐙" + } + }, + { + "name": "bold italic", + "characters": { + "a": "𝙖", + "b": "𝙗", + "c": "𝙘", + "d": "𝙙", + "e": "𝙚", + "f": "𝙛", + "g": "𝙜", + "h": "𝙝", + "i": "𝙞", + "j": "𝙟", + "k": "𝙠", + "l": "𝙡", + "m": "𝙢", + "n": "𝙣", + "o": "𝙤", + "p": "𝙥", + "q": "𝙦", + "r": "𝙧", + "s": "𝙨", + "t": "𝙩", + "u": "𝙪", + "v": "𝙫", + "w": "𝙬", + "x": "𝙭", + "y": "𝙮", + "z": "𝙯", + "A": "𝘼", + "B": "𝘽", + "C": "𝘾", + "D": "𝘿", + "E": "𝙀", + "F": "𝙁", + "G": "𝙂", + "H": "𝙃", + "I": "𝙄", + "J": "𝙅", + "K": "𝙆", + "L": "𝙇", + "M": "𝙈", + "N": "𝙉", + "O": "𝙊", + "P": "𝙋", + "Q": "𝙌", + "R": "𝙍", + "S": "𝙎", + "T": "𝙏", + "U": "𝙐", + "V": "𝙑", + "W": "𝙒", + "X": "𝙓", + "Y": "𝙔", + "Z": "𝙕" + } + }, + { + "name": "bold script", + "characters": { + "a": "𝓪", + "b": "𝓫", + "c": "𝓬", + "d": "𝓭", + "e": "𝓮", + "f": "𝓯", + "g": "𝓰", + "h": "𝓱", + "i": "𝓲", + "j": "𝓳", + "k": "𝓴", + "l": "𝓵", + "m": "𝓶", + "n": "𝓷", + "o": "𝓸", + "p": "𝓹", + "q": "𝓺", + "r": "𝓻", + "s": "𝓼", + "t": "𝓽", + "u": "𝓾", + "v": "𝓿", + "w": "𝔀", + "x": "𝔁", + "y": "𝔂", + "z": "𝔃", + "A": "𝓐", + "B": "𝓑", + "C": "𝓒", + "D": "𝓓", + "E": "𝓔", + "F": "𝓕", + "G": "𝓖", + "H": "𝓗", + "I": "𝓘", + "J": "𝓙", + "K": "𝓚", + "L": "𝓛", + "M": "𝓜", + "N": "𝓝", + "O": "𝓞", + "P": "𝓟", + "Q": "𝓠", + "R": "𝓡", + "S": "𝓢", + "T": "𝓣", + "U": "𝓤", + "V": "𝓥", + "W": "𝓦", + "X": "𝓧", + "Y": "𝓨", + "Z": "𝓩" + } + }, + { + "name": "bubble", + "characters": { + "0": "⓪", + "1": "①", + "2": "②", + "3": "③", + "4": "④", + "5": "⑤", + "6": "⑥", + "7": "⑦", + "8": "⑧", + "9": "⑨", + "a": "ⓐ", + "b": "ⓑ", + "c": "ⓒ", + "d": "ⓓ", + "e": "ⓔ", + "f": "ⓕ", + "g": "ⓖ", + "h": "ⓗ", + "i": "ⓘ", + "j": "ⓙ", + "k": "ⓚ", + "l": "ⓛ", + "m": "ⓜ", + "n": "ⓝ", + "o": "ⓞ", + "p": "ⓟ", + "q": "ⓠ", + "r": "ⓡ", + "s": "ⓢ", + "t": "ⓣ", + "u": "ⓤ", + "v": "ⓥ", + "w": "ⓦ", + "x": "ⓧ", + "y": "ⓨ", + "z": "ⓩ", + "A": "Ⓐ", + "B": "Ⓑ", + "C": "Ⓒ", + "D": "Ⓓ", + "E": "Ⓔ", + "F": "Ⓕ", + "G": "Ⓖ", + "H": "Ⓗ", + "I": "Ⓘ", + "J": "Ⓙ", + "K": "Ⓚ", + "L": "Ⓛ", + "M": "Ⓜ", + "N": "Ⓝ", + "O": "Ⓞ", + "P": "Ⓟ", + "Q": "Ⓠ", + "R": "Ⓡ", + "S": "Ⓢ", + "T": "Ⓣ", + "U": "Ⓤ", + "V": "Ⓥ", + "W": "Ⓦ", + "X": "Ⓧ", + "Y": "Ⓨ", + "Z": "Ⓩ" + } + }, + { + "name": "double struck", + "characters": { + "0": "𝟘", + "1": "𝟙", + "2": "𝟚", + "3": "𝟛", + "4": "𝟜", + "5": "𝟝", + "6": "𝟞", + "7": "𝟟", + "8": "𝟠", + "9": "𝟡", + "a": "𝕒", + "b": "𝕓", + "c": "𝕔", + "d": "𝕕", + "e": "𝕖", + "f": "𝕗", + "g": "𝕘", + "h": "𝕙", + "i": "𝕚", + "j": "𝕛", + "k": "𝕜", + "l": "𝕝", + "m": "𝕞", + "n": "𝕟", + "o": "𝕠", + "p": "𝕡", + "q": "𝕢", + "r": "𝕣", + "s": "𝕤", + "t": "𝕥", + "u": "𝕦", + "v": "𝕧", + "w": "𝕨", + "x": "𝕩", + "y": "𝕪", + "z": "𝕫", + "A": "𝔸", + "B": "𝔹", + "C": "ℂ", + "D": "𝔻", + "E": "𝔼", + "F": "𝔽", + "G": "𝔾", + "H": "ℍ", + "I": "𝕀", + "J": "𝕁", + "K": "𝕂", + "L": "𝕃", + "M": "𝕄", + "N": "ℕ", + "O": "𝕆", + "P": "ℙ", + "Q": "ℚ", + "R": "ℝ", + "S": "𝕊", + "T": "𝕋", + "U": "𝕌", + "V": "𝕍", + "W": "𝕎", + "X": "𝕏", + "Y": "𝕐", + "Z": "ℤ" + } + }, + { + "name": "emoji", + "characters": { + "a": "🅰", + "b": "🅱", + "c": "🌜", + "d": "🌛", + "e": "🎗", + "f": "🎏", + "g": "🌀", + "h": "♓", + "i": "🎐", + "j": "🎷", + "k": "🎋", + "l": "👢", + "m": "〽️", + "n": "🎵", + "o": "⚽", + "p": "🅿️", + "q": "🍳", + "r": "🌱", + "s": "💲", + "t": "🌴", + "u": "⛎", + "v": "✅", + "w": "🔱", + "x": "❎", + "y": "🍸", + "z": "💤" + } + }, + { + "name": "italic", + "characters": { + "a": "𝘢", + "b": "𝘣", + "c": "𝘤", + "d": "𝘥", + "e": "𝘦", + "f": "𝘧", + "g": "𝘨", + "h": "𝘩", + "i": "𝘪", + "j": "𝘫", + "k": "𝘬", + "l": "𝘭", + "m": "𝘮", + "n": "𝘯", + "o": "𝘰", + "p": "𝘱", + "q": "𝘲", + "r": "𝘳", + "s": "𝘴", + "t": "𝘵", + "u": "𝘶", + "v": "𝘷", + "w": "𝘸", + "x": "𝘹", + "y": "𝘺", + "z": "𝘻", + "A": "𝘈", + "B": "𝘉", + "C": "𝘊", + "D": "𝘋", + "E": "𝘌", + "F": "𝘍", + "G": "𝘎", + "H": "𝘏", + "I": "𝘐", + "J": "𝘑", + "K": "𝘒", + "L": "𝘓", + "M": "𝘔", + "N": "𝘕", + "O": "𝘖", + "P": "𝘗", + "Q": "𝘘", + "R": "𝘙", + "S": "𝘚", + "T": "𝘛", + "U": "𝘜", + "V": "𝘝", + "W": "𝘞", + "X": "𝘟", + "Y": "𝘠", + "Z": "𝘡" + } + }, + { + "name": "leet speek", + "characters": { + "a": "4", + "b": "8", + "e": "3", + "g": "9", + "o": "0", + "s": "5", + "t": "7" + } + }, + { + "name": "script", + "characters": { + "a": "𝒶", + "b": "𝒷", + "c": "𝒸", + "d": "𝒹", + "e": "𝑒", + "f": "𝒻", + "g": "𝑔", + "h": "𝒽", + "i": "𝒾", + "j": "𝒿", + "k": "𝓀", + "l": "𝓁", + "m": "𝓂", + "n": "𝓃", + "o": "𝑜", + "p": "𝓅", + "q": "𝓆", + "r": "𝓇", + "s": "𝓈", + "t": "𝓉", + "u": "𝓊", + "v": "𝓋", + "w": "𝓌", + "x": "𝓍", + "y": "𝓎", + "z": "𝓏", + "A": "𝒜", + "B": "𝐵", + "C": "𝒞", + "D": "𝒟", + "E": "𝐸", + "F": "𝐹", + "G": "𝒢", + "H": "𝐻", + "I": "𝐼", + "J": "𝒥", + "K": "𝒦", + "L": "𝐿", + "M": "𝑀", + "N": "𝒩", + "O": "𝒪", + "P": "𝒫", + "Q": "𝒬", + "R": "𝑅", + "S": "𝒮", + "T": "𝒯", + "U": "𝒰", + "V": "𝒱", + "W": "𝒲", + "X": "𝒳", + "Y": "𝒴", + "Z": "𝒵" + } + }, + { + "name": "small capital", + "characters": { + "a": "ᴀ", + "b": "ʙ", + "c": "ᴄ", + "d": "ᴅ", + "e": "ᴇ", + "f": "ꜰ", + "g": "ɢ", + "h": "ʜ", + "i": "ɪ", + "j": "ᴊ", + "k": "ᴋ", + "l": "ʟ", + "m": "ᴍ", + "n": "ɴ", + "o": "ᴏ", + "p": "ᴘ", + "q": "ǫ", + "r": "ʀ", + "s": "s", + "t": "ᴛ", + "u": "ᴜ", + "v": "ᴠ", + "w": "ᴡ", + "x": "x", + "y": "ʏ", + "z": "ᴢ" + } + }, + { + "name": "square", + "characters": { + "a": "🄰", + "b": "🄱", + "c": "🄲", + "d": "🄳", + "e": "🄴", + "f": "🄵", + "g": "🄶", + "h": "🄷", + "i": "🄸", + "j": "🄹", + "k": "🄺", + "l": "🄻", + "m": "🄼", + "n": "🄽", + "o": "🄾", + "p": "🄿", + "q": "🅀", + "r": "🅁", + "s": "🅂", + "t": "🅃", + "u": "🅄", + "v": "🅅", + "w": "🅆", + "x": "🅇", + "y": "🅈", + "z": "🅉" + } + }, + { + "name": "strike", + "characters": { + "0": "0̶", + "1": "1̶", + "2": "2̶", + "3": "3̶", + "4": "4̶", + "5": "5̶", + "6": "6̶", + "7": "7̶", + "8": "8̶", + "9": "9̶", + "a": "a̶", + "b": "b̶", + "c": "c̶", + "d": "d̶", + "e": "e̶", + "f": "f̶", + "g": "g̶", + "h": "h̶", + "i": "i̶", + "j": "j̶", + "k": "k̶", + "l": "l̶", + "m": "m̶", + "n": "n̶", + "o": "o̶", + "p": "p̶", + "q": "q̶", + "r": "r̶", + "s": "s̶", + "t": "t̶", + "u": "u̶", + "v": "v̶", + "w": "w̶", + "x": "x̶", + "y": "y̶", + "z": "z̶", + "A": "A̶", + "B": "B̶", + "C": "C̶", + "D": "D̶", + "E": "E̶", + "F": "F̶", + "G": "G̶", + "H": "H̶", + "I": "I̶", + "J": "J̶", + "K": "K̶", + "L": "L̶", + "M": "M̶", + "N": "N̶", + "O": "O̶", + "P": "P̶", + "Q": "Q̶", + "R": "R̶", + "S": "S̶", + "T": "T̶", + "U": "U̶", + "V": "V̶", + "W": "W̶", + "X": "X̶", + "Y": "Y̶", + "Z": "Z̶" + } + }, + { + "name": "tilde strike", + "characters": { + "0": "0̴", + "1": "1̴", + "2": "2̴", + "3": "3̴", + "4": "4̴", + "5": "5̴", + "6": "6̴", + "7": "7̴", + "8": "8̴", + "9": "9̴", + "a": "a̴", + "b": "b̴", + "c": "c̴", + "d": "d̴", + "e": "e̴", + "f": "f̴", + "g": "g̴", + "h": "h̴", + "i": "i̴", + "j": "j̴", + "k": "k̴", + "l": "l̴", + "m": "m̴", + "n": "n̴", + "o": "o̴", + "p": "p̴", + "q": "q̴", + "r": "r̴", + "s": "s̴", + "t": "t̴", + "u": "u̴", + "v": "v̴", + "w": "w̴", + "x": "x̴", + "y": "y̴", + "z": "z̴", + "A": "A̴", + "B": "B̴", + "C": "C̴", + "D": "D̴", + "E": "E̴", + "F": "F̴", + "G": "G̴", + "H": "H̴", + "I": "I̴", + "J": "J̴", + "K": "K̴", + "L": "L̴", + "M": "M̴", + "N": "N̴", + "O": "O̴", + "P": "P̴", + "Q": "Q̴", + "R": "R̴", + "S": "S̴", + "T": "T̴", + "U": "U̴", + "V": "V̴", + "W": "W̴", + "X": "X̴", + "Y": "Y̴", + "Z": "Z̴" + } + }, + { + "name": "underline", + "characters": { + "0": "0̲", + "1": "1̲", + "2": "2̲", + "3": "3̲", + "4": "4̲", + "5": "5̲", + "6": "6̲", + "7": "7̲", + "8": "8̲", + "9": "9̲", + "a": "a̲", + "b": "b̲", + "c": "c̲", + "d": "d̲", + "e": "e̲", + "f": "f̲", + "g": "g̲", + "h": "h̲", + "i": "i̲", + "j": "j̲", + "k": "k̲", + "l": "l̲", + "m": "m̲", + "n": "n̲", + "o": "o̲", + "p": "p̲", + "q": "q̲", + "r": "r̲", + "s": "s̲", + "t": "t̲", + "u": "u̲", + "v": "v̲", + "w": "w̲", + "x": "x̲", + "y": "y̲", + "z": "z̲", + "A": "A̲", + "B": "B̲", + "C": "C̲", + "D": "D̲", + "E": "E̲", + "F": "F̲", + "G": "G̲", + "H": "H̲", + "I": "I̲", + "J": "J̲", + "K": "K̲", + "L": "L̲", + "M": "M̲", + "N": "N̲", + "O": "O̲", + "P": "P̲", + "Q": "Q̲", + "R": "R̲", + "S": "S̲", + "T": "T̲", + "U": "U̲", + "V": "V̲", + "W": "W̲", + "X": "X̲", + "Y": "Y̲", + "Z": "Z̲" + } + }, + { + "name": "upsidedown", + "characters": { + "0": "0", + "1": "Ɩ", + "2": "ᄅ", + "3": "Ɛ", + "4": "ㄣ", + "5": "ϛ", + "6": "9", + "7": "ㄥ", + "8": "8", + "9": "6", + "a": "ɐ", + "b": "q", + "c": "ɔ", + "d": "p", + "e": "ǝ", + "f": "ɟ", + "g": "ƃ", + "h": "ɥ", + "i": "ᴉ", + "j": "ɾ", + "k": "ʞ", + "m": "ɯ", + "n": "u", + "p": "d", + "q": "b", + "r": "ɹ", + "t": "ʇ", + "u": "n", + "v": "ʌ", + "w": "ʍ", + "y": "ʎ", + "A": "∀", + "B": "𐐒", + "C": "Ɔ", + "E": "Ǝ", + "F": "Ⅎ", + "G": "פ", + "H": "H", + "I": "I", + "J": "ſ", + "L": "˥", + "M": "W", + "N": "N", + "P": "Ԁ", + "R": "ᴚ", + "T": "⊥", + "U": "∩", + "V": "Λ", + "Y": "⅄" + } + } +] \ No newline at end of file diff --git a/includes/json/config.json b/includes/json/config.json new file mode 100644 index 0000000..a798c7c --- /dev/null +++ b/includes/json/config.json @@ -0,0 +1,7 @@ +{ + "name": "Text Generator", + "email": "me@birajrai.tk", + "facebook-url": "https:\/\/www.facebook.com\/birajx2", + "github-url": "https:\/\/github.com\/birajrai\/text-generator", + "about": "lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua." +} \ No newline at end of file diff --git a/includes/json/statistics.json b/includes/json/statistics.json new file mode 100644 index 0000000..16a2cc4 --- /dev/null +++ b/includes/json/statistics.json @@ -0,0 +1,4 @@ +{ + "uses": 10, + "characters": 2888 +} \ No newline at end of file diff --git a/includes/text.generator.class.php b/includes/text.generator.class.php new file mode 100644 index 0000000..644fad4 --- /dev/null +++ b/includes/text.generator.class.php @@ -0,0 +1,153 @@ + count(self::get_sets()), + "uses" => (isset($stats['uses']) ? $stats['uses'] : 0), + "characters" => (isset($stats['characters']) ? $stats['characters'] : 0) + ); + } + return self::$stats; + } + + + public static function update_stats($type, $amount) { + $stats = self::get_json('statistics'); + if ( !isset($stats[$type]) ) { + $stats[$type] = 0; + } + $stats[$type] += $amount; + self::put_json('statistics', $stats); + } + + + public static function generate($text, $characters, $stats = false) { + $changed = 0; + $text = str_split($text); + foreach ( $text as $key => $value ) { + if ( isset($characters[$value]) ) { + $text[$key] = $characters[$value]; + ++$changed; + } + else if ( isset($characters[self::switch_case($value)]) ) { + $text[$key] = $characters[self::switch_case($value)]; + ++$changed; + } + } + if ( $stats ) { + self::update_stats('uses', 1); + self::update_stats('characters', $changed); + } + return implode($text); + } + + + public static function current_set() { + $sets = self::get_sets(); + if ( isset($_GET['slug']) && isset($sets[$_GET['slug']]) ) { + return $sets[$_GET['slug']]; + } + else { + self::website_redirect(self::website_url(), 'HTTP/1.1 301 Moved Permanently'); + } + } + + + public static function load_config(&$global) { + if ( file_exists(PATH_ABSOLUTE . 'install.php') && !preg_match('/install\.php$/', self::current_url()) ) { + self::website_redirect(self::website_url() . 'install.php'); + } + else { + $config = self::get_json('config'); + foreach ( $config as $name => $value ) { + $global[$name] = $value; + } + } + } + + +} +?> \ No newline at end of file diff --git a/index.php b/index.php new file mode 100644 index 0000000..6374d23 --- /dev/null +++ b/index.php @@ -0,0 +1,38 @@ + + + + + + + + + + <?php echo $website['name'];?> + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file