摘要: 替换文本中出现的字母(大写+小写)$row= preg_replace("/[a-z'A-Z]/i",null, $str);替换文本中出现的字母(大写)$row= preg_replace("/[a-z']/i",null, $str);替换文本中出现的数字$row= preg_replace("/[0-9']/i",null, $str);替换文本中出现的数字+字母$row= preg_replace("/[^\x{4E00}-\x{9FFF}]{1,4}/u",null, $str); 阅读全文
posted @ 2013-09-21 11:43 Damon.Wu 阅读(144) 评论(0) 推荐(0)
摘要: 0) { // Check whether the browser/gateway says it accepts WML. $br = "WML"; } else { $browser = isset($_SERVER['HTTP_USER_AGENT']) ? trim($_SERVER['HTTP_USER_AGENT']) : ''; if(empty($browser)) return true; $mobile_os_list=array('Google Wireless Transc... 阅读全文
posted @ 2013-09-21 11:32 Damon.Wu 阅读(260) 评论(0) 推荐(0)
摘要: 1、打开includes/lib_article.php文件:找到:大约21行-82行代码,替换为一下/*** 获得文章分类下的文章列表** @access public* @param integer $cat_id* @param integer $page* @param integer $size** @return array*/function get_cat_articles($cat_id, $page = 1, $size = 20 ,$requirement=''){//取出所有非0的文章if ($cat_id == '-1'){$cat_s 阅读全文
posted @ 2013-09-21 11:12 Damon.Wu 阅读(320) 评论(0) 推荐(0)
摘要: 找到start.htm 模板注释Ajax.call('cloud.php?is_ajax=1&act=cloud_remind','', cloud_api, 'GET', 'JSON');这一行就可以了 阅读全文
posted @ 2013-09-21 11:08 Damon.Wu 阅读(234) 评论(0) 推荐(0)
摘要: 以官方自带默认模板为例进行修改,其他模板大同小异,可参照修改方法。第一步、 用编辑器打开商品详情页模板文件-----goods.dwt1. ----在之间加入如下代码2. ----定位到把它修改为3. ----保存第二步、 用编辑器打开商品相册库文件-----library/goods_gallery.lbi把改为(此处其他模板稍有差别,请看仔细!) 阅读全文
posted @ 2013-09-21 10:55 Damon.Wu 阅读(756) 评论(0) 推荐(0)
摘要: 有不少人都在找支持ECShop用户名、邮箱或手号码登录的插件,下面就讲一下如何实现用户名、邮箱或手机号码登录ECShop。找到user.php 的以下代码:if (empty($_POST['captcha'])){show_message($_LANG['invalid_captcha'], $_LANG['relogin_lnk'], 'user.php', 'error');}后面增加:if(is_email($username)){$sql ="select user_name from &quo 阅读全文
posted @ 2013-09-21 10:53 Damon.Wu 阅读(480) 评论(0) 推荐(0)
摘要: 在首页调出指定分类下的精品或新品或热销,分别在不同地方调用,使用下面的函数$children = get_children(你要调用的分类ID);$smarty->assign( 'bestGoods', get_category_recommend_goods('best', $children));$smarty->assign( 'newGoods', get_category_recommend_goods('new', $children));$smarty->assign( 'hotGoods 阅读全文
posted @ 2013-09-21 10:51 Damon.Wu 阅读(391) 评论(0) 推荐(0)