jquery

unable to remove div inserted by jquery

hello guys, am trying to remove a div inserted by jquery onclick. for some reason its just not working i tried remove(); hide(); css(); empty(); they all are just not working.. so here's my js function function callme() { var content = '<div id="floating_box" class="fb">' 'sdfsdfsdfsdfsfsddsfsfsdfsdfsdfsfsdfsdfsdfsfsdfsd' '</div>'; jQu...

Why is this simple jQuery not working?

I have this jQuery get request: $.get($(this).attr("href"), { "searchExpression": "schroders" }, function (result) { // do stuff }, "html"); Which sends the get request to this Action Method: public PartialViewResult Tabs(string searchExpression) { return PartialView(new SearchViewModel { PagedFunds = _fundServi...

Help with jquery GET method

Hi guys, I'm very very new to this ... so, here's my newbie question :D What's wrong with my code snippet below? I'm not getting any response from that URL. It should return the result in plain text ... am I doing this wrongly? $.get('http://is.gd/api.php?longurl=http://www.google.com.my/', function(data) { ...

Clearing default contents of textbox on focus with jQuery

I have a loginbar that can be used to login to 2 different systems depending on what value a user chooses from a dropdown. And then, I provide default values to fill each textbox depending on which login is chosen by the user. However, to make things easier for the user by clearing the default contents when the textbox receives focus, an...

How can I blink with jQuery?

I would like to blink my menu text. I have this code, but it doesn't work with IE. (function($) { $.fn.blink = function(options) { var defaults = { delay:500 }; var options = $.extend(defaults, options); return this.each(function() { var obj = $(this); setInterval(function() { ...

How to capture user input into a field one letter at a time

We would like to mimic taking user input one letter at a time (intended for children). Assuming they are going to type "hello" we would want to capture all the letters separately. (e.g. you will show something like 5 underscores to show that they have to provide 5 inputs). Assuming they enter h e l d (i.e. the last letter is a mistake) ...

how to prevent to change selectbox value if i say no to confirm

Hello ALL, i m using a select box of country, when user select a country then add branch link appears and user add branches under that country, but when user want to change country then all branches regarding that country should be destryoed. before changing a country a confirm box appears and show warning..everything is working fine b...

jquery.append() Iframe IE Problem

Hi Perhaps this is a bug, but I cannot access an outer document from an iframe with jquery (IE7). here a very simple example: top document: <html> <head> </head> <body> <iframe src="test2.html" id="UserIFrame" name="UserIFrame"> </body> </html> and child iframe: <html> <head> <script type="text/javascript" src="styles/genevadesign...

how to create watermark effect using jquery in asp.net

I got this article for doing this but i found that this is not working as i have given multiple classes in same textbox. How to convert this to work with multiple classes. I dont know how to use selectors to work with. I am using it like this <div class="inbox3full"> <div class="threeinbg"><asp:TextBox ID="txtSortOrder" CssClass="t...

Javascript jQuery only shows Image element once in IE. FF works

I want to show a big Image when I press the small thumbnail. A simple Lightbox style script. When I press the grey transparent overlay area around the image, the CSS and image is removed from view. This code is stripped down. Maybe missed something needed... $(document).ready(function() { $(".lightBobo").click(function(e) { ...

How to send jQuery $.get so the Model Binder can bind a string to a parameter?

I'm having difficulty getting the Model Binder to work. I thought it was the jQuery, so I asked this question, but after further investigation, I can see that the jQuery is indeed sending the parameter to the server. That's the reason I'm asking a new question - this is no longer a jQuery issue, as I originally thought. Background: Wha...

Open SWF onclick in a DIV with Jquery

For each item in a JSON I create an URL with this code. $('<a>').attr('href',item.link + '?enablejsapi=1&version=3').text(item.title).addClass(domain.replace(/[^a-z]/ig,'_')).appendTo('#sample-feed-block'); How can I force this URL (all SWF) to open the link in a DIV? Should I add .click(function() ? Do you think I can call a Jscript...

Cloning in-memory image in JavaScript /jQuery

This is probably a really simple one but I couldn't find the answer. I have the following JavaScript/jQuery code where I am trying to create loading messages: // preload an image to use for dynamic loading icon whenever requested $(document).ready(function() { var loadingIcon = document.createElement('img'); loadingIcon.src = '...

regex taken from jQuery.validate email method doesn't work with my php script

Hi I have a form with jQuery.validate. It checks if typed email is correct using it's own method. What i would like to achieve is to use the regex from it with my server-side php input validation. The regex i'm talking about: /^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.( [a-z]|\d|[!#\$%&'...

Is it possible to read a PHP session using Javascript?

Hi all, I am using cakePHP 1.26. In a controller, I got a function which contains these lines of code: $this->Session->write('testing', $user); $this->Session->read('testing'); Now the system wrote a session and stored on the server. Is it possible to use Javascript or Jquery to read the session named 'testing' ? ...

Two jQuery Font Resizer Issues: No Worky in IE, and Cookie Fails Beyond Root

Here is my code: $(function() { var section = new Array('#content'); section = section.join(','); var fontcookieoptions = { expires: 10 }; var originalFontSize = $(section).css('font-size'); // call cookie class $.cookie("test"); // parse cookie into numerical data var savedFontSize = parseFloat($.cooki...

Jquery $.ajax fails in IE on cross domain calls

I am doing a cross domain request using $.ajax , it works on firefox and chrome but does not issue a call on IE 7,8. can anyone tell me whats wrong with the following?? I have used JSON, JSONP, left that method due to some custom restrictions Usin Allow-access-control-origin headers already on my site(without that chrome and firefox w...

e.preventdefault(); not working

Morning All, I'm having real trouble getting e.preventDefault(); to work. Here is my code $('#ListSnapshot a').live('click', function(e){ var url = $(this).attr('href') +' #WebPartWPQ2 .ms-listviewtable'; $('#ListSnapshot').load(url); e.preventDefault(); }); Could someone explain what I'm doing wrong, I can see the load ...

Hidden panel keeps on appearing when the page loads ...

Hello everyone... I have this div that is supposed to be hidden when the page loads and it would appear when clicking on a certain button. Although in the CSS class I added display:none to the class and in the JQuery I added ("$('.panel').hide()") the panel still appears when the page is loading, once the page loads it disappears ... A...

Using Jquery for multiple values?

I'm trying to display a reply form for each comment but I hide the form using Jquery and I was wondering how can I grab the comment id and add it to Jquery so it can hide each reply form and display the correct reply form correctly instead of displaying the wrong reply form? For example, form_show_hide1, form_show_hide2, form_show_hide3...