jquery

AJAX AND JSON within Codeigniter

Hello, I have a website where I am wanting to get some query results through AJAX and JSON, but I have absolutely no idea how to do it, I have this function, public function category() { $table = $this->uri->segment(2); $content_id = $this->uri->segment(3); $data['content'] = $this->site_model->get_content($tabl...

JQuery Help Needed for ID order given N Rows

Hi. I am trying to add a function that, when a user clicks "remove", 1) updates the numbers in the left-most column 2) updates the id order 3) updates the alternating color scheme I need help with 1) I am able to update the number row but it currently updates for all rows, even if there isn't anything there. Can somebody show me ho...

jCarouselLite reset autoscroll interval

How can I reset the auto-scroll interval on my jCarouselLite carousel after some event so that it lets you look at the content for the full interval, regardless of how far along the timer was when you clicked next or previous? Right now, if I click next or previous after 9 seconds, it scrolls again after 1 second. In the jCarouselLite s...

Check user is logged in using Jquery

Hi there Wondering if anyone can assist.. I am adding some jquery to my site, but I want to restrict some actions dependant on whether a user is logged in or not. I am unsure of how to detect the session variable with Jquery.. My initial thought was to call my checkUser cfc using Jquery Ajax and then check how many rows where returned...

jQuery Validation on Success

Hey guys thanks in advance for all your help! I have this registration form which is then validated using "bassistance's" validate.js: $('#pForm').validate({ rules: { fname: "required",// simple rule, converted to {required:true} lname: "required", accType: "required", country: "required", email: {//...

Fluid CSS Grid structrue possible?

Short and simple version: I have a project where I need to define a DIV that will repeat horizontally and then wrap to the next row when out of space (tabular-like grid). I've seen mention of jQuery.GridLayout, but the demo/homepage is 404'd so I have no clue if this is what I'm looking for. Simply, I'm trying to achieve this: Div.ItemC...

Jquery - Find a select element inside a parent DIV

I have a parent Div : <div id="ctl00_MainContentAreaPlaceHolder_deliveryOpen" class="delivery_open" style="display: block;"> //Child select Element <select class="txtfield ckgcountry" id="ctl00_MainContentAreaPlaceHolder_DeliveryPersonalInformation_country" name="ctl00$MainContentAreaPlaceHolder$DeliveryPersonalInformation$country"> ...

jQuery Recursive Function

I'm trying to write a recursive jQuery statement that grabs some data and populates fields. However I don't want the next command to be executed until the current one is finished. I'm trying to do the below, however it doesn't seem to make it to the second run. Is there something I am doing wrong? I kick it off by doing: var arg = new...

Javascript or jQuery for Adding Style to Phrases on Page

I'm applying a style to a certain phrase on our website over and over again. Is there a way to search the page for instances of that phrase and apply that style automatically? Example: <div> This is what you get from <span class="comp">Company Name</span>. We do all kinds of things here at <span class="comp">Company Name</...

In JavaScript/jQuery, how to retrieve data that has spaces in its name?

I am retrieving JSON using jQuery's getJSON call. My problem is that some of the fields in the returned JSON have spaces in them. How do I retrieve these values from the JSON without changing the source data? See line marked "ERROR" below: $.getJSON(url, null, function(objData) { $.each(objData.data, function(i, item) { var zip ...

Extract all h6 tags from a TextArea using JavaScript

Here is what I'm looking to do. 1: Have a jQuery WYSIWYG editor that allows users to enter text 2: Have a box that displays extracted text from the WYSIWYG editor that is only viewable. The extracted text should be bulleted. Each bullet item should be anything that is contained in an tag in the WYSIWYG. Example: WYSIWYG editor would ...

How to cache a jquery Ajax request and parsing

I'm building an application that is an image gallery but with lots of images (it's for browsing archives of documents); basically the application does this: display an image display "previous" and "next" links left and right of the first image The previous and next links are retrieved from an XML file that lists all images in sequenc...

jQuery deep linking plugins (#hash navigation)

So far I've found Address (port of SWFaddress?) and BBQ. Which other plugins that provide this functionality exist, and which is better/standard? So far I've only built my own hackish #-reading scripts, but need something that can handle multiple variables, i.e. #user=bob&sortBy=rating. Any suggestions or opinions are welcome. Thanks!...

How to move an <option> up down in a <select>?

I'm using jQuery. ...

How to know the type of an jQuery object?

I need to detect whether it's a <option> or something else ...

JavaScript JQuery Ajax Issue: POST Works fine in Firefox, IE, Safari but not Chrome.

I'm new to JavaScript, and working on a hobby project with a few developers. We have a simple page that is used to submit requests to a database. I decided to try learning JQuery, and started implementing some AJAX functionality into this request page. It works fine in FireFox, IE and Safari, but for some odd reason, I can't get it to w...

how to handle AJAX session_out with jquery?

I think it's a common problem but I can't find any solution about this. For example: I'm building a AJAX Web system using Jquery(client js) and php(server side). All the ajax requests are sent to index.php, which checks if that session is valid or not. If the session is not valid, server side's php will output the login page; if the sess...

Is 42 a valid credit card number? jQuery validator thinks it is

We all know that 42 is the answer to everything, but it's news to me that it is a valid credit card number. Try entering '42' or '42176' into this jQuery Validation testing page and click OK. What's going on? I thought this was supposed to be the de-facto validation library. Even Microsoft is using it now, but it thinks '42' and '42176...

Need currently selected tab ID for jquery tabs

I know I can get the index of the currently selected tab but can I somehow get to the ID (the equivalent of the ui.panel.id if this were triggered by an tab event...but it's not) of the currently selected tab? I'd prefer not to use the index because ordering of the tabs might change. I prefer not to use the style markups as those may c...

What's the difference between these two selectors?

$(this).parents('table:first > tbody > tr') And $(this).parents('table:first').children('tbody').children('tr') ...