https://github.com/mrclay/minify - nors man kazkodel nepasileido
https://github.com/matthiasmullie/minify - minifikatorius, bet kazin ar turi cache
http://rakaz.nl/code/combine - paprastas 1 failo skriptas su file cache filetime md5 pagrindu
2016 m. sausio 28 d., ketvirtadienis
2016 m. sausio 27 d., trečiadienis
Mokejimu gateway
https://www.paysera.lt/
https://mistertango.lt
https://cardinity.lt
https://opay.lt
Uzsienio
https://fortumo.com
https://coingate.com
http://www.worldpay.com/
https://www.braintreepayments.com
https://mistertango.lt
https://cardinity.lt
https://opay.lt
Uzsienio
https://fortumo.com
https://coingate.com
http://www.worldpay.com/
https://www.braintreepayments.com
load async
https://css-tricks.com/thinking-async/
taip pat rekomendujama sfriftus laikyti local storage http://www.sitepoint.com/improving-font-performance-subsetting-local-storage/
taip pat rekomendujama sfriftus laikyti local storage http://www.sitepoint.com/improving-font-performance-subsetting-local-storage/
mysql benchmarkt tool - mytop
yum install mytop
taip pat padeda sql komanda SHOW GLOBAL STATUSmytop --prompt
server info
wget http://percona.com/get/pt-summary
bash ./pt-summary
more info: https://www.percona.com/doc/percona-toolkit/2.2/pt-summary.html
2016 m. sausio 25 d., pirmadienis
Accelerated mobile pages
https://www.ampproject.org/
gerseniam mobile seo rekomenduojama kurti accelerated web pages
gerseniam mobile seo rekomenduojama kurti accelerated web pages
2016 m. sausio 18 d., pirmadienis
page optimisation
kaip is google pagespeed insights 77 score pasiekti 100, bootstrap atveju
http://www.appneta.com/blog/bootstrap-pagespeed/
vienas svarbesniu momentu - google pagespeed module
https://developers.google.com/speed/pagespeed/module/
http://www.appneta.com/blog/bootstrap-pagespeed/
vienas svarbesniu momentu - google pagespeed module
https://developers.google.com/speed/pagespeed/module/
load jquery after page load
https://github.com/danriti/bootstrap-pagespeed/commit/50e10b6a908d71fa8b79b153c36042a5d29efe1b
<script type="text/javascript">
+ // Add a script element as a child of the body
+ function downloadJSAtOnload() {
+ var element = document.createElement("script");
+ element.src = "scripts/all.min.js";
+ document.body.appendChild(element);
+ }
+
+ // Check for browser support of event handling capability
+ if (window.addEventListener)
+ window.addEventListener("load", downloadJSAtOnload, false);
+ else if (window.attachEvent)
+ window.attachEvent("onload", downloadJSAtOnload);
+ else window.onload = downloadJSAtOnload;
+ </script>
<script type="text/javascript">
+ // Add a script element as a child of the body
+ function downloadJSAtOnload() {
+ var element = document.createElement("script");
+ element.src = "scripts/all.min.js";
+ document.body.appendChild(element);
+ }
+
+ // Check for browser support of event handling capability
+ if (window.addEventListener)
+ window.addEventListener("load", downloadJSAtOnload, false);
+ else if (window.attachEvent)
+ window.attachEvent("onload", downloadJSAtOnload);
+ else window.onload = downloadJSAtOnload;
+ </script>
Load jQuery with Javascript and use jQuery
2016 m. sausio 15 d., penktadienis
Fontastic - ikonu rinkiniu kaip fontu kurimas
nenorite pilno fiont-awesome paketo? susikurkite savo fontu rinkini is ikonu:
http://app.fontastic.me/
online base4 images for inline usage: http://b64.io/
base64 embed font sample: http://stackoverflow.com/questions/6866965/how-to-detect-onload-for-base-64-encoded-webfonts
http://app.fontastic.me/
online base4 images for inline usage: http://b64.io/
base64 embed font sample: http://stackoverflow.com/questions/6866965/how-to-detect-onload-for-base-64-encoded-webfonts
Google material design - bootstrap alternartyva
https://www.google.com/design/spec/material-design/introduction.html
http://www.getmdl.io/ lite
pvz, admin theme http://www.getmdl.io/templates/dashboard/index.html
http://www.getmdl.io/ lite
pvz, admin theme http://www.getmdl.io/templates/dashboard/index.html
2016 m. sausio 14 d., ketvirtadienis
CDN for JS/CSS
A free super-fast CDN
for developers and webmasters http://www.jsdelivr.com/
for developers and webmasters http://www.jsdelivr.com/
Font loader
Eliminate render-blocking JavaScript and CSS in above-the-fold content. Use: https://github.com/typekit/webfontloader arba https://github.com/filamentgroup/loadCSS
2016 m. sausio 9 d., šeštadienis
Javacript document.write catch
If you're dealing with 3rd party scripts, simply replacing document.write to capture the output and stick it in the right place isn't good enough, since they could change the script and then your site would break.
writeCapture.js does what you need (full disclosure: I'm the author). It basically rewrites the script tags so that each one captures it's own
document.write
output and puts it in the correct place. The usage (using jQuery) would be something like:$(document.body).writeCapture().append('<script type="text/javascript" src="http://3rdparty.com/foo.js"></script>');
Here I'm assuming that you want to append to the end of the body. All jQuery selectors and manipulation methods will work with the plugin, so you can inject it anywhere and however you want. It can also be used without jQuery, if that is a problem.
2016 m. sausio 8 d., penktadienis
URL apdribimas iš turimo html
URL apdribimas iš turimo html
prepare_url($str, $len=0);
prepare_url($str, $len=0);
2016 m. sausio 7 d., ketvirtadienis
Neapkraunantis youtube užkrovimas
Jei viename tinklalapio lange norite ikelti daug youtube video, tai labai akraus puslapi, jei desite embeded visus youtube video. Todel geriau deti tik youtube cover paveiksleli su ant virsaus nupiestu play mygtuku. Istraukti coveri ir ji suaktyvinti, kad paspaudus coveri isikeltu grotuvas, nesunkiai galima padaryti su JS funkcija: http://www.sitepoint.com/faster-youtube-embeds-javascript/
Lightweight social share buttons
be addthis.com dar yra paprastas lengvas skriptukas http://sapegin.github.io/social-likes/ ( https://github.com/sapegin/social-likes )
papsrastas budas pasidaryti mytukus su fontawesome: http://webdesignerhut.com/css-social-sharing-buttons/
Geras budas pasidaryti mygtukus su counteriais, ne atskiro srifto failo (sriftas itrauktas i js): http://sapegin.github.io/social-likes/
papsrastas budas pasidaryti mytukus su fontawesome: http://webdesignerhut.com/css-social-sharing-buttons/
Geras budas pasidaryti mygtukus su counteriais, ne atskiro srifto failo (sriftas itrauktas i js): http://sapegin.github.io/social-likes/
2016 m. sausio 5 d., antradienis
Website benchmark tool
https://gtmetrix.com - irankis vertinti tinklalapiui
2016 m. sausio 4 d., pirmadienis
JS ekrano screenshot paėmimas ir siuntimas į serverį
http://permadi.com/2010/10/html5-saving-canvas-image-data-using-php-and-ajax/
http://www.jedox.com/en/screen-shot-web-via-javascript-saving-back-server
https://html2canvas.hertzen.com/
html to canvas alternatyva: http://cburgmer.github.io/rasterizeHTML.js/ taip pat https://github.com/Irrelon/html-to-canvas
Tačiau mums reikia html versti į canvas, naudojant html2canvas.js
Server side:
http://www.jedox.com/en/screen-shot-web-via-javascript-saving-back-server
https://html2canvas.hertzen.com/
html to canvas alternatyva: http://cburgmer.github.io/rasterizeHTML.js/ taip pat https://github.com/Irrelon/html-to-canvas
function saveViaAJAX() | |
{ | |
var testCanvas = document.getElementById("testCanvas"); | |
var canvasData = testCanvas.toDataURL("image/png"); | |
var postData = "canvasData="+canvasData; | |
var debugConsole= document.getElementById("debugConsole"); | |
debugConsole.value=canvasData; | |
//alert("canvasData ="+canvasData ); | |
var ajax = new XMLHttpRequest(); | |
ajax.open("POST",'testSave.php',true); | |
ajax.setRequestHeader('Content-Type', 'canvas/upload'); | |
//ajax.setRequestHeader('Content-TypeLength', postData.length); | |
ajax.onreadystatechange=function() | |
{ | |
if (ajax.readyState == 4) | |
{ | |
//alert(ajax.responseText); | |
// Write out the filename. | |
document.getElementById("debugFilenameConsole").innerHTML="Saved as<br><a target='_blank' href='"+ajax.responseText+"'>"+ajax.responseText+"</a><br>Reload this page to generate new image or click the filename to open the image file."; | |
} | |
} | |
ajax.send(postData); | |
} |
Tačiau mums reikia html versti į canvas, naudojant html2canvas.js
function takeScreenShot(){
html2canvas(window.parent.document.body, {
onrendered: function(canvas) {
var cand = document.getElementsByTagName('canvas');
if(cand[0] === undefined || cand[0] === null){
}else{
//cand[0].remove();
document.body.removeChild(cand[0]);
}
document.body.appendChild(canvas);
}
});
}
Server side:
<?php
if
(isset($GLOBALS[
"HTTP_RAW_POST_DATA"
]))
{
// Get the data
$imageData=$GLOBALS[
'HTTP_RAW_POST_DATA'
];
// Remove the headers (data:,) part.
// A real application should use them according to needs such as to check image type
$filteredData=substr($imageData, strpos($imageData,
","
)+1);
// Need to decode before saving since the data we received is already base64 encoded
$unencodedData=base64_decode($filteredData);
//echo "unencodedData".$unencodedData;
// Save file. This example uses a hard coded filename for testing,
// but a real application can specify filename in POST variable
$fp =
fopen
(
'test.png'
,
'wb'
);
fwrite
( $fp, $unencodedData);
fclose
( $fp );
}
?>
JS loader
http://requirejs.org/ - padeda per funkcijas uzkrauti asinchroniskai kitas JS bibliotekas, pvz jQuery, nestabdant HTML isvedimo i ekrana
Taip pat http://headjs.com/
Taip pat http://headjs.com/
Android / ios appslikacijų kūrimas
Naudojant html/js/css standartus, aplikacijas galima kurti http://phonegap.com/ pagalba
Užsisakykite:
Pranešimai (Atom)