Hello, I have code:
$('#head_menu a').click(function(){
currentPage = document.location.hash.split('#')[1];
});
<div id="head_menu">
<a href="#order"><div>make order</div></a>
<a href="#portfolio"><div>portfolie</div></a>
<a href="#contacts"><div>contacts</div></a>
<a href="#vacancies"><div>vacancies</div></a>
<...
Hi,
I have two divs and two buttons:
<div id="container">
<div id="items"></div>
</div>
<div id="up"></div>
<div id="down"></div>
How to continuously scroll '#items' until user releases the button?
I tried using jquery mousedown event and animate function but couldn't make it to work.
$("#up").mousedown(function(){
$("#items").an...
Hi all,
I'm using the jQuery plugin DataTables (http://www.datatables.net/) with the following initialization:
$('#reconcile_table').dataTable( {
'bSort' : true,
'bFilter' : true,
'bSortClasses' : false,
'iDisplayLength' : 200,
'bPaginate' : true,
'sPaginationType': 'full_numbers',
'bProcessing' : true,
'sDom' ...
I tried this to remove the adjacent li, but it doesn't work:
$(this).prev(".Removable").remove();
Edit: I only want to remove the immediate adjacent li if it has that class.
WHEN SELECTABLE IS CLICKED I WANT THE PREVIOUS REMOVABLE TO VANISH
<ul>
<li class="Removable"> <li>
<li class="Selectable"> <li>
<li class="Rem...
Hello, I can't call callback after animation ends. Here is my animation function:
function animate( parentElement, callback )
{
parentElement.animate({
"height" : "hide", "opacity" : 0.0
}, { duration : "slow"}, "linear", callback);
}
And here is calling it:
animate( $(this).parent(), function() { alert('...
I have a large report currently rendered as a regular HTML table. I'd like to be able to group columns together and expand/collapse them with a button.
This is a very common practice for rows but not so much for columns. I was wondering if anyone has any tips for doing it with columns.
My stack includes jquery so that's available to y...
Hi Guys
I'm developing an ASP.NET MVC app and I'm a bit curious if anyone can tell me if there's a better way than this to submit selected options with the rest of the form data?
var lstOption1 = $('#lstOption1 :selected').attr("optionId1");
var lstOption2= $('#lstOption2 :selected').attr("optionId2");
var formData = $(this).serialize...
What javascript effect/ui libraries are the best that also have Rails helpers and all that?
Which ones do you use. Seems like people use jQuery with either scriptaculous or yui for the interface elements... Is there anything that's particularly easy or best that's supported in a Rails gem or something similar that you recommend?
...
Hi,
I am migrating my js lib from prototype to jquery. However, I don't know how to replace the following code:
var utilityMethods = {
autoHide : function(element) {
//...
}
Element.addMethods('SPAN', utilityMethods);
Is there a jQuery equivalent for extending the DOM?
Thanks
...
I'm trying to make a draggable instance of FlowPlayer using jQuery, but I can't get any mouse events to work over the Flash object.
If wmode is 'opaque' or 'window' I only have mouse events working inside the flash object, whereas with wmode set to 'transparent' I get the mouse events in jQuery but not in the flash object...does anyone ...
hi guys,
This is my first time here so go easy with me. I am keen on mastering codeignter and jquery for web app dev. I have made progress but I am at a point I was hoping I would pick on your great minds over.
I have links where I click and they fill up a div with content and this works but I use the $.ajax({}); not get or post or loa...
Me again,
I have a question I would like to ask as a followup.
to submit a form using a link powered by jquery is what I am curious about. do I just bind a click event to the link in the live() event for eg and use a submit() added to the click?
God bless
...
In code below is function that converts slider class into slider control. It has function which is executed when "slide" event is raised.
$(function(){
$(".slider").slider({
value: 0,
min: 0,
max: 5,
step: 1,
slide: func...
Has anybody else experienced this? I get tons of JS errors surrounding the jquery markup, such as the following line of code, works in FF but generates an error "Object doesn't support this property or method" in IE.
$("input[type=text]").css("border","1px solid grey");
Chrome doesn't give me the same error, but it locks up when I per...
Hello,
Is there a way to Set Jquery's autocomplete Http submission method to POST instead of GET?
...
I Have to load a html file using jquery. When i referred google, i got the snippet
$("#feeds").load("feeds.html");
But I dont want to load the content of feed.html into feeds object. Instead I need to load that page entirely. How to load that page. Help me plz
...
Home.html
I have a left menu in which when visitor menu is clicked, it will load visitor.html in the div named 'rightcont'.
$(".rightcont").load("visitor.html");
Also when the students menu is clicked, it will load students.html on the div rightcont
$(".rightcont").load("students.html");
But by default i loaded welcome.html in th...
How can I write a javascript/jquery function that replaces text in the html document without affecting the markup, only the text content?
For instance if I want to replace the word "style" with "no style" here:
<tr>
<td style="width:300px">This TD has style</td>
<td style="width:300px">This TD has <span class="style100">style</span> to...
I inject html to div on the page (contains float div)
var text = "some text<div style='float:rigth'><a href='#'>foo</a></div>"
$("#taget").html(text);
After that users of Google Chrome and Safari cannot click at link "foo"
...
I need to create some kind of JS onclick that will run a php mail script that emails a page with broken content.
Would it be best to run a normal javascript onclick that calls a php file which is hidden, grabs the referring url and emails it?
I would also like a message confirming the click, then disable it.
Is there anything like thi...