Php test Navigation engine laguage, and Syetem language

Php test Navigation engine laguage

Php test Syetem lang

Read the rest of this entry »

Disordered Chinese Characters in Phpld

Open init.php, between
$db->SetFetchMode(ADODB_FETCH_ASSOC);
read_config($db);

add MySQL_query(”SET NAMES ‘latin1′”);

let them becomes: Read the rest of this entry »

Finding Items in an Array or not with PHP

The problem: we have an array of items in PHP and we want to find out if a specific item is in the array. In code we can define the array as:
Read the rest of this entry »

how to add php code in phpld, find current url?

It is very simple,just like this:

{php}
echo “PHP
“;
echo “I love PHP
“;
echo “included in .tpl
“;
{/php}

Find the Current URL with PHP Read the rest of this entry »

Host 2 domains for the same wordpress database.

Q:Me and a friend are trying to make http://kingphp.com and www.chinascience.org the same… I hosted his domain on my hosting as an add-on domain. Read the rest of this entry »

Mass Post Manager for Wordpress

This plugin performs the following tasks:

Delete all posts and/or comments in selected category
Move all posts from one category to another
Plugin was developed for may needs so its functionality is quite limited right now. However i plan to add more and more features to Mass Post Manager Read the rest of this entry »

Show random ads at phpld

If you’re looking for a simple static solution (an not an entire ad manager) use this
add in your init.php after the $tpl = get_tpl(… line Read the rest of this entry »

Make a string’s first character uppercase

ucfirst — Make a string’s first character uppercase

example:

$coo= ‘clay desiccant!’;
$coo= ucfirst($desiccant); // Clay desiccant!

$bar = ‘CLAY DESICCANT!’;
$bar = ucfirst($bar); // CLAY DESICCANT!
$bar = ucfirst(strtolower($bar)); // Clay desiccant!

Read the rest of this entry »

How to ad text on main page of phpld?

{if $category.ID == 0}
This is the description of my homepage. I can even include html.
{/if}

Note:the above code works, but the only problem is this added text also appears when using the search function from the home page. Read the rest of this entry »

How to show all files under a document and rename the file names?

$dirname=”E:/zhanzhongjie/chengbiao-com/chengbiao-com”;
$dir_handle=opendir($dirname);
while($file=readdir($dir_handle))

{
echo $file.”
“;
rename(”E:/zhanzhongjie/chengbiao-com/chengbiao-com/”. $file, “E:/zhanzhongjie/chengbiao-com/chengbiao-new/insurance-”.$file);
}

closedir($dir_handle) Read the rest of this entry »