Search Results

Search found 23820 results on 953 pages for 'jquery ui autocomplete'.

Page 69/953 | < Previous Page | 65 66 67 68 69 70 71 72 73 74 75 76  | Next Page >

  • Using jQuery with form to eliminate spam

    - by Thierry-Dimitri Roy
    I have put a form on a web page where the user can send us data. Unfortunately, the webmaster does get a lot of spam through this form and the valid submissions gets buried. I have used captcha to bypass this problem. But I think that everyone would agree that captcha is a big annoyance to users. I switched to another solution: now the URL of the submit form points to null: <form id="sendDataForm" action="/null" method="post"> ... </form> And I bypass the form submission using jQuery excellent form plugin: $('#sendDataForm').ajaxForm({ url: '/ajax-data/' }); Since then, no spam has reached the webmaster, and valid comments gets through. The only drawbacks is that users without javascript cannot send us the form. But since this is on top of a javascript web application, we can safely assume that these are not valid users. My question is: in a world where 99% of users has javascript enabled (and a mechanism for those user could be build that uses captcha), why is this solution not more used? What drawback am I not seeing?

    Read the article

  • How to get unique value in jquery?

    - by jquerier
    I am learning jquery. I have following chunk of code in a html file: <table width="100%"> <tr> <td align='center'> <div> <a id='get_this' href='#'> <input type='hidden' id='id' value='1'><img src='images/1.gif'></a> </div> </td> <td align='center'> <div> <a id='get_this' href='#'> <input type='hidden' id='id' value='2'><img src='images/2.gif'></a> </div> </td> <td align='center'> <div> <a id='get_this' href='#'> <input type='hidden' id='id' value='3'><img src='images/3.gif'></a> </div> </td> </tr> What I want to do is, when I click any of the image, I can get the value, so that I can display the information. For example, I click the id=1, then I will display information on id1 in somewhere else. I tried this: $("a#get_this").click(function(){ var id = $('input[type=hidden]#id').val(); window.alert("You have chosen the id: " + id); }); It always return id: 1 to me.

    Read the article

  • jquery select one class from many

    - by simnom
    Hi, I'm trying to achieve the following functionality. Within a form I have multiple fields with the class name .inputField if one of these fields is selected then the div associated with that element should be shown on focus and hidden on blur. However, when I implement the code below on selecting the second element the class is applied to both. Not sure where I'm going wrong?!?!? html markup: <form class="friendlyForm" name="friendlyForm" id="friendlyForm"> <ul> <li> <label for="testField">Test field</label> <input name="testField" value="here" class="inputField" id="testField" /> <div class="helper" style="display: none;">helper text here</div> </li> <li> <label for="testField">Test field2</label> <input name="testField2" value="here" class="inputField" id="testField2" /> <div class="helper" style="display: none;">helper text here</div> </li> </ul> </form> jQuery markup: $('.friendlyForm').find('.inputField').each(function(i) { $(this).blur(); $(this).focus(function() { //Add the focus class and fadeIn the helper div $(this).parent().addClass('focus'); $(this).parent().parent().find('.helper').fadeIn(); }); $(this).blur(function () { //Remove the focus class and fadeOut helper div $(this).parent().removeClass('focus'); $(this).parent().parent().find('.helper').fadeOut(); }); }); Any pointers here would be greatly appreciated. Thanks

    Read the article

  • jQuery Mobile page overrides desktop HTML div layout

    - by batjko
    I'd like to use jQuery mobile on my desktop page. I'm probably thinking of this wrongly, but I tried simply inserting a page element into an existing standard div, like this: <body> <div id="left_sidebar"> [...] </div> <div id="mylist" data-role="page"> <div data-role="listview"> [list items bla bla] </div> </div> <div id="right_sidebar"> [...] </div> <div id="site_footer"> (c) bla blub </div> </body> ...hoping that only the middle part displays the "mobile" page elements. However, that page div seems to override the entire site and turns the whole body into a mobile page (albeit displaying my listview item nicely... across the entire screen). Any idea what to do? Advice is much appreciated.

    Read the article

  • how to add jquery live to lightbox v2?

    - by Mahmoud
    Hey all I am trying to create a page that well display a gallery image, when the user clicks on any images it inlarges using lightbox v2 now after that i adding on each image a button that well submit to jcart script which well add to cart, but when the user click on the button it refreshes. so i wanted to use jquery live to submit to jcart without closing the lightbox v2 but i still dont know how to do? code used inside lightbox title is <form class="jcart" method="post" action="" name = "add" > <input type="hidden" name="id" value="".$row['pro_num']."" /> <input type="hidden" name="name" value="".$row['pro_name']."" /> <input type="hidden" name="price" value="".$row['pro_price']."" /> <input type="hidden"name="qty" size = "1" value="1" /> <br /> <input type="image" value="Submit" name="addto" src = "images/add.png" /> </form>

    Read the article

  • jquery - index of click element on the list is different on IE 7

    - by surajz
    cms is generating content in this format. <ul id="slide_nav" class="tabs"> <a name="ctn2363_2465" id="ctn2363_2465" class="hidden"></a><li id="button_1"><a class="ohlord" href="javascript: void(0);" id="b1">Bookbag</a></li> <a name="ctn2363_2466" id="ctn2363_2466" class="hidden"></a><li id="button_2"><a class="ohlord" href="javascript: void(0);" id="b2">help</a></li> <a name="ctn2363_2467" id="ctn2363_2467" class="hidden"></a><li id="button_3"><a class="ohlord" href="javascript: void(0);" id="b3">Team</a></li> <a name="ctn2363_2468" id="ctn2363_2468" class="hidden"></a><li id="button_4"><a class="ohlord" href="javascript: void(0);" id="b4">At</a></li> </ul> To get a correct index of the clicked link I have to do this in IE 7 (use class info in selector) $("#slide_nav li a").click(function(){ var index = $("#slide_nav li > a.ohlord").index(this); }); On firefox $("#slide_nav li > a").index(this); works. On IE this produces incorrect index (0, 2, 4, 6 ..). Is there a way to get the correct index in IE 7 for the above html without using class information in the selector? My second question is $('#slides img')[index].attr('style', 'display: block;'); does not work. I have to iterate through each $('#slides img') elements to set the attribute. Isn't HTMLElement object returned from $('#slides img')[index] an jquery object?

    Read the article

  • jQuery .val() Selector Confusion

    - by Matt Dawdy
    I've kind of written myself into a corner, and was hoping there was an "easy" way out. I'm trying to loop through a series of things on my page, and build a key:value pair. Here is my structure: <div class="divMapTab" id="divMapTab34"> <div class="divFieldMap"> <select class="selSrc" id="selTargetnamex"><options....></select> </div> </div> <div class="divMapTab" id="divMapTab87"> <div class="divFieldMap"> <select class="selSrc" id="selTargetnamex"><options....></select> </div> </div> It's way more complicated than that, and there are many select elements inside of each divFieldMap div. Here is my JS function that is building my string: function Save() { var sSaveString = ''; $('.divMapTab').each(function() { var thisId = this.id; $('.selSrc', "#" + thisId).each(function() { var thisSubId = this.id; //alert(thisSubId); <-- HERE IS THE PROBLEM var sTargetCol = thisSubId.replace('selTarget', ''); var sValue = this.val(); sSaveString += sTargetCol + '¸' + sValue + '·'; }); }); } On the line that has the alert box and the text "HERE IS THE PROBLEM" is that I'm trying to get the selected value of the "current" select input element, but the id of that element isn't unique (I thought it would be, but I screwed up). Is there a good way, inside of an "each" type of jQuery statement, to use "this" to get the exact select element that I really am looking for, even if it doesn't have a unique id?

    Read the article

  • jquery .animate - image gets cropped during animation

    - by stef
    Hello all, I am currently programming a carousel with javascript using the jquery library. Basically, there are three images shown, the central image being bigger than the two others. Upon going left or right, the central images is resized from 115px*115px to 50px*50px and tossed left or right, depending on the user input. The problem is that when the resize happens, the central image gets gradually cropped until it reaches the 50px*50px and then return to a more normal state: http://www.filedropper.com/imggetscropped Javascript is as follow: $("div#carousel .item:eq(2)").animate({'width':'50px', 'height':'50px', 'opacity':'0.5'}, {queue:false, duration:900}); $("div#carousel .item:eq(2) img").animate({'width':'50px', 'height':'50px', 'marginTop': '30px'}, {queue:false, duration:900}); $("div#carousel .item:eq(1)").animate({'width':'115px', 'height':'115px', 'opacity':'1'}, {queue:false, duration:900}); $("div#carousel .item:eq(1) img").animate({'width':'115px', 'height':'115px', 'marginTop': '0px'}, {queue:false, duration:900}); $("div#carousel .item:not(eq(2))").animate({'left':'+=56px'}, {queue:false, duration:900}); $("div#carousel .item:eq(2)").animate({'left':'+=122px'}, {queue:false, duration:900, complete: carousel.toggleInput}); Images used are png with transparency.

    Read the article

  • jQuery not working as expected on HTTPS Internet explorer

    - by jat
    When I try to run my code on any other webbrowsers apart from the Internet explorer it works fine. But when I try to run the code on Internet explorer I do get an alert box saying HERE along with an Ok button. but the problem is when I click on that OK button I do not get anything. Ideally I should be getting another alert box. <!DOCTYPE html> <html> <head> <script src="js/jquery-1.4.2.min.js"></script> <script type="text/javascript"> $(document).ready(function(){ $("#submit").click(function(event) { alert("here"); $.post('process.php', {name:'test1',email:'test.com'}, function(data) { $('#results').html(data); alert(data); }); }); }); </script> </head> <body> <form name="myform" id="myform" action="" method="POST"> <label for="name" id="name_label">Name</label> <input type="text" name="name" id="name" size="30" value=""/> <br> <label for="email" id="email_label">Email</label> <input type="text" name="email" id="email" size="30" value=""/> <br> <input type="button" name="submit" id="submit" value="Submit"> </form> <div id="results"><div> </body> </html> Any help on this is very much appreciated. Edit: I found out that Internet Explorer which has HTTP works perfectly fine but not on Internet Explorer which uses HTTPS.

    Read the article

  • How do I cache jQuery selections?

    - by David
    I need to cache about 100 different selections for animating. The following is sample code. Is there a syntax problem in the second sample? If this isn't the way to cache selections, it's certainly the most popular on the interwebs. So, what am I missing? note: p in the $.path.bezier(p) below is a correctly declared object passed to jQuery.path.bezier (awesome animation library, by the way) This works $(document).ready(function() { animate1(); animate2(); }) function animate1() { $('#image1').animate({ path: new $.path.bezier(p) }, 3000); setTimeout("animate1()", 3000); } function animate2() { $('#image2').animate({ path: new $.path.bezier(p) }, 3000); setTimeout("animate2()", 3000); } This doesn't work var $one = $('#image1'); //problem with syntax here?? var $two = $('#image2'); $(document).ready(function() { animate1(); animate2(); }) function animate1() { $one.animate({ path: new $.path.bezier(p) }, 3000); setTimeout("animate1()", 3000); } function animate2() { $two.animate({ path: new $.path.bezier(p) }, 3000); setTimeout("animate2()", 3000); }

    Read the article

  • need help with jquery selectors

    - by photographer
    I've got code like that: <ul class="gallery_demo_unstyled"> <li class="active"><img src='001.jpg' /></li> <li><img src='002.jpg' /></li> <li><img src='003.jpg' /></li> <li><img src='004.jpg' /></li> <li><img src='005.jpg' /></li> <li><img src='006.jpg' /></li> </ul> <div class="Paginator"> <a href="../2/" class="Prev">&lt;&lt;</a> <a href="../1/">1</a> <a href="../2/">2</a> <span class="this-page">3</span> <a href="../4/">4</a> <a href="../5/">5</a> <a href="../4/" class="Next">&gt;&gt;</a> </div> <div class="Albums"><div class="AlbumsMenu"> <p><b>ALBUMS</b></p> <p><a href="../../blackandwhite/1/" >blackandwhite</a></p> <p><a href="../../color/1/" class='this-page'>>>color</a></p> <p><a href="../../film/1/" >film</a></p> <p><a href="../../digital/1/" >digital</a></p> <p><a href="../../portraits/1/" >portraits</a></p> </div></div> ...and some JavaScript/jQuery allowing to cycle through the images (the very top li elements) going back to the first image after the last one: $$.nextSelector = function(selector) { return $(selector).is(':last-child') ? $(selector).siblings(':first-child') : $(selector).next(); }; Current page is always 'this-page' class (span or p in my case, but I could change that if necessary). The question: what should I change in my code to make it go after the last image to the next page instead of cycling through the page over and over again, and after the last page to the next album? And to the first image on the first page of the first album after the last-last-last (or just stop there — don't really care)?

    Read the article

  • Thread Synchronization - UI thread and Worker thread

    This article describes how a Worker thread can take the control of the UI and can update the UI, created by the UI thread. This will be useful when a worker thread needs to update the UI in the mid of the background processing or on the completion without relying on UI thread to synchronize the work

    Read the article

  • jQuery Cycle plugin IE6/7 issues

    - by Aaron Moodie
    I've implemented a slideshow using the Cycle plugin, which is working in all browsers except IE6&7, where the images just show up in a list, and the #page_copy div is not hiding. I've been going through the code all day without any luck, and not exactly sure how or what I should be looking for. What would be the best way to go about debugging this issue? I know that the #page_copy div is hiding when I remove the rest of the code, and I've tried the reverse (which had no result) <script type="text/javascript" charset="utf-8"> jQuery.fn.fadeToggle = function(speed, easing, callback) { return this.animate({opacity: 'toggle'}, speed, easing, callback); }; $(document).ready(function() { $('#page_copy').hide(); $('a#info_close_button').click(function() { $('#page_copy').fadeOut(200); return false; }); $('a#info_button').click(function() { $('#page_copy').fadeToggle(200); return false; }); }); $(window).load(function() { // vertically center single image var $image_cnt = $("#images > img").size(); if($image_cnt < 2) { var $single_img = $("#images").children(':first-child'); var h = $single_img.height(); $single_img.css({ marginTop: (620 - h) / 2, }); $(".next").css("display","none"); $(".prev").css("display","none"); } }); // wait until images have loaded before starting cycle $(window).load(function() { // front image rotator $('#images').cycle({ fx: 'fade', speed: 300, next: '.next', prev: '.prev', containerResize: 0, timeout: 0, delay: -2000, before: onBefore }); }); // hide all but the first image when page loads $(document).ready(function() { $('#images img:gt(0)').hide(); }); // callback fired when each slide transition begins function onBefore(curr,next,opts) { var $slide = $(next); var w = $slide.width(); var h = $slide.height(); $slide.css({ marginTop: (620 - h) / 2, marginLeft: (650 - w) / 2 }); }; </script>

    Read the article

  • Jquery flowplayer - tabs - content inside div tags not displaying

    - by Gublooo
    Hey guys, I'm looking for a simple example of JQuery tabs in which I am planning to show two different forms. I came across this example http://flowplayer.org/tools/demos/tabs/index.htm which is perfect for my needs. So I implemented the simple example. The code in question is: <div class="panes" <divFirst tab content. Tab contents are called "panes"</div <divSecond tab content</div <divThird tab content</div </div Now my content for the first tab is a form which has several of its own div tags - when I put that form with div tags as the content for the first tab - nothing appears. So I made a simple change and added another div tag to the content of the first tab as shown below and still nothing appears: <div class="panes" <div<divFirst tab content. Tab contents are called "panes"</div</div <divSecond tab content</div <divThird tab content</div </div Is there a simple way to fix this. This is the content that I want to display in my first tab - Thanks for your help <div id="formbox" class="formbox" <form id="shopping_form" method="post" <div id="3" style="width:520px;" <textarea id="message" name="message" rows="3" cols="50"</textarea </div <div id="store_row" style="width:220px;float:left;padding-bottom:10px;"<bStore</b <input type="text" id="store" name="store" class="required" size="20" / <input type="hidden" id="store_id"/ </div <div id="city_column" style="width:200px;float:left;padding-bottom:10px;"<bCity</b <input type="text" id="city" name="city" size="15"/ </div <div id="findbutton_column" style="vertical-align:top;width:80px;float:left;" <input class="find_address" id="findaddress" type="button" value="Find Store"/ </div <div id="googlerow" style="width:120px;float:left;padding-bottom:10px;" <bSelect Store</b<select id="google_stores" name="google_stores"</select <input type="hidden" id="google_address"/ </div <div id="google_message" style="float:left;padding-bottom:10px;display:none;"</div <div id="locationrow" style="float:left;padding-bottom:10px;display:none;" <bAddress/Country</b <input type="text" id="address" name="address" size="20" / <input type="text" id="country" name="country" size="20"/ </div <div style="width:520px;float:left;padding-bottom:10px;" <bPrice    <input type="text" id="price" name="price" size="20" / </div <div id="buttonrow" style="width:200px;float:right;display:none;" <input id="it" type="image" src="http://images.pe.com.s3.amazonaws.com/it.png" height="35px"/ </div </form </div

    Read the article

  • Jquery Cycle Plugin Question - turning off relative links to photos so it goes to a URL

    - by alpdog14
    I am using Jquery Cycle Plugin and it has a side panel that highlights as the photos change and currently when I click on the text the associated photo pulls up then I have to click on the photo to go to the URL but I would like the text itself to link to the URL. I have looked at the fn.cycle.defaults but not sure what to change and I tried a few things but nothing works. If anyone can help me figure this out it would be most helpful. Here are the fn.cycle.defaults: fx: 'fade', // one of: fade, shuffle, zoom, scrollLeft, etc timeout: 4000, // milliseconds between slide transitions (0 to disable auto advance) continuous: 0, // true to start next transition immediately after current one completes speed: 1000, // speed of the transition (any valid fx speed value) speedIn: null, // speed of the 'in' transition speedOut: null, // speed of the 'out' transition next: null, // id of element to use as click trigger for next slide prev: null, // id of element to use as click trigger for previous slide prevNextClick: null, // callback fn for prev/next clicks: function(isNext, zeroBasedSlideIndex, slideElement) pager: null, // id of element to use as pager container pagerClick: null, // callback fn for pager clicks: function(zeroBasedSlideIndex, slideElement) pagerEvent: null, // event which drives the pager navigation pagerAnchorBuilder: null, // callback fn for building anchor links before: null, // transition callback (scope set to element to be shown) after: null, // transition callback (scope set to element that was shown) end: null, // callback invoked when the slideshow terminates (use with autostop or nowrap options) easing: null, // easing method for both in and out transitions easeIn: null, // easing for "in" transition easeOut: null, // easing for "out" transition shuffle: null, // coords for shuffle animation, ex: { top:15, left: 200 } animIn: null, // properties that define how the slide animates in animOut: null, // properties that define how the slide animates out cssBefore: null, // properties that define the initial state of the slide before transitioning in cssAfter: null, // properties that defined the state of the slide after transitioning out fxFn: null, // function used to control the transition height: 'auto', // container height startingSlide: 0, // zero-based index of the first slide to be displayed sync: 1, // true if in/out transitions should occur simultaneously random: 0, // true for random, false for sequence (not applicable to shuffle fx) fit: 0, // force slides to fit container pause: true, // true to enable "pause on hover" autostop: 0, // true to end slideshow after X transitions (where X == slide count) autostopCount: 0, // number of transitions (optionally used with autostop to define X) delay: 0, // additional delay (in ms) for first transition (hint: can be negative) slideExpr: null, // expression for selecting slides (if something other than all children is required) cleartype: 0, // true if clearType corrections should be applied (for IE) nowrap: 0 // true to prevent slideshow from wrapping }; I have tried changing the pageClick and pagerEvent but nothing seems to be working. Please help!!!

    Read the article

  • help with jquery ajax and templates in asp.net mvc

    - by NachoF
    So I have a complex form for an IncomeDeclaration. Its going to display a textfield GrossIncome for each Activity that the IncomeDeclaration is related to... this all gets done on the server and works just fine.... the problem is. The User should also be able to add Activities on the fly.. through javascript... so when the user clicks on Add Activity a Dropdown and a textfield must be appended to the bottom the activities list... heres what Ive got so far <tbody id="activities"> @Html.EditorFor(model => model.income.EconomicActivityIncomeDeclarations) </tbody> </table> <a href="#" id="add_activity">Agregar Otra Actividad</a> </fieldset> <script type="text/javascript"> $("#add_activity").click(function () { $.getJSON('/IncomeDeclarations/GetEconomicActivities', function (data) { var select = new Select(); var data = new Array(); for (var i = 0; i < data.length; i++) { var option = new Option(data[i]["name"], data[i]["i"]) //should do something here } //should call the template and append to #activities }); }); </script> <script id="template" type="text/x-jquery-tmpl"> <tr> <td><select name="income.EconomicActivityIncomeDeclarations[${SomeNumber}].EconomicActivityId"> ${MyOptions} </select></td> <td><input type="text" name="income.EconomicActivityIncomeDeclarations[${SomeNumber}].GrossIncome" /></td>> </tr> </script> } The name attribute for both the select and the text_field is key for this to work... otherwise modelbinding wont work... I would think that if the SomeNumber variable is set to new Date.GetTime() model Binding should work just fine... I actually dont see the need of ajax for this but thats another topic.. I just havent figured out a way to do this without ajax... right now I want to get the template to work and append the form elements to the bottom of the list.

    Read the article

  • jquery addresses and live method

    - by Jay
    //deep linking $.fn.ajaxAnim = function() { $(this).animW(); $(this).html('<div class="load-prog">loading...</div>'); } $("document").ready(function(){ contM = $('#main-content'); contS = $('#second-content'); $(contM).hide(); $(contM).addClass('hidden'); $(contS).hide(); $(contS).addClass('hidden'); function loadURL(URL) { //console.log("loadURL: " + URL); $.ajax({ url: URL, beforeSend: function(){$(contM).ajaxAnim();}, type: "POST", dataType: 'html', data: {post_loader: 1}, success: function(data){ $(contM).html(data); $('.post-content').initializeScroll(); } }); } // Event handlers $.address.init(function(event) { //console.log("init: " + $('[rel=address:' + event.value + ']').attr('href')); }).change(function(event) { evVal = event.value; if(evVal == '/'){return false;} else{ $.ajax({ url: $('[rel=address:' + evVal + ']').attr('href'), beforeSend: function(){$(contM).ajaxAnim();}, type: "POST", dataType: 'html', data: {post_loader: 1}, success: function(data){ $(contM).html(data); $('.post-content').initializeScroll(); }}); } //console.log("change"); }) $('.update-main a, a.update-main').live('click', function(){ loadURL($(this).attr('href')); return false; }); $(".update-second a, a.update-second").live('click', function() { var link = $(this); $.ajax({ url: link.attr("href"), beforeSend: function(){$(contS).ajaxAnim();}, type: "POST", dataType: 'html', data: {post_loader: 1}, success: function(data){ $(contS).html(data); $('.post-content').initializeScroll(); }}); return false; }); }); I'm using jquery addresses to update content while maintaining a useful url. When clicking on links in a main nav, the url is updated properly, but when links are loaded dynamically with ajax, the url address function breaks. I have made 'click' events live, allowing for content to be loaded via dynamically loaded links, but I can't seem to make the address event listener live, but this seems to be the only way to make this work. Is my syntax wrong if I change this : $.address.change(function(event) { to this: $.address.live('change', function(event) { or does the live method not work with this plugin?

    Read the article

  • capture data from FORM using jquery/ajax/json

    - by nisardotnet
    i have few textbox on the form and when the user submit i want to capture the data and insert into db here is what my code looks like beforeSubmit: function(data) { // called just before the form is submitted var item = $("[id$='item']"); var category = $("[id$='category']"); var record = $("[id$='record']"); var json = "{'ItemName':'" + escape(item.val()) + "','CategoryID':'" + category.val() + "','RecordID':'" + record.val() + "'}"; var ajaxPage = "DataProcessor.aspx?Save=1"; //this page is where data is to be retrieved and processed var options = { type: "POST", url: ajaxPage, data: json, contentType: "application/json;charset=utf-8", dataType: "json", async: false, success: function(response) { alert("success: " + response); }, error: function(msg) { alert("failed: " + msg); } }; //execute the ajax call and get a response var returnText = $.ajax(options).responseText; if (returnText == 1) { record.html(returnText); $("#divMsg").html("<font color=blue>Record saved successfully.</font>"); } else { record.html(returnText); $("#divMsg").html("<font color=red>Record not saved successfully.</font>"); } // $("#data").html("<font color=blue>Data sent to the server :</font> <br />" + $.param(data)); }, here is what is the Data sent to the server: if i uncomment this line: // $("#data").html("Data sent to the server : " + $.param(data)); _VIEWSTATE=%2FwEPDwULLTE4ODM1ODM4NDFkZOFEQfA7cHuTisEwOQmIaj1nYR23&_EVENTVALIDATION=%2FwEWDwLuksaHBgLniKOABAKV8o75BgLlosbxAgKUjpHvCALf9YLVCgLCtfnhAQKyqcC9BQL357nNAQLW9%2FeuDQKvpuq2CALyveCRDwKgoPWXDAKhwImNCwKiwImNC1%2Fq%2BmUXqcSuJ0z0F%2FQXKM3pH070&firstname=Nisar&surname=Khan&day_fi=12&month_fi=12&year_fi=1234&lastFour_fi=777&countryPrefix_fi=1&areaCode_fi=555-555&phoneNumber_fi=5555&email_fi=nisardotnet%40gmail.com&username=nisarkhan&password=123456&retypePassword=123456 DataProcessor.aspx.cs: public partial class DataProcessor : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) ProcessAjaxRequest(); } private void ProcessAjaxRequest() { if (Request.ContentType.Contains("json") && Request.QueryString["Save"] != null) SaveMyData(); } private void SaveMyData() { //data passed in as JSON format System.IO.StreamReader sr = new System.IO.StreamReader(Request.InputStream); string line = ""; line = sr.ReadToEnd(); //This is all you need to parse JSON string into an JObject. //Require namespace Newtonsoft.Json.Linq; JObject jo = JObject.Parse(line); Console.WriteLine((string)jo["RecordID"]); Console.WriteLine(Server.UrlDecode((string)jo["ItemName"])); //use Server.UrlDecode to reverse the text that was escaped before it was passed in to its original state Response.Write((string)jo["CategoryID"]); //this send to responseText of .ajax(options).responseText } } the above code is not working and i need a way to capture the values before i insert into db. any help? Thanks.

    Read the article

  • iTunes UI artifacts

    - by beefon
    Hello! 2 days ago I found out that iTunes interface become buggy. Here are some screenshots: UI bugs in listview headers: iTunes doesn't download app icons in App Store: CoverFlow doesn't show album arts: Finder and other apps are working well, without any artifacts. Macbook 062 (Intel C2D 2.13, GMA950), Mac OS X 10.6.2, iTunes 9.0.2. I have reinstalled iTunes via Apple's site - nothing. What do you advice to do?

    Read the article

  • Jquery Cycle issue or css issue in Chrome/Safari for Mac

    - by Mark
    Hi i have used the jquery cycle plugin to create multiple simple sliding galleries. In Chrome/Safair on Mac the browser is not loading the images. Here is the link the js i am using is here, although it could be a css issue..? I am struggling to find the real problem. $(document).ready(function() { $('.slides').each(function() { var $this = $(this), $ss = $this.closest('.slideshow'); var prev = $ss.find('a.prev'), next = $ss.find('a.next'); $this.cycle({ prev: prev, next: next, fx: 'scrollLeft', speed: 'fast', timeout: 0 }); }); }); CSS .slideshow { width:476px; height:287px; float:left; margin-right:30px; position:relative; z-index:0; margin-bottom:20px; } .slides { position:absolute; top:0; left:0; z-index:1; } a.prev { display:block; width:23px; height:22px; background:red; position:absolute; z-index:1000; background: url(../images/next_prev.png) no-repeat 0 0; top:133px; left:-11px; } a.next { display:block; width:23px; height:22px; background:red; position:absolute; z-index:1000; background: url(../images/next_prev.png) no-repeat -23px 0; top:133px; right:-11px; } Markup: <div class="slideshow"> <div class="slides"> <img src="images/chief_st_1.jpg" alt="CHIEF stationery + literature" /> <img src="images/chief_st_3.jpg" alt="CHIEF stationery + literature" /> <img src="images/chief_st_2.jpg" alt="CHIEF stationery + literature" /> </div> <a class="prev" href="#"></a> <a class="next" href="#"></a> </div> Any help would be appreciated. thanks

    Read the article

  • DOM Elements with same id and jQuery

    - by Steve
    Hi I have multiple elements with the same structure in my application. Second div element's id varies as per the comment id in the db which is unique. There are elements with the id 'vote_up' and 'vote_down'. This gets repeated for each comment.What happens is that, as I mentioned, there are multiple comments. I want to perform an Ajax request. First of this structure functions properly using ajax, but the rest does an http request. Btw I am developing a rails application and I am using jQuery. <div id="post_comment"> john<i> says </i> Comment<br/> <div id="comment_10_div"> **<form action="/comments/vote_up" id="vote_up" method="post">** <div style="margin:0;padding:0;display:inline"> <input name="authenticity_token" type="hidden" value="w873BgYHLxQmadUalzMRUC+1ql4AtP3U7f78dT8x9ho=" /> </div> <input id="Comment_place_id" name="Comment[post_id]" type="hidden" value="3" /> <input id="Comment_id" name="Comment[id]" type="hidden" value="10" /> <input id="Comment_user_id" name="Comment[user_id]" type="hidden" value="2" /> <input name="commit" type="submit" value="Vote up" /> </form> <label id="comment_10">10</label> **<form action="/comments/vote_down" id="vote_down" method="post">** <div style="margin:0;padding:0;display:inline"> <input name="authenticity_token" type="hidden" value="w873BgYHLxQmadUalzMRUC+1ql4AtP3U7f78dT8x9ho=" /> </div> <input id="Comment_place_id" name="Comment[place_id]" type="hidden" value="3" /> <input id="Comment_id" name="Comment[id]" type="hidden" value="10" /> <input id="Comment_user_id" name="Comment[user_id]" type="hidden" value="2" /> <input name="commit" type="submit" value="Vote Down" /> </form> </div> Can you please help me to solve this Thanks

    Read the article

  • not able to get a processed list in jquery variable

    - by Pradyut Bhattacharya
    I have html list <ol id="newlist"> <li>Test <ol> <li>1</li> <li>2</li> <li>3</li> </ol> </li> <li>Another test <ol> <li>1</li> </ol> </li> <li>Cool Test <ol> <li>1</li> <li>2</li> </ol> </li> </ol> Now i have hidden the list using the css... #newlist li { display:none; list-style: none; } I want to display the list and the only the descendants which have greater than 1 descendants... the output should be... Test 1 2 3 Another test Cool Test 1 2 I have used jquery and able to get the output... the code i used... $("ol#newlist > li").show(); for (var i = 0; i < $("ol#newlist > li").length; i++) { if ($("ol#newlist > li:eq(" + i + ") ol > li").length > 1) $("ol#newlist > li:eq(" + i + ") ol > li").show(); } the sample page here Now i want all the list in a single variable like i can get the lis in a variable... var $li = $("ol#newlist > li"); but the code $li.add($("ol#newlist > li:eq(" + i + ") ol > li")); is not working... the sample page here Please help... Thanks Pradyut India

    Read the article

  • incremental OL using letters (jQuery)

    - by jquery n00b
    Hi, I'm trying to dynamically add a span to an ol, where the counter should be in letters. eg: A result B result C result etc etc I've got this code which is great for using numbers but I've no idea what to do to it to make the numbers into letters jQuery(document).ready( function() { jQuery('.results ol').each(function () { jQuery(this).find('li').each(function (i) { i = i+1; jQuery(this).prepend('<span class="marker">' + i + '</span>'); }); }); }); Any help is greatly appreciated!

    Read the article

  • passing data from a client form via jquery ajax dinamicly

    - by quantum62
    i wanna insert specification of members that enter in textboxs of form in the database .i do this operation with jquery ajax when i call webmetod with static value the operation do successfully.for example this code is ok. $.ajax({ type: "POST", url:"MethodInvokeWithJQuery.aspx/executeinsert", data: '{ "username": "user1", "name":"john","family":"michael","password":"123456","email": "[email protected]", "tel": "123456", "codemeli": "123" }', contentType: "application/json; charset=utf-8", dataType: "json", async: true, cache: false, success: function (msg) { $('#myDiv2').text(msg.d); }, error: function (x, e) { alert("The call to the server side failed. " + x.responseText); } } ); but when i wanna use of values that enter in textboxes dynamically error occur.whats problem?i try this two code <script type="text/javascript"> $(document).ready( function () { $("#Button1").click( function () { var username, family, name, email, tel, codemeli, password; username = $('#<%=TextBox1.ClientID%>').val(); name = $('#<%=TextBox2.ClientID%>').val(); family = $('#<%=TextBox3.ClientID%>').val(); password = $('#<%=TextBox4.ClientID%>').val(); email = $('#<%=TextBox5.ClientID%>').val(); tel = $('#<%=TextBox6.ClientID%>').val(); codemeli = $('#<%=TextBox7.ClientID%>').val(); $.ajax( { type: "POST", url: "WebApplication20.aspx/executeinsert", data: "{'username':'username','name':name, 'family':family,'password':password, 'email':email,'tel':tel, 'codemeli':codemeli}", contentType: "application/json;charset=utf-8", dataType: "json", async: true, cache: false, success: function(msg) { alert(msg); }, error: function (x, e) { alert("The call to the server side failed. " + x.responseText); } } ); } ) }) </script> or $(document).ready( function () { $("#Button1").click( function () { var username, family, name, email, tel, codemeli, password; username = $('#<%=TextBox1.ClientID%>').val(); name = $('#<%=TextBox2.ClientID%>').val(); family = $('#<%=TextBox3.ClientID%>').val(); password = $('#<%=TextBox4.ClientID%>').val(); email = $('#<%=TextBox5.ClientID%>').val(); tel = $('#<%=TextBox6.ClientID%>').val(); codemeli = $('#<%=TextBox7.ClientID%>').val(); $.ajax( { type: "POST", url: "WebApplication20.aspx/executeinsert", data: '{"username" : '+username+', "name": '+name+', "family": '+family+', "password": '+password+', "email": '+email+', "tel": '+tel+' , "codemeli": '+codemeli+'}', contentType: "application/json;charset=utf-8", dataType: "json", async: true, cache: false, success: function(msg) { alert(msg); }, error: function (x, e) { alert("The call to the server side failed. " + x.responseText); } } ); } ) })

    Read the article

  • Jquery hover with animation

    - by Brian
    anyone know how to stop a .hover happening again before the mouseout animation has finished? I have the following code which has 4 anchors. Once hovered over the anchor the related anchor slides in using animation. My problem is you hover out and in quickly, before the square has been set back to 0px it increases the slide distance. <body class="home"> <div id="container"> <a class="page-link homet" id="anim-1"></a> <a class="page-link about" id="anim-2"></a> <a class="page-link portfolio" id="anim-3"></a> <a class="page-link contacts" id="anim-4"></a> <div id="header"> <div id="logo"> </div> <ul id="navigation"> <li><a id="1"></a></li> <li><a id="2"></a></li> <li><a id="3"></a></li> <li><a id="4"></a></li> </ul> </div> <div id="main"> <div id="left-content"> </div> <div id="main-content"> </div> </div> </div> </body> </html> Jquery var cc = { displayAnim : function () { actionLink = $("#container #header #navigation li a"); movePosition = "0"; $("#container a.page-link").css({ position:"absolute", right: 0}); $(actionLink).hoverIntent( function() { circleToReveal = $(this).attr('id'); switch (circleToReveal) { case "1" : movePostion = "386" break; case "2" : moveposition = "514" break; case "3" : movePosition = "643" break; case "4" : movePosition = "400" break; default : movePosition = "772" }; /* console.log(movePosition); */ $("#container #anim-" +circleToReveal+ "").stop().animate({"right": "+="+ movePosition +"px"}, "slow"); }, function() { $("#container #anim-" +circleToReveal+ "").stop().animate({"right": "-="+ movePosition +"px"}, "slow"); } ); } }; $(window).load (function () { $("body").addClass('js'); $("a.pagelink").hide(); cc.displayAnim(); });

    Read the article

< Previous Page | 65 66 67 68 69 70 71 72 73 74 75 76  | Next Page >