Index.cshtml


Dosyayı İndir
@{
    ViewBag.Title = "Index";
}

<h2>Index</h2>
 
    Örnek Adı <input type="text" id="SampleName" /><b />
    Başka Bir Şey <input type="text" id="AnotherThing" /><b />

    @section Scripts {
    <script type="text/javascript" language="javascript">
        $(function () {
            alert("Çağrıldı");
            $("#SampleName").autocomplete({
                source: function (request, response) {
                    $.ajax({
                        url: "/Complete/Suggestions", type: "POST", dataType: "json",
                        data: { searchText: request.term, maxResults: 10 },
                        success: function (data) {
                            response($.map(data, function (item) {
                                return { label: item.SampleName, value: item.SampleName, id: item.SampleId }
                            }))
                        }
                    })
                },
                select: function (event, ui) {
                    alert(ui.item ? ("You picked '" + ui.item.label + "' with an ID of " + ui.item.id)
                        : "Nothing selected, input was " + this.value);
                }
            });

        });
    </script>
    }

				
Dosyayı İndir

Bu Sayfayı Paylaş:




Bu Sayfayı Paylaş:

İletişim Bilgileri

Takip Et

Her Hakkı Saklıdır. Bu sitede yayınlanan tüm bilgi ve fikirlerin kullanımından fibiler.com sorumlu değildir. Bu sitede üretilmiş , derlenmiş içerikleri, fibiler.com'u kaynak göstermek koşuluyla kendi sitenizde kullanılabilirsiniz. Ancak telif hakkı olan içeriklerin hakları sahiplerine aittir