I want one of the page adding editors on site to have a preview buttons associated with it. When user clicks preview the content gets saved and if the save is successful a page preview window is launched. The problem here is that the preview windows is blocked by browser's pop-up blocker. What can I make to "fool" the browser ?
I was t...
I am trying to set the default value for a form field in SharePoint and am having a bit of trouble getting the code to work in IE. I have tested Firefox and Chrome successfully. Any ideas why IE would not be setting the value?
<script type="text/javascript" src="http://www.qg.com/shared/cache/jquery/142/jquery-1.4.2.min.js"></sc...
Hey all, having an issue getting asp buttons to interact with JQuery. I'm basically trying to hide a div that contains a form and replace it with an processing image. It works fine for me when I use an HTML input button as the trigger but when I use an aspButton nothing happens.
This works (the id of the HTML button is 'btnSubmit'):
<s...
I was curious what that meant in general.
But here is the specifics..
I'm doing a sortable jquery project, that touches this rails action :
def update_order
params[:media].each_with_index do |id, index|
media = @organization.media.find(id)
media.do_not_touch = true
media.update_attribute('position', index+1)
end if par...
Is there a way to DRY this jQuery up?
<script type="text/javascript">
$('form input#search').watermark('search...');
</script>
<script type="text/javascript">
$('form input#post_title').watermark('title');
</script>
<script type="text/javascript">
$('form input#post_tag_list').watermark('tag (separate tags with a comma)');
</scrip...
I'm loading partial views which are ajax Forms.
They look like this
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<WebGRC.Web.Controllers.Models.Administration.UserAdminModel>" %>
<%@ Import Namespace="WebGRC.Web.Controllers.Models.User" %>
<h2><%=Html.Encode(ViewData["HeaderText"])%></h2>
<% Html.EnableClientValid...
I am using jqGrid. One of the columns has the possible values:
Poor, Fair, Good, Very Good, Excellent, Ideal
But when you sort by this column they are ordered alphabetically like:
Excellent, Fair, Good, Ideal, Poor, Very Good
Instead of the intuitive order you would expect.
Is there a way to correct this?
update
Here is a snippe...
Hi Everyone
I am writing a code using Google-Ajax-Feed-API to get latest feeds from some site. I want the feeds to be checked for update every(say 1 secs?). I am able to retrieve the blogs but not able to refresh the DIV tags. Any help will be useful.
<script type="text/javascript">
google.load("feeds", "1");
$(documen...
I am just trying to test a simple ajax call on my server using jquery
I have a HTML file like this
<!doctype html>
<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript">
$(function(){
$("#connect_button").click(function(event){
$("#placeholder...
I'm having an issue with my jquery script... should an easy task, but having some strange behaviours that I can't figure out.
When I click on a link, I want my content to disappear, then the new content to reappear. All content is stored in tags.
Here's what I'm using:
$("#events_link").click(function() {
$("#content").children("....
How to create tabs corresponding to the main vertical menu....
Say I have a vertical menu
submenu 1 submenu2 submenu3
Menu 1
Menu 2
Menu 3
ect .
Now on clicking i need to show the submenu in tabs as above ...and each time I click previous submenu will disappear and new will appear in the same place
...
$(document).ready(
function()
{
$('input[id^="btnRemoveCategory"]').bind(
'click',
function(){
if($('input[id^="chkIsBottom_":checked]'))
alert('YES YES YES!!!!');
else
alert('No NO no!!!!!');
I've tried with the:
if($('input[id^="chkIsBottom_"]').attr(chec...
I am new to jQuery and i came across a select box population code which work perfectly in Firefox,chrome, opera but not in IE.
In this code the first select will be populate the directory structure and as user select the select box the second select box should be populated according to users choice. But in IE the second select box is not...
I've got a small issue with the .offset().top value in jQuery.
I'm making a drop down menu function that binds to my selector as follows:
$('.navButton').mouseenter(
function(){
var x = $(this).offset().left;
var y = $(this).offset().top;
var height = $(this).height();
var dList = $(this).find('.d...
My boss asked me to program a custom jQuery validation plugin. If <input /> tag has special attribute [needcheck], my plugin must determine the type of [needcheck] and check input data before submit.
For example:
<input name="email" type="text" needchek=”Email”/>
If value of <input /> tag has errors, plugin must show a promting ...
Hello all,
I have a page as follows:
<div id="warning_msg">
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Praesent aliquam, justo.
<span id="closeerrordiv" class="notify-close">×</span>
</div>
<div id="bigForm2">
Lots of content here
</div>
<div id="bigForm...">
</div>
<div id="footer">
</div>
<script type="text/ja...
Is it possible to use the JavaScript jQuery framework with the HTML5 <canvas> element? Or do I have to do it with plain JavaScript.
I'm just wondering, because I think I could save a lot of time with using jQuery, but I have no clue about the <canvas> element's uses yet, so it may be completely impossible!
Anyone know if I can use jQu...
I keep getting a 405 Method not allowed. The script is hosted on same port as server, using IIS.
<script>
function auth() {
var str= '{"Password":"Password","Username":"Username"}';
$.ajax({
type: "POST",
contentType: "application/json; charset=utf-8",
url: "http://127.0.0.1:8080/auth/authenticate",
data: s...
I was wondering if anyone knows of an efficient pattern for dynamically loading html. jQuery's load method allows a developer to load html into a specified element. I would like to insert the html before a certain element. For example
html
<div>
<div class ="child">
</div>
</div>
jQuery
jQuery('div.child').load('ex.html');
...
Is there a way that has better performance than the other when appending a new element to the dom with jQuery?
This is the way I usually do it:
$('<div class="foo">Hello World!</div>').appendTo($("#bar"));
But I've seen this quite a few times around :
$('<div/>').attr("class", "foo").text("Hello World!").appendTo($("#bar"));
I thi...