Generate dynamically iframe and it’s content
2 April 2014 | Category: Browsers, JavaScript | Comments (2)
Let’s say you want to generate dynamically iframe
and instead of point to external source:
<script>
var iframe = document.createElement('ifr[......]
Google Chrome and load insecure content
31 March 2014 | Category: Browsers | Comments (0)
Google Chrome, by default, blocks insecure content on secure pages. It doesn’t allow you to mix HTTPS and HTTP connections. In developer console you’l[……]
contenteditable and prevent from going to new line using ENTER key
3 February 2014 | Category: Browsers, JavaScript | Comments (0)
Let’s say we have a simple div
HTML element with attribute contenteditable
. Sometimes we want to observe ENTER key and prevent cursor to go to new lin[……]
How to override compatibility mode for intranet site when “Display intranet sites in Compatibility View” is checked?
31 January 2014 | Category: Browsers | Comments (0)
Based on some research in internet I found that we can use HTML meta tag:
meta http-equiv="X-UA-Compatible" content="IE=edge"
to force IE to use h[……]
Modal windows – are they always necessary?
27 November 2013 | Category: Browsers, General | Comments (0)
I do not want to write about “what is modal windows”, but focus on potential problems which may occur when you start using modal windows in some scena[……]
JS Tip: How to check if specified HTML element is supported by the browser
11 November 2013 | Category: Browsers, JavaScript | Comments (0)
To check if browser support specified HTML element you can use:
function isHTMLElementSupported(elm) {
return (Object.prototype.toString.call([......]
How to check if browser supports cookies using client-side technique
29 September 2013 | Category: Browsers, JavaScript | Comments (0)
Introduction
There is at least (which I know) two methods to find out if cookies are enabled or not. You can use client-side script techniques or s[……]
Simple technique to preload images at specified moment
20 August 2013 | Category: Browsers, Optimizing | Comments (2)
There are many ways to preload images, including methods that rely on CSS, JavaScript, and various combinations thereof. Here I would like to present[……]
JS tip: always use full reference
17 August 2013 | Category: Browsers, JavaScript, Optimizing | Comments (0)
Let’s say we have an example of code like this:
(function(){
function close_window() {
if (typeof self.close === 'function') {[......]
CSS: provide a unit for zero lengths
8 July 2013 | Category: Browsers, CSS, Tools | Comments (0)
Zero lengths do not need unit. However, there is some significant benefits of using unit with zero lengths while developing code.