Introduction to asp.net MVC: Search and price screening for Taobao products

Source: Internet
Author: User
Tags min

51 things that have been busy with Android until now finally have a chance to catch my breath, so I took the time to write this blog, to record my previous study of MVC after a week to write a small example: Search Taobao products and price screening products.

First start the interface:

The source code for this interface is as follows:

@{
    viewbag.title = "Home page";
}
    
 <script src= "@Url. Content (" ~/scripts/jquery.validate.min.js ")" 

type= "Text/javascript" ></script>
 <script src= "@Url. Content (" ~/scripts/jquery.validate.unobtrusive.min.js ")" 

type= "Text/javascript" ></script>
    
@using (Html.BeginForm ()) {
    <fieldset>
    
        <legend>Search</legend>
        <p id = "Editor-field" >
            <p> Search for merchandise @Html. TextBox ("keyword") 
            </p> <p> Price limit @ Html.textbox ("Max") </p>
            <p> Lower price @Html. TextBox ("min") </p>
        </p>
    </ fieldset>
        <p>
            <input type= "Submit" value= "Search"/>
        </p>
}

It is noteworthy that I marked the Code red, the textbox provides user input, and submits the user input, "keyword" in parentheses is used to identify the submitted content, so that we can extract the user's input from the submitted form.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.