Given a string like:
"The dog has a long tail, and it is RED!"
What kind of JQUERY, JavaScript magic can be used to keep spaces to only 1 max?
Goal:
"The dog has a long tail, and it is RED!"
thanks
...
I am making a page with Jquery UI TABS.
In one of tabs I want to make pagination for comments.
I want such thing. When user clicks on the number of the page,
the data of the page , which is linked will load via ajax in the tab.
Here is my code
<script type="text/javascript">
$(function() {
$("#tabs").tabs();
});
$('#demo')...
I need a to create a slide show with previous and next buttons. So I found an example online. I tried implementing it but there is a part I dont understand: Cufon replacement. I dont know where to add the following code.
// Cufon title replacement
//Cufon.replace('#features .title')('h1')('h2')('#nav-main li a:not(#nav-main li d...
I want to animate a series of items in jquery 1.3, with each next item beginning halfway through the first animation. In otherwords, I want a half-queue effect. I attempted to use the below code, but it is not working. Does anyone have any ideas?
$("h3").click(function(){
$(".projectItem").each(function (i) {
if (i > 0...
I am trying to reproduce the lock function on posts on facebook with jquery and php/mysql.
Below is an image showing the different actions it does when clicked on.
I think you would do somehing like on hover, show a hidden div with a tooltip, on hover off remove it. On click event show another hidden div but somehow has to change the ...
Can't seem to get this to work -- my ajax tabs load fine ... but, the nested tabs are not working.
Before I post some code, I'm just wondering if this is possible or not.
thanks
...
I have an html file that I'd like to open and read from, but I'm not entirely sure how to do that... Basically, it's a fairly large file (big.html), and, in a separate file (titles.html), I have some jquery code that I'd like to use to find certain elements (namely, h2 tags) and get the inner text from those tags and write just that text...
I'm using the treetable plugin in my web app.
http://plugins.jquery.com/project/treeTable
I want to be able to perform an action when a specific expandable node is expanded.
I can determine which element is responsible for expanding the node. Its a span with class expander.
As far as I can tell the plugin doesnt have an event that i...
Offff dont understand why I get cufon.font is not a function error. I followed all the instructions at its website.
<script type="text/javascript" src="js/cufon-yui.js"></script>
<script type="text/javascript" src="js/Futura_Lt_BT_400.font.js"></script>
<script type="text/javascript">
$(document).ready(function()
{
Cufon.replace(...
Hi All,
I'm new to JQuery and so far I'm using prototype. But now I want to use JQuery and the thing is I done want to change my old code, which uses prototype
I installed jrails plugin also
my question is can i use
new Ajax.Updater etc.. kind of methods with JQuery (having the jrails plugin installed)
(it doesnt work for me)
BTW -...
I am looking to make a iPhone app for a simple anonymous discussion website I launched this week (blurba.com).
I would like it to be native, available for free download in the app store.
I am looking for the fastest, easiest way to do this.
I have been looking at these options.
1. Build a native app in Obj-C
2. Build with JQ tou...
i want to copy a content from one div when clicked and write it to other div:
But when doing this i lost the clicked content from first div:
$(img).click(function(){
var newdiv=this;
$(".second").html(newdiv);
});
i have two divs with class first and second. frist div having images.
why i lost the first div's content or the clic...
I have a ul that is draggable, and there are anchors in the li's that I want to deactivate during the drag so that they're not triggered once the draggable.stop() event triggers.
<ul class="draggable-list">
<li class="list-item"><a href="#">clickable child</a></li>
<li class="list-item"><a href="#">clickable child</a></li>
....
I'm trying to implement the jQuery Cookie plugin into my slide toggle script, but so far haven't been successful. Here's my code (without any cookie implementation):
jQuery:
$(document).ready(function() {
$('a.toggle').click(function() {
var id = $(this).attr('name');
$('#module' + id).slideToggle('fast');
$('a.toggle[name=...
I just saw a demo that had this jquery code to show and hide a dive on hover, can't this be done with just regualr css though? And if you can do it with css is there any advantage of doing it with javascript?
$('.comment').hover(function() {
$(this).children('.delete').show();
}, function() {
$(this).children('.delete').hide();
});...
Hi
I have a drop down list and would like to remove an option from it, given the text/value of that particular option. Is it possible using jQuery? Just like 'append' which adds an option to the drop down list, is there a function to remove an option?
I tried searching for it but all I got were examples where the entire set of options ...
Lets say I have two divs
How do I use .find to get div1's background image, than apply that background image to div2, and replace ".jpg" with "_highlighted.jpg" ?
var div2bg = $('.div1').find('div').attr('background-image'??)//how to assigned the background image as a variable?
$('.div2').css("background-image", "url(" + div2bg + ")")...
Are there any existing AJAX/Javascript Date picker widgets/libraries that also allow you to select a time range? That is, after picking a date, an existing UI pops-up/becomes available to select a time range for the same.
I'm looking for example of things like this. UI Libraries that offer some form of date picking, followed by a ste...
My site is using the jQuery tooltip plugin (http://jquery.bassistance.de/tooltip/demo/) and the blockui plugin.
I am applying the tooltips like this:
$(function() {
$("span.helptooltip").tooltip({
showURL: false,
showBody: " - "
});
});
That works like a charm everywhere except a DIV that is being shown using ...
Im trying to get two alpha-24 transparent .png files to crossfade into each other. I started this adventure by modifying a pretty decent little script (thanks to jqueryfordesigners.com):
// wrap as a jQuery plugin and pass jQuery in to our anoymous function
(function ($) {
$.fn.cross = function (options) {
retur...