So, what i'm trying to do is adding a Javascript snippet in wordpress admin new post page, so that when i click a button it fills up the CONTENT textarea where the body of the post goes. Adding it is not a problem, i've already done this, but for some reason filling up the content field doesn't work.
The textarea from the wordpress admi...
Hi to all,
i have wrote today because i need some help with a simple function in jquery for modify the structure of an input [reCaptcha] and hide the image showed.
The code of the page(s) that contains the reCaptcha plugin is:
http://pastebin.com/Qahph2ZB
Is possible to make this in Jquery?
BEFORE -----------------------------------...
I have the following variable which contains the following string. I would like to remove both the <nobr> and the </nobr> and just leave what is inside.
alert(product_code);
produces
<nobr>209/00254/01</nobr>
How would I make a new variable that removes the <nobr> tags?
var product_code = $(this).html();
alert(product_code);...
My code has some divs that appear on the screen based on different actions. The divs have handles that make them draggable via the jquery ui.draggable code. I have the draggable ui stack option set, so that when you drag an item, it automatically moves to the front of all other draggable items.
The problem I am having is that I want a d...
I found this solution on here http://stackoverflow.com/questions/2782815/how-to-update-strongly-typed-html-dropdownlist-using-jquery and am trying to implement it, but something is bugged in it.
$(function() {
$('#cid').change(function() {
var selectedCompany = $(this).val();
var ddl = $("#foid");
$.post("/Ti...
I can't seem to get preventDefault() to work with the following code... The browser still wants to jump to the top of the page after a click. Any ideas on how to fix this?
$('#controls a').click(function(event){
event.preventDefault();
var r = $(this).attr('rel');
var c = $('#container').attr('class');
// Prevent redundant action...
When we use the method jQuery.Val( value ) over a DOM element to change its value.
shouldn't the element dispatch an event informing that its value has changed? -I though the event 'change' was going to be dispatched.
If it shouldn't why?
Live Demo
...
I have built autocomplete input box (but there is a problem with foucsout)
Watch this :
http://www.youtube.com/watch?v=IxlXWfJsSeM
Demo:
http://www.faressoft.org/autocomplete/
My HTML Code :
<div class="autoCompleteDiv">
<input type="text" value="" size="60" name="countryName" id="countryName" class="autocomplete">
<ul class=...
I wrote a small plugin to handle text-to-input-to-text fields for on-the-fly editing, and it includes arguments that allow a user to run functions at different intervals of the process.
I want the user to be able to click the "actuator" (the element that controls the process), and choose to have an intervening function run after the but...
I'm trying to show a second select element only if a certain option of a first one is selected.
Should be straight forward but it doesn't work.
So I have a few of select elements of class "one" each followed by a select o class "two".
Within document ready function I first hide all of the selects of class "two": $('.two').hide(); works...
My webserver returns an json response to any ajax request no matter what. If the response was a success, it returns the json with the status code of 200. If there was something wrong, it'll return the json with a status code of 400 or 500. I need to get that information, even if the request is a 400 or 500 because the json response has t...
I have a page with a bunch of thumbnails. I use DIV with background images for the thumbnails. When I hover, I have a jQuery script that animates the DIV to expand the div to the full width of the images. The expansion is in all direction, it expands from the center with some margin and top/left positioning.
Problem is: if I hover on ...
So I have a site with a dozen pages on it using Drupal as a CMS. Wanted to know how to set/append all href links on any page with a dynamic attribute?
so here is an example URL:
http://www.site.com/?q=node/4
and I wanted to append to the URL like so:
http://www.site.com/?q=node/4&attr=1234
Now I have a nav bar on the site and ...
I have a jQuery dialog defined as follows
<div id="emaildialog" title="Contact Us">
<!-- Html.RenderPartial("ContactUs"); -->
<div>This is a test</div>
</div>
<script type="text/javascript">
(function ($) {
// increase the default animation speed to exaggerate the effect
$.fx.speeds._default = 1000;
...
Hello,
I have this code to popup a JQuery dialog box:
$( "#dialogBox" ).dialog({
height: 585,
width: 620,
modal: true,
resizable: false,
show: {
effect: 'fold',
complete: function() { $("#txtEmail").focus(); }
}
});
The dialog box appears correctly except for the eff...
Hi,
i would just like to know if the way i am doing (parsing xml data) is correct.
From web service (hosted on sharepoint 2007) i retrive xml data. Web service does not retrive any parameters, just returns data. Now I'm using jQuery .ajax() function to go throu this data and output it.
XML is very deep inside (7 levels)
Just an exa...
I have the following bean method signatures:
public String foo();
public List<String> getList(String bar);
public String getName(String baz);
The following works for me:
$("#div_id").append('<%= beanId.foo() %>');
The following is what I would like to do, but is a little more complex though, and I can't get it to work.
var...
<script type="text/javascript">
$(function() {
$("#resizable").resizable().draggable();
$('#resizable').append('<iframe id="rte" width="100%" height="100%" ></iframe>');
myeditor = document.getElementById("rte").contentWindow.document;
myeditor.designMode = "on";
$('#rte').bind('keypress', f...
Hello all,
I have worked quite a bit with jQuery and slidetoggle effects without coming across this bug before. The page is http://gilman.oomphdev.com, and the bug is when a user clicks the "What's This?" tag at the top of the page in IE7. Also, when one clicks the "Contribute Yours" link (right hand column, bottom-ish of white box) to ...
I am trying to set a cookie with a delayed amount of time.
I want the cookie to be set after 80 minutes on the page.
here is my code -
$(document).ready(function() {
// Set the cookie after 81 mins so the next visit has the button
$.cookie('EVGSalesLetter', 'visited').delay(4860000);
});
...