Archive for the 'web trick' Category

28 Oct 2017

identify the type of an object

12:54 | javascript, web trick | 240 views

Goal: simple way to check the type of a page object I have found many answers about this question but the useless is much more than the valuable. There is a simple way to identify objects on the page. For example I have a click listener and I want to know the type of the […]


7 Apr 2017

use the camera

14:15 | html5, web trick | 194 views

Goal: simple way to use the camera I’ve read some articles about this, but there was no a simple one. So, here is: check it: here Two thing to know. 1. the browser will say insecure connection. Just say do it anymore 2. Take a Photo will take a photo after 3 sec


7 May 2015

How to crash the Chrome from javascript

0:01 | javascript, web trick | 409 views

Goal: there is no goal at all… I have came across an unhandled exception in the Chrome what is crashing the actual page. The js command is simple: so and there is a living issue ticket (somebody else found this as well): jump


19 Mar 2015

autofit div variant

12:41 | web trick | 363 views

Goal: to find a good way to create an autofit div How can I use a divs to fill spaces like panels in the desktop applications? 1. css calc() This is brilliant but maybe dangerous because of the browsers. 2. content shifting with padding 3. stretched sail – div glued to the edges This way […]


14 Feb 2015

quick js editor

23:41 | javascript, web trick | 351 views

Goal: a simple js editor from the browser put the following to the address line… 1. simple way: try this this one is poor because of not focus, but here is the fixed version: 1.1 simple way with focus in the window: try this 2. extended editor (big respect for the ace team! check it […]


23 Oct 2014

Vista internet speed increase

10:10 | web trick | 352 views

Goal: to increase the speed of the internet connection I’ve read many articles about this topic and seemingly I’ve found a good idea. Let’s open a command prompt as an Administrator and type netsh interface tcp set global autotuning=disabled This solution is enough to the happiness. nota bene: this solution working without restart! check the […]


3 Sep 2014

edit in place

14:56 | javascript, web trick | 299 views

Goal: To create a simple editable field on my page There is a simple way to create an editable DIV field. We can start the editing by click or simple on getting focus. So in this case the editor is the container itself. Forget to create input boxes or textarea-s and forget the additional event […]


29 Jun 2014

detect the ie version on the client side

14:17 | web trick | 471 views

Goal: feature specific ie version detection I’ve found somewhere a tricky solution for this problem. Here is a little bit modified version of that: The isIE variable will be the version number if we have an internet explorer in other cases this variable will be . The original method not working above ie9, that’s why […]


24 Jun 2014

Get the client country based on ip address

18:05 | php, web trick | 678 views

Goal: find the client on the map I was supprised when I examined my server’s stat. There were many client from unknown country. This is not too good. I remember an old solution depends on ip2c database. This is nice and easy, but to keep the database updated not too confortable. 1. database solution I […]


19 Jun 2014

no more cache – force the reload based on the file date

8:17 | php, web trick | 383 views

Goal: avoid cache in case of changed files The cache is our friend in case of old files. With this code I can use the cache based on my file date. the result is In a little bit friendly shape: Shorter, smarter… Call the no_cache class like


#sidebar a { color:#fff; } #sidebar ul ul li { color: #DEF585; } #sidebar h2 { color: #fff; } #sidebar ul p, #sidebar ul select { color: #BEDDBE; } #backfly { background: url(images/golfBallWallPaper.jpg) left bottom fixed repeat-x #65a51d; }