jquery

PHP & Javascript: Image file description properties (Summary tab)

Image files come with description properties like title, subject and keyword (summary tab). How do I "get" these properties in PHP? is there a function that allows me to the same in Javascript? ...

Passing parameters when submitting a form via jQuery in ASP.NET MVC

I'm trying to do a form submit to my controller through jQuery Ajax. The following code works for the most part, however, the ThreadId parameter does not get passed. If I call the controller directly without using jQuery, it gets passed, but when using jquery, I don't see the ThreadId after form.serialize(). WHat would be the easiest ...

Inserting HTML with jQuery document.ready

Hello. I'm a beginner at jQuery and I'm trying to insert a Facebook like button through the jQuery document.ready function. My external Javascript file (loaded after the jQuery script) has the following code: $(document).ready(function(){ if ($('#fb_btn').length) { var fb_code = ""; fb_code += "<iframe src=\"http://www.facebook.c...

Dynamically Create Widgets in DOM

I'm using jQuery mobile 1 alpha 1. To create a text input for instance in jQuery mobile you add to your HTML <div data-role='fieldcontain'> <label for='name'>Text Input:</label> <input type='text' name='name' id='name' value='' /> </div> Supposing you assign the above HTML code to a variable $textinput and type $("#someid").append($...

change div content based on three for elements

Hey guys, I'm new to jQuery/js and having a hard time figuring this out. There are two fields in a form of mine i want to do some calculations with, what i tried is this: jQuery.fn.calculateit = function(){ var one = $("#one").val(); var two = $("#two").val(); //total var total = one + two; $("#total").text(total)...

JQuery parentsUntil with element as variable not working as expected.

My problem is best explained with examples: This works: $(startContainer).parents().each(function(index, parentNode) { if (parentNode.isSameNode(commonContainer)) return false; console.log("start vert struc: " + parentNode.nodeName); }); While, this does not work: $(startContainer).parentsUntil(commonContainer).each(function...

$(selector).live('click', finction(){ }); acting as a double click, why?

Hello, I've been trying to tackle this problem for a day and half now and I can't seem to figure out this strange behavior. When I do that live.('click' fn) it behaves like a double click. Well no that's not the true, what happens is that if I click on it once it performs on action, then when I click on it again it files off the second ...

is it possible to send a HTML form that includes a submit button via JavaScript?

I need to send a file via HTTP Post (a form) to more than one destination via a single click. The form has a submit button <input type="submit" id="button1" name="submit" value="upload file"> The action attribute and various different hidden fields that are needed, are set via JavaScript. After button1 is clicked the file is sent t...

How to create a Proper JQuery Carousel Plugin

Hi, I have done a Customised carousel with my understanding. To develop a Product Carousel, I stucked with making this as an object oriented carousel. If you help me to re-edit my Jquery('Carousel_plugin.js') to like as ('should_be_like_this.js') then the codes would looks more structured. The requirment is to use below things: Please ...

jQuery button primary & secondary

I am using jQuery button in my project, I need to display primary button in orange color and secondary button in grey color; but for me both buttons are in the same color grey. I am using following code: $(function() { $( "button, input:submit").button({ icons: {primary:'ui-icon-gear',secondary:'ui-icon-triangle-1-s'} }); ...

Need a HTML form defined to pass a String back to my MVC app using jQuery ajax?

I have a /mysite/nameprocessor handler that I want to pass a string to using jQuery ajax: <a href="#"><c:out value="${name}"/></a> Do I need to wrap this inside a form and serialize the form like in Prototype, which I think would look something like this: <form action="/mysite/nameprocessor" method="post" onsubmit="new Ajax.Req...

Problems Rendering Remote Events using JSONP in FullCalendar

I'm trying to load a json events feed into the FullCalendar jQuery plugin, however, I don't understand how to pass the data into FullCalendar. The url is called, and the JSON object is available inside the eventHandler function. The code below attempts to pass the resulting data into a global variable (which, doesn't feel right), which ...

Force click event on input file or open choose file window

I have a form in my HTML with field. I'd like to show the file selection window when the user clicks somewhere else (for example, an image on other part of the screen). The reason I want to do this is that I have a form with many fields, posting to some action "x", and the file selection form on other part of screen, submiting to actio...

What can be the best Practice for a Rapid Web Application Development?

Hello friends, I am coming up with a web application which will be primarily based on PHP. I would like to know some of the best practices and technologies that I can make use of to come out with the app as fast as possible. My team will be working remotely, so I want to know the best ways of collaborating through web resources too. I'm ...

Javascript IDE that forces strict typing, semicolons, and validates code like JSLint (or: that adds the advantages of a compiler to Javascript)?

I'm looking for ways to make developing big server sided Javascript (I'm working with Node.js) projects a whole lot easier. Basically, the problems I'm facing with Javascript is that I'm not being warned when I make a syntax error, or when I mix different kinds of object types in the same arrays/variables etc. I was using haXe to solve...

Select element after .wrap()

Helo I use this code: cur = $('input:radio'); cur.wrap('<span class="customRadio"></span>'); what i must to do to acces the '.customRadio' element? I already tried: cur.parent('.customRadio') and $('.customRadio') ...

Need some help with jQuery AJAX request loading a PHP document into a DIV Container.

I need a little bit of help here. First off, I am not sure if i should use the .ajax function or the .load function. I want to grab a PHP file on the server and just load the page into a DIV container. How could i go about this? EDIT: Thankyou for the help. Now I am running into another problem. Here is the code i am using. ...

jQuery click being fired twice

Code: $(".box-collapse").live("click",function(){ if(updating()) return false; var b = $(this).parent().parent(); b.find(".album-div").stop(true,false).slideToggle(); $.ajax({ url: addNonce($(this).attr("href")), success:function(data){ c = b.attr("id"); var resp = $('<div />').htm...

Slide Down Animation with Jquery

Hello, I'm looking to have a slide down animation (popular on a lot of forms these days) with jquery. I have text injecting into a div. The text is fetched from a database. success: function(text, textS, xhr){ if(xhr.status){ if (text == "") { $("#resultsDiv").html(" "); } else { $("#resultsDiv").html(t...

dynamic element id with php and jquery

Ok this might be a bit confusing, but here goes. Let's say I have a a few select dropdowns on a page. <select id="filter" name="filter[]"> <option value="">-- Select Filter --</option> </select> <select id="load_choice" name="load_choice[]"> <option value="">-- Select Load_choice --</option> </select> ...