Archive

Archive for the ‘Tutorials’ Category

Howto: Force a browser redraw/repaint

September 24th, 2010 3 comments

Have you ever had the problem that IE (most often in IE6, IE7 and even in IE8) or other browsers just didn’t redraw the content? This happens quite often when CSS properties get changed via JavaScript. There are already some solutions available to solve this problem but most of them just don’t work properly. I’m now going to show you the way it works most often and a solution which I found myself.
Read more…

Categories: HTML / CSS, JavaScript, Tutorials Tags:

Howto: 100% height and width background image (CSS / JavaScript)

January 22nd, 2010 1 comment

Hello everyone

Somewhen every frontend developer will be faced with the problem that you cannot stretch a background image to 100% height and width by default (except CSS3 compatible browsers). This is very annoying if the background image contains a gradient or something else which can not be repeated. Now I will show you how to realize such a solution with min-height and min-width support which works in all browsers (IE6, IE7, IE8, Safari, Chrome, Firefox and Opera). Read more…

Categories: HTML / CSS, JavaScript Tags:

How to bypass the JavaScript (AJAX) Same Origin Policy

February 28th, 2009 7 comments

Due to a security feature it is not allowed to make cross domain calls within JavaScript. There are several ways to bypass this limitation. One of the best solutions in my opinion is to use a small flash file which makes these calls for you since Flash is able to make cross domain calls (requires a crossdomain.xml on the destination server).

Read more…

How to call CodeIgniter from the CLI or Cron

February 18th, 2009 5 comments

Since CodeIgniter does not accept arguments via the command line, you can not call a specific controller or function.
So you have to do the following to run CI from the CLI or Cron.

Create a second file in the root directory called cronjob.php or whatever and enter these two lines of code:

$_GET["/controller/function"] = null;
require “index.php”;

Make sure to replace “controller” and “function” with your desired controller/function.

Categories: CodeIgniter Tags: ,