Archive for 六月, 2011

syslog

[belogErrorReporting]

  1. Integer: Configures which PHP errors should be logged to the “syslog” table (extension: belog). If set to “0” no PHP errors are logged to the sys_log table. Default is “E_ALL ^ E_NOTICE” (6135).

 


how to get a js png fix to work on ajax calls

If you are using iepngfix.htc, you might try setting the behavior inline

var myEl = document.getElementById('inbound-ajax-element');
myEl.style.behavior = 'url(iepngfix.htc)';

http://www.twinhelix.com/css/iepngfix/demo/

 

You should take a look here jQuery IE PNG Fix Plugin

jQuery(function($) {
    $("img[@src$=png], #image-one, #image-two").pngfix();
});

You should run this on the images you just loaded.

 

demo:

 

function filterAlphaImages(){
	var rslt = navigator.appVersion.match(/MSIE (\d+\.\d+)/, '');
	var itsAllGood = (rslt != null && Number(rslt[1]) >= 5.5);
	if (itsAllGood) {
		for (var i=0; i<document.all.length; i++){
			var obj = document.all[i];
			var bg = obj.currentStyle.backgroundImage;
			var img = document.images[i];
			if (bg && bg.match(/\.png/i) != null) {
			var img = bg.substring(5,bg.length-2);
			var offset = obj.style["background-position"];
			obj.style.filter =
			"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+img+"', sizingMethod='crop')";
			obj.style.backgroundImage = "url('fileadmin/templates/images/pixel.gif')";
			obj.style["background-position"] = offset; // reapply
			} else if (img && img.src.match(/\.png$/i) != null) {
			var src = img.src;
			img.style.width = img.width + "px";
			img.style.height = img.height + "px";
			img.style.filter =
			"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+src+"', sizingMethod='crop')"
			img.src = "fileadmin/templates/images/pixel.gif";
			}
		}
	}
}

 


typoscript numberFormat

Calls the PHP function number_format
Allows you to format numbers
Note: TYPO3 v4.5 introduces a stdWrap property numberFormat. In order to avoid conflicts, the extension disables its own stdWrap property described below.Converting a number to localized Euro value

(continue reading…)


anytopdf

anytopdf is a perl script that converts OpenOffice.org, Microsoft Office (Word DOC, Excel XLS), RTF, HTML, and other openoffice.org readable file formats to the PDF format. It will automatically install the supporting ‘AnyToPDF’ OpenOffice.org Basic macro library in the current user’s OpenOffice.org configuration if it’s not already present. (continue reading…)


PHP内存溢出Allowed memory size of 解决办法

在PHP里,至少有一种情况内存不会得到自动释放,即便是手动调用 unset()。详情可考:http://bugs.php.net/bug.php?id=33595(continue reading…)


MySQL双机热备份试验

linux服务器lvs负载均衡、双机热备应用中经常用到mysql双机热备,安装和配置过程如下: (continue reading…)


Copyright © 1996-2010 Add Lives. All rights reserved.
iDream theme by Templates Next | Powered by WordPress