select列表双向选择

<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-

transitional.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”>
<head>
<title>select列表双向选择</title>
<script type=”text/javascript” src=”jquery-1.4.2.js”></script>
<style type=”text/css”>   (continue reading…)


mysql按字母排序

数据表某字段client_name的字符编码是utf8_general_ci;


国家代号与区号

Country CODE. (continue reading…)


PHP+MySql中文乱码解决方案

我相信PHPmyadmin里查看是乱码,调用出来的话肯定100%也是乱码。乱码问题其实也就是编码不一致导致的。要解决这个问题需要回顾乱码问题出现以前的操作是否使用的是同一种编码。

总之一句话,要解决PHP中文乱码最好最快的解决办法就是:页面申明的编码与数据库内部编码一致,如果页面申请的页码与数据库内部编码不一致时,就设定连接编码mysql_query(”SET NAMES XXX”); XXX为连接编码。一定可以解决乱码的问题。

在mysql+php程序开发中,总结了产生乱码原因: (continue reading…)


htaccess文件缓存WP图片

WordPress博客里大量的图片会使页面加载速度变得缓慢。 此时访问者需要用更多时间才能打开一个页面。 不过我们可以通过缓存图片来解决这个问题。 当页面第一次被加载时,将所有图片存放在浏览器的缓存池里。 之后访问者再加载该页面时,浏览器就可以从浏览器缓存中获取图片,从而减少页面加载时间。 (continue reading…)


imagettftext字符间距

imagepstext有字符间距参数,而imagettftext没有,解决思路是逐个写入字符,有两种方法 (continue reading…)


RTE图片绝对路径

t3lib/class.t3lib_parsehtml_proc.php line533 块注释

                    // Convert abs to rel url
                 if ($imgSplit[$k])    {
                    $attribArray=$this->get_tag_attributes_classic($imgSplit[$k],1);
                    $absRef = trim($attribArray['src']);
                    if (t3lib_div::isFirstPartOfStr($absRef,$siteUrl))    {
                        $attribArray['src'] = $this->relBackPath.substr($absRef,strlen($siteUrl));
                        if (!isset($attribArray['alt']))    $attribArray['alt']='';        // Must have alt-attribute for XHTML compliance.
                        $imgSplit[$k]='';
                    }
                } 
1 Comment more...

ecshop函数列表大全

所有函数功能说明:

lib_time.php
gmtime()
P: 获得当前格林威治时间的时间戳 /$0
server_timezone()
P: 获得服务器的时区 /$0 (continue reading…)


smarty实例教程

smarty实例教程

整个教程分四大部分:
一、模板设计部分
二、程序设计部分
三、实例篇(使用PHP内置MySQL函数)
四、实例篇(使用phplib的DB类)
(continue reading…)

1 Comment more...

Font Files

Identifying Font Files

Differences between Mac and PC files
The PC and Mac differ in the way they store files. On a Mac each file can have two parts called forks. The data fork holds data (text, images, etc.). The resource fork holds resources (icons, fonts, menus, sounds, etc.). There are actually two files linked to one name in the file system. PCs only have one file linked to each name. Macs also have two four character fields stored with the name for each file. They are called the type and creator. The type field tells the Mac software what type of file it is. The creator is a unique signature identifying a program on the Mac. This field tells the Mac OS what program to launch if the files icon is clicked. PCs identify files with a file name extension. This is the characters after a period at the end of the file name. It used to be limited to three characters from the DOS days, but it can now be larger on current Windows versions. This tells Windows both what type of file it is and what program to launch if the icon is clicked. Unlike the Mac, you have to tell Windows what program goes with what extension (this can also be done automatically by a setup program). OS X seems to be moving away from using resource forks as heavily as OS Classic. It also can use file name extensions like Windows and Linux in addition to a file type and creator. This makes files more portable and easier to transmit over networks.

(continue reading…)


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