织梦搜索,关键词不少于2个字节

转个贴~~~~~~~~~~~~~~~~~~

针对织梦系统的织梦搜索,关键词时候出现不少于2个字节的样式,今天织梦爱好者网技术部分享一下如何解决这个问题:
织梦原始的搜索代码:
<form action="{dede:global name='cfg_phpurl'/}/search.php" name="formsearch">
<input type="hidden" name="kwtype" value="1" />
<input name="keyword" id="keyword" type="text" class="searchtxt" />
<select name="searchtype" id="searchtype">
<option value="titlekeyword" selected>智能模糊搜索</option>
<option value="title">仅搜索标题</option>
</select>
<input type="image" src="{dede:field name='templeturl'/}/images/topsearch_submit.gif" />
</form>

在调用其他样式的时候,必须添加的几个参数
<form action="{dede:global name='cfg_phpurl'/}/search.php" name="formsearch">
<INPUT class="Schinput C9 F14 Fari" name="keyword" id="keyword" type="text">
<input type="hidden" name="kwtype" value="1" />
<input class="SchBtn" onmouseover="this.className='SchBtn0';" onmouseout="this.className='SchBtn';" type="submit" value="" />
</form>

出现关键词不少于2个字节,不用修改其他的文件,就是文件的代码书写少了红色的部分,大家好好看看。

posted @ 2012-08-16 15:35  洛神红茶  阅读(512)  评论(0)    收藏  举报