private void SortByList() { StringBuilder itemViewListSortByBdl = new StringBuilder(); itemViewListSortByBdl.Append("<span class=\"sfLocale\">Sort by:</span><select id=\"ddlSortItemDetailBy\" class=\"sfListmenu\">"); SortByOptions = SortByOptions.TrimEnd(','); if (SortByOptions != "") { foreach (string sortByOpt in SortByOptions.Split(',')) { string[] sortByOpt1 = sortByOpt.Split('#'); if (sortByOpt1[0] == SortByOptionDefault) { itemViewListSortByBdl.Append("<option selected=\"selected\" data-html-text=\"" + sortByOpt1[1] + "\" value=" + sortByOpt1[0] + ">" + sortByOpt1[1] + "</option>"); } else { itemViewListSortByBdl.Append("<option data-html-text=\"" + sortByOpt1[1] + "\" value=" + sortByOpt1[0] + ">" + sortByOpt1[1] + "</option>"); } } } itemViewListSortByBdl.Append("</select>"); ltrItemViewDetailSortBy.Text = itemViewListSortByBdl.ToString(); if (Request.QueryString["id"] == "special") { LoadAllSpecialItems(); } }
private void SortByList() { StringBuilder itemViewListSortByBdl = new StringBuilder(); itemViewListSortByBdl.Append("<h4 class=\"sfLocale\">Sort by:</h4><select id=\"ddlSortItemDetailBy\" class=\"sfListmenu\">"); SortByOptions = SortByOptions.TrimEnd(','); if (SortByOptions != "") { foreach (string sortByOpt in SortByOptions.Split(',')) { string[] sortByOpt1 = sortByOpt.Split('#'); if (sortByOpt1[0] == SortByOptionDefault) { itemViewListSortByBdl.Append("<option selected=\"selected\" data-html-text=\"" + sortByOpt1[1] + "\" value=" + sortByOpt1[0] + ">" + sortByOpt1[1] + "</option>"); } else { itemViewListSortByBdl.Append("<option data-html-text=\"" + sortByOpt1[1] + "\" value=" + sortByOpt1[0] + ">" + sortByOpt1[1] + "</option>"); } } } itemViewListSortByBdl.Append("</select>"); ltrItemViewDetailSortBy.Text = itemViewListSortByBdl.ToString(); if (Request.QueryString["id"].ToLower() == "best") { LoadAllBestSoldItems(); } if (Request.QueryString["id"].ToLower() == "special") { LoadAllSpecialItems(); } if (Request.QueryString["id"].ToLower() == "feature") { LoadAllFeature(); } if (Request.QueryString["id"].ToLower() == "recent") { LoadAllRecentlyViewedItems(); } if (Request.QueryString["id"].ToLower() == "new") { LoadAllLatestItems(); } if (Request.QueryString["id"].ToLower() == "giftCard") { LoadAllGiftCard(); } if (Request.QueryString["id"] == "heavy") { LoadAllHeavyDiscountItems(); } if (Request.QueryString["id"] == "seasonal") { LoadAllSeasonalItems(); } }