Format:
Recent snippets matching tags of call
//start processing var api = new moviesApi(); api.getRatings({ success: function (result) { for (var i = 0; i < result.length; i++) { //new Option(text, value) var option = new Option(result[i].ID, result[i].Name); $('#ratings').append( $('<option></option>').val(result[i].ID).html(result[i].Name) );
23 Views
no comments
// JavaScript Code $().ready(function () { ajaxCallMethod("CallbackHandler.ashx?", "GetDate", [{ Name: "Rick", Entered: new Date(2012,0,1) }], function (result) { alert(result); }); ajaxCallMethod("CallbackHandler.ashx?", "GetDate",
111 Views
no comments
/////////////////////////////////////////// //From the service.cs side// /////////////////////////////////////////// //Make sure u include these namespaces using System.Web.Script.Services; using System.Web.Script.Serialization; //Have the webservice class have this Attribute to allow ajax calls [System.Web.Script.Services.ScriptService]
33 Views
no comments
/* Google jquery CDN <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script> */ $.ajax( { type: "POST", contentType: "application/json; charset=utf-8", url: "services/FeedService.svc/ServiceMethod", data: '{"param1":"data1" , "param2":"data2"}', dataType: "json",
103 Views
no comments
//using System.Web.Security
FormsAuthentication.SignOut();
118 Views
no comments
//using System.Web.Security if (Membership.ValidateUser(username, password)) { //Log in user. FormsAuthentication.SetAuthCookie(username, true); } else { //Handle user not exist code.
120 Views
no comments
#include <SDL/SDL.h> #include <stdio.h> using namespace std; void func_callback(void *unused, Uint8 *stream, int len) { for (int i=0;i<len;i++) { stream[i] = i; }
160 Views
no comments
private IEnumerable<MemberInfo> GetImportMembers(Type type) { var local = new HashSet<string>(); if (type.IsAbstract) { yield break; } foreach (var member in GetDeclaredOnlyImportMembers(type)) {
335 Views
no comments
Subscribe
Discuss
What's new
What is it
New Snippet
Recent Snippets
My Snippets
Web Code
Search
