- Timestamp:
- 2007/07/20 15:58:59 (19 years ago)
- Location:
- branches/feature-module-update
- Files:
-
- 1 edited
- 2 copied
-
. (copied) (copied from branches/rel) (1 prop)
-
html (copied) (copied from branches/rel/html)
-
html/admin/contents/recommend_search.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/feature-module-update
-
Property
svn:ignore
set to
.cache
.settings
.projectOptions
-
Property
svn:ignore
set to
-
branches/feature-module-update/html/admin/contents/recommend_search.php
r12157 r15078 22 22 $objSess = new SC_Session(); 23 23 24 // ǧ¾Ú²ÄÈݤÎȽÄê24 // 認証可否の判定 25 25 sfIsSuccess($objSess); 26 26 27 27 if ($_POST['mode'] == "search") { 28 28 29 // POST Ãͤΰú¤·Ñ¤®29 // POST値の引き継ぎ 30 30 $objPage->arrForm = $_POST; 31 // ÆþÎÏʸ»ú¤Î¶¯À©ÊÑ´¹31 // 入力文字の強制変換 32 32 lfConvertParam(); 33 33 … … 35 35 $where = "del_flg = 0"; 36 36 37 /* ÆþÎÏ¥¨¥é¡¼¤Ê¤·*/37 /* 入力エラーなし */ 38 38 foreach ($objPage->arrForm as $key => $val) { 39 39 if($val == "") { … … 48 48 break; 49 49 case 'search_category_id': 50 // »Ò¥«¥Æ¥´¥êID¤Î¼èÆÀ50 // 子カテゴリIDの取得 51 51 $arrRet = sfGetChildsID("dtb_category", "parent_category_id", "category_id", $val); 52 52 $tmp_where = ""; … … 74 74 $order = "update_date DESC, product_id DESC"; 75 75 76 // ÆÉ¤ß¹þ¤àÎó¤È¥Æ¡¼¥Ö¥ë¤Î»ØÄê76 // 読み込む列とテーブルの指定 77 77 $col = "product_id, name, category_id, main_list_image, status, product_code, price01, stock, stock_unlimited"; 78 78 $from = "vw_products_nonclass AS noncls "; 79 79 80 80 $objQuery = new SC_Query(); 81 // ¹Ô¿ô¤Î¼èÆÀ81 // 行数の取得 82 82 $linemax = $objQuery->count("dtb_products", $where, $arrval); 83 $objPage->tpl_linemax = $linemax; // ²¿·ï¤¬³ºÅö¤·¤Þ¤·¤¿¡£É½¼¨ÍÑ83 $objPage->tpl_linemax = $linemax; // 何件が該当しました。表示用 84 84 85 // ¥Ú¡¼¥¸Á÷¤ê¤Î½èÍý85 // ページ送りの処理 86 86 if(is_numeric($_POST['search_page_max'])) { 87 87 $page_max = $_POST['search_page_max']; … … 90 90 } 91 91 92 // ¥Ú¡¼¥¸Á÷¤ê¤Î¼èÆÀ92 // ページ送りの取得 93 93 $objNavi = new SC_PageNavi($_POST['search_pageno'], $linemax, $page_max, "fnNaviSearchOnlyPage", NAVI_PMAX); 94 $objPage->tpl_strnavi = $objNavi->strnavi; // ɽ¼¨Ê¸»úÎó94 $objPage->tpl_strnavi = $objNavi->strnavi; // 表示文字列 95 95 $startno = $objNavi->start_row; 96 96 97 // ¼èÆÀÈϰϤλØÄê(³«»Ï¹ÔÈֹ桢¹Ô¿ô¤Î¥»¥Ã¥È)97 // 取得範囲の指定(開始行番号、行数のセット) 98 98 if(DB_TYPE != "mysql") $objQuery->setlimitoffset($page_max, $startno); 99 // ɽ¼¨½ç½ø99 // 表示順序 100 100 $objQuery->setorder($order); 101 101 102 // view ¤â¹Ê¹þ¤ß¤ò¤«¤±¤ë(mysqlÍÑ)102 // viewも絞込みをかける(mysql用) 103 103 sfViewWhere("&&noncls_where&&", $where, $arrval, $objQuery->order . " " . $objQuery->setlimitoffset($page_max, $startno, true)); 104 104 105 // ¸¡º÷·ë²Ì¤Î¼èÆÀ105 // 検索結果の取得 106 106 $objPage->arrProducts = $objQuery->select($col, $from, $where, $arrval); 107 107 } 108 108 109 // ¥«¥Æ¥´¥ê¼èÆÀ109 // カテゴリ取得 110 110 $objPage->arrCatList = sfGetCategoryList(); 111 111 … … 115 115 116 116 117 //---- ¡¡¥Ú¡¼¥¸É½¼¨117 //---- ページ表示 118 118 $objView->assignobj($objPage); 119 119 $objView->display($objPage->tpl_mainpage); … … 123 123 //--------------------------------------------------------------------------------------------------------------------------------------------------------- 124 124 125 /* ¼èÆÀʸ»úÎó¤ÎÊÑ´¹*/125 /* 取得文字列の変換 */ 126 126 function lfConvertParam() { 127 127 global $objPage; 128 128 /* 129 * ʸ»úÎó¤ÎÊÑ´¹130 * K : ¡ÖȾ³Ñ(Êݶ¸)ÊÒ²¾Ì¾¡×¤ò¡ÖÁ´³ÑÊÒ²¾Ì¾¡×¤ËÊÑ´¹131 * C : ¡ÖÁ´³Ñ¤Ò¤é²¾Ì¾¡×¤ò¡ÖÁ´³Ñ¤«¤¿²¾Ì¾¡×¤ËÊÑ´¹132 * V : ÂùÅÀÉÕ¤¤Îʸ»ú¤ò°ìʸ»ú¤ËÊÑ´¹¡£"K","H"¤È¶¦¤Ë»ÈÍѤ·¤Þ¤¹133 * n : ¡ÖÁ´³Ñ¡×¿ô»ú¤ò¡ÖȾ³Ñ(Êݶ¸)¡×¤ËÊÑ´¹129 * 文字列の変換 130 * K : 「半角(ハンカク)片仮名」を「全角片仮名」に変換 131 * C : 「全角ひら仮名」を「全角かた仮名」に変換 132 * V : 濁点付きの文字を一文字に変換。"K","H"と共に使用します 133 * n : 「全角」数字を「半角(ハンカク)」に変換 134 134 */ 135 135 $arrConvList['search_name'] = "KVa"; 136 136 $arrConvList['search_product_code'] = "KVa"; 137 137 138 // ʸ»úÊÑ´¹138 // 文字変換 139 139 foreach ($arrConvList as $key => $val) { 140 // POST ¤µ¤ì¤Æ¤¤¿ÃͤΤßÊÑ´¹¤¹¤ë¡£140 // POSTされてきた値のみ変換する。 141 141 if(isset($objPage->arrForm[$key])) { 142 142 $objPage->arrForm[$key] = mb_convert_kana($objPage->arrForm[$key] ,$val);
Note: See TracChangeset
for help on using the changeset viewer.
