[jQuery] Re: need help with simple jQuery problem

2010-01-22 Thread Rory Bernstein
Thank you so much, Adriana. With the information you've given me, I
have fixed the problem. I am so grateful.

Best,
Rory


[jQuery] Re: need help with simple jQuery problem

2010-01-20 Thread Rory Bernstein
Hi Adriana,

Adriana, I am honored that you wrote in to help me; it is, or course,
your script I am trying to work with.

I do not understand what you are asking me to do; can you please give
more info/context? Are you saying that I am missing the lines of code
you put in your response? If so, where do I put the code?

I am truly a novice, as you see.

Thank you so much,
Rory

On Jan 20, 9:36 am, Adriana P  wrote:
> Hi Rory,
>
> You need only the expandAll() plug-in:
>
> $(function() {
>     $("#outer").expandAll({trigger: "span.expand", ref: "div.demo",
> showMethod: "slideDown", hideMethod: "slideUp", speed: 600});
>
> });
>
> Regards,
>
> Adriana
>
>
>
> Rory Bernstein wrote:
>
> > Hello,
>
> > I am a total jQuery novice, and I tried to use jQuery for a project
> > but I'm having trouble.
>
> >http://www.rorybernstein.com/stage/index2.html
>
> > When you click the blue "go ahead" link, it expands the hidden div,
> > revealing content. I want the effect to be a "slide" effect, as on
> > this sample page:
> >http://adipalaz.awardspace.com/experiments/jquery/expand.html
> > From these various examples, I want the "slideToggle effect -
> > slideToggle ("slow"), as shown in section 2 of the above link.
>
> > I cannot figure out what is wrong; my toggle link does work (it
> > expands the hidden div), but I do not know how to get it to "slide" at
> > the speed shown in the sample.
>
> > Any help would be appreciated.
> > Thanks,
> > Rory
>
> --
> View this message in 
> context:http://old.nabble.com/need-help-with-simple-jQuery-problem-tp27228125...
> Sent from the jQuery General Discussion mailing list archive at Nabble.com.


[jQuery] Re: Need help with a required field from radio selection

2010-01-11 Thread Jules
$("form").validate(
{
rules: {
legal_status_comment: {
required: function(element) {
return $
("[name=legal_status]:checked").attr("id") == "other_radio";
}
}
}
});

On Jan 12, 3:43 am, jeffself  wrote:
> I've got a form with a radio group called 'legal_status'. There are
> five radio buttons. The last one has an id='other_radio'. If this
> button is selected, I have a textarea field that gets displayed. The
> field has an id='legal_status_comment'. This textarea field is wrapped
> by a div with an id='other_text_area' that is hidden until the
> other_radio button is selected.
>
> How do I write the rule to make the 'legal_status_comment' field to be
> required if the 'other_radio' button has been selected?
>
> Thanks!


[jQuery] Re: Need help with a simple problem?

2010-01-07 Thread Šime Vidas
The click method has only one argument - the funcion that is going to
be executed on every mouseclick.

Also, you can use the show and hide methods as shortcuts for
manipulating the display property.

The toggles method toggles the display property between the states
"hide" and "show".

$('#top-bar-login li.current').hover(function() {
$(this).siblings("ul").show();
}, function() {
$(this).siblings("ul").hide();
});

$('#top-bar-login li.current').click(function() {
$(this).siblings("ul").toggle();
});

If you wanted to attach 2 or more functions to the click event, you
could use the toggle method (same name as the one above, but different
purpose)...

$('#top-bar-login li.current').toggle(function() {
$(this).siblings("ul").show();
}, function() {
$(this).siblings("ul").hide();
});

Now, the first click will execute the first function, second click =
second function, third click = first function again, and so on...


Re: [jQuery] Re: Need help learning

2010-01-06 Thread Mark Tank
Thank you, you have help out so much

On Jan 6, 2010, at 6:14 PM, Šime Vidas wrote:

> If you want to manipulate with the DIV inside the $.get function, you
> can declare a local variable and put the reference to DIV in it...
> 
> (function($) {
>$.fn.myPlugin = function() {
> 
>this.each(function() {
>alert(this.id);
> 
>var that = this;
> 
>$.get("return.php",function(data) {
>// now "this" is "that"
>alert(that.id);
>//do something with "this" & the
> "data"
>});
>});
>return this;
>};
> 
> })(jQuery);
> 
> 
> You don't have to call the variable "that", but it's a nice name,
> isn't it? :)



[jQuery] Re: Need help learning

2010-01-06 Thread Šime Vidas
If you want to manipulate with the DIV inside the $.get function, you
can declare a local variable and put the reference to DIV in it...

(function($) {
$.fn.myPlugin = function() {

this.each(function() {
alert(this.id);

var that = this;

$.get("return.php",function(data) {
// now "this" is "that"
alert(that.id);
//do something with "this" & the
"data"
});
});
return this;
};

})(jQuery);


You don't have to call the variable "that", but it's a nice name,
isn't it? :)


[jQuery] Re: Need help learning

2010-01-06 Thread Šime Vidas

this refers to different objects depending on where we are in the
code...

(function($) {
$.fn.myPlugin = function() {

// here "this" refers to the jQuery object on which the myPlugin
method was called upon

this.each(function() {

// here "this" refers to the matched elements in the jQuery object...
in your example, you matched every DIV element, so "this" refers to
each node in the DOM tree that has
type = ELEMENT_NODE
nodeName = "DIV"

alert(this.id)
$.get("return.php",function(data) {

// here "this" refers to the options object for the AJAX request
you may print it out with this code:

for (prop in this) {
$("div").append(prop + " = " + this[prop] + "");
}
alert(this.id);
//do something with "this" & the
"data"
});
});
return this;
};

})(jQuery);


[jQuery] Re: Need help with image slideshow effect

2009-12-18 Thread dec0y
Sorry for the double post, just forgot to add the code.


[jQuery] Re: Need help converting conventional code to jquery

2009-12-14 Thread Ibatex
Thats perfect, I think the eq(0) is what I was missing on my earlier
attempts

Much thanks, Leonardo!!

On Dec 14, 6:52 am, Leonardo K  wrote:
> function togglePassFail(radioName) {
>     var buttonGrp = document.getElementsByName(radioName);
>     var radioValue = $(buttonGrp).filter(':checked').val();
>     var detailDiv = $(buttonGrp).eq(0).parent().next();
>     if ( radioValue == 'p' ){
>         detailDiv.hide();
>     }else{
>         detailDiv.show();
>     }
>
> }
> On Sun, Dec 13, 2009 at 17:55, Ibatex  wrote:
> > Hi all, I'm new here and new to jquery in general.
>
> > Question is how can I do the following in jquery, I'd like to have
> > access to jqueries effects and animations.
>
> > function togglePassFail(radioName) {
> >        var buttonGrp = document.getElementsByName(radioName);
> >        var radioValue;
>
> >        // text input for related details are in a div thats the next
> > sibling
> > of the parent div of the radio buttons
> >        var detailDiv = buttonGrp[0].parentNode.nextSibling;
>
> >        // get value of selected radio button
> >        for (var i=0; i >                if (buttonGrp[i].checked == true) {
> >                        radioValue = buttonGrp[i].value;
> >                }
> >        }
>
> >        // hide if pass is selected, show otherwise
> >        detailDiv.style.display = (radioValue == 'p') ? 'none' : 'block';
> > }
>
> > Thanks ahead of time for any help.


[jQuery] Re: Need help with superfish dropdown menu

2009-12-11 Thread Yvan

I've made some progress on resolving this issue, and all I have left
to fix is the following:


> 2) When I mouseover the sublinks -- I'd like for the "Resources" link
> text to remain white (instead of turning blue)

> 4)  In IE -- the left edge of the subnav list doens't line up wih the
> left edge of the Resources button (like the way it displays in Firefox)

http://www.alliedcash.com/comparison/

Any help would be appreciated.

- Yvan


[jQuery] Re: NEED HELP::siblings isssue in jquery

2009-12-10 Thread Greg Tarnoff
Easier yet, give your UL an ID then
$('#myID li a').click(function() {

$('#myID li a').removeClass("bg");
   $(this).addClass("bg");
});

--Greg


[jQuery] Re: NEED HELP::siblings isssue in jquery

2009-12-10 Thread Scott Sauyet
On Dec 10, 1:56 am, Bideshi  wrote:
> i've a little issue related to siblings in jquery,
> i'm using sibling to deselect the previous selected link after
> clicking on the new link, but it's now working,
> please let me know where i'm missing.
> [ ... ]
>                 $("a").click(function(){
>                         $(this).toggleClass("bg");
>                         $(this).siblings("a").removeClass("bg");
>                 });
> [ ... ]
>     Link 1
>     Link 2

Your  tags aren't siblings; they're cousins.

Maybe something like this:

$("a").click(function(){
$(this).parents("ul").find("a").removeClass("bg");
$(this).addClass("bg");
});

Cheers,

  -- Scott


[jQuery] Re: Need help in jquery script for copying values

2009-12-04 Thread rose
Sorry to ask a silly question like this. I solved this . Here goes the
modified script :

  $('#addEmployee').click(function(){
$.ajax({
url: 'searchEmployee.do?method=searchEmployee',
type: 'GET',
data: {employeeId: $('input#emp').val()},
success: function(data) {
 if($('textarea#employee_id_textarea').val() ==""){
 $('textarea#employee_id_textarea').val(data) ;
}
else {
$('textarea#employee_id_textarea').val($
('textarea#employee_id_textarea').val() +"," +data);
}
$('div#resultEmp').html("").css("padding",0);
$('input#emp').val("");
}
});

Thanks,
Rose

On Dec 3, 1:14 pm, rose  wrote:
> Hi All,
> I have a below jquery function to search the employee data and show
> the result. i have a text box in which the user type in the empid and
> click on search. Once user clicks on search it shows the employee
> detail such as name, sex, race etc below the textbox.
>
> $('#addEmployee').click(function(){
>                 $.ajax({
>                         url: 'searchEmployee.do?method=searchEmployee',
>                         type: 'GET',
>                         data: {employeeId: $('input#emp').val()},
>                         success: function(data) {
>                                 $('div#resultEmp').css("padding","10px 0 10px 
> 0").html(data);
>                         }
>                 });
>         });
>
> Once i get the proper employee data such as empid, name, race etc. I
> have a href link for the empid . I click on the emp id link and i copy
> that employee id into the textarea i have right below the results.
> Now the user doesn't want to  click on the emp id to copy the value on
> the textarea. They just want if data from backend is correct directly
> copy to the textarea without clicking on empid(which i am showing as
> results after clicking search).
>
> To copy emp id  from the link to textarea i am calling another
> javascript as below :
>
> // Function for copying Employee Id to the textarea.
>
> function selectEmp(id) {
>         if($('textarea#employee_id_textarea').val() ==""){
>                 $('textarea#employee_id_textarea').val(id) ;
>         }
>         else {
>                 $('textarea#employee_id_textarea').val($
> ('textarea#employee_id_textarea').val() +"," +id);
>         }
>         $('div#resultEmp').html("").css("padding",0);
>         $('input#emp').val("");
>
> }
>
> Could you please advise how i can do that? After result success i want
> to copy the empid directly to the textarea without clicking. I don't
> even know if i have made myself clear. Please let me know if you need
> more information. Thanks in advance.


[jQuery] Re: need help with logic

2009-08-19 Thread Dhruva Sagar
It is of course possible, you have to simply redirect the user from the
server to the right page.
If in the the first scenario you have a page like 'search.php' and your form
is submitting the data to it, and your doing the search on server side and
displaying it on the same page, then in that case when you've moved the
search form to another page, you will need to make sure that the 'action'
attribute of this particular form still points to the 'search.php'.

If how your submitting data to the server and how you get it back and
display is different than that, then you will have to give a bit of details,
for example if your working in Ruby on Rails and your submitting the data to
the controller where your doing the actual search, then from there you can
easily redirect to the search action page...

Give a bit more details and I could help you more.

Thanks & Regards,
Dhruva Sagar.


Samuel Goldwyn
- "I'm willing to admit that I may not always be right, but I am never
wrong."

On Thu, Aug 20, 2009 at 6:07 AM, efet  wrote:

>
> I have search page. At this page, when user enters a value to the form
> field and clicks submit, the value is posted and server's results
> printed inside main div. Now, I want to add search form to main page
> and so when user enters a value to the form field and clicks submit,
> he is redirected to search page and the entered value is posted and
> server's results printed inside main div. Is this possible? If yes,
> how?


[jQuery] Re: Need help with table sorter

2009-08-01 Thread Adrian Lynch

If you can't or don't want to add a table footer, you can pass the
sorter a selector that excludes the last row. The last sorter I looked
at didn't allow you to pass the selector in so I had to modify the
source.

On Jul 31, 10:08 pm, aquaone  wrote:
> http://www.w3schools.com/tags/tag_tfoot.asp
>
> On Fri, Jul 31, 2009 at 07:36, Razor M  wrote:
>
> > Is it possible to do some changes so that the bottom row will not be
> > included while doing the sorting?
>
> > Suppose I have totals in the bottom row, so I do not want that row to
> > be
> > sorted while using the table sorter through jquery.
>
> > Please let me know if it can be done.


[jQuery] Re: Need help with table sorter

2009-07-31 Thread aquaone

http://www.w3schools.com/tags/tag_tfoot.asp

On Fri, Jul 31, 2009 at 07:36, Razor M  wrote:

>
> Is it possible to do some changes so that the bottom row will not be
> included while doing the sorting?
>
> Suppose I have totals in the bottom row, so I do not want that row to
> be
> sorted while using the table sorter through jquery.
>
> Please let me know if it can be done.
>


[jQuery] Re: Need help with a custom selector to bind ajax callbacks

2009-07-23 Thread Jules

Opps,

Sorry, didn't realise request and settings are not available on
ajaxSend and ajaxStop.  So, my proposed solution is not working.
May be a dumber solution

var isFaceBox = true;

$(document).ready(function(){
  $(document).ajaxSend(function(event){
if(!isFaceBox)
{
$('body > div.container').fadeTo('normal', 0.33);
$('#loading').show();
}
  });
  $(document).ajaxComplete(function(event){
if(!isFaceBox)
{
$('body > div.container').fadeTo('normal', 1);
$('#loading').hide();
}
  });

  $.ajax({

   //your call
beforeSend: function(){ isFaceBox = false;},
complete: function(){ isFaceBox = true;}
   });
});
On Jul 24, 10:02 am, Jules  wrote:
> Can't you check the settings.url?
>
> $(document).ready(function(){
>   $(document).ajaxSend(function(event, request, settings){
>     if(settings.url != 'faceboxurl') // replace faceboxurl with the
> real url
>     {
>     $('body > div.container').fadeTo('normal', 0.33);
>     $('#loading').show();
>     }
>   });
>   $(document).ajaxComplete(function(event, request, settings){
>     if(settings.url != 'faceboxurl') // replace faceboxurl with the
> real url
>     {
>     $('body > div.container').fadeTo('normal', 1);
>     $('#loading').hide();
>     }
>   });
>
> });
>
> On Jul 24, 6:05 am, Rodrigo Tassinari  wrote:
>
> > Anyone?
>
> > On 20 jul, 12:34, Rodrigo Tassinari de Oliveira
>
> >  wrote:
> > > Hello everyone,
>
> > > I'm stuck with an annoying problem in this webapp I'm developing.
>
> > > I've created a small code to be called automagically on every ajax
> > > request, which shows a "loading..." div overlay while the ajax request
> > > is being processed. This works fine, and the code used can be seen in
> > > this pastie:
>
> > >http://pastie.org/552179
>
> > > However, we also use the Facebox plugin (http://famspam.com/facebox/)
> > > in this app, and we don't want the "loading..." div overlay to show
> > > when a facebox ajax request is triggered (the example link trigger is
> > > also on the above pastie), since facebox has it's on "loading" thing.
>
> > > I can't seem to do that. I binding the ajaxSend and ajaxComplete
> > > callbacks to some css selector that would include everything except
> > > the facebox links (a[rel*=facebox]), instead of the current $
> > > (document) route, but I failed.
>
> > > Does anyone have any ideas to help me with this?
>
> > > Thanks a lot in advance,
> > > Rodrigo.


[jQuery] Re: Need help with a custom selector to bind ajax callbacks

2009-07-23 Thread Jules

Can't you check the settings.url?

$(document).ready(function(){
  $(document).ajaxSend(function(event, request, settings){
if(settings.url != 'faceboxurl') // replace faceboxurl with the
real url
{
$('body > div.container').fadeTo('normal', 0.33);
$('#loading').show();
}
  });
  $(document).ajaxComplete(function(event, request, settings){
if(settings.url != 'faceboxurl') // replace faceboxurl with the
real url
{
$('body > div.container').fadeTo('normal', 1);
$('#loading').hide();
}
  });
});


On Jul 24, 6:05 am, Rodrigo Tassinari  wrote:
> Anyone?
>
> On 20 jul, 12:34, Rodrigo Tassinari de Oliveira
>
>  wrote:
> > Hello everyone,
>
> > I'm stuck with an annoying problem in this webapp I'm developing.
>
> > I've created a small code to be called automagically on every ajax
> > request, which shows a "loading..." div overlay while the ajax request
> > is being processed. This works fine, and the code used can be seen in
> > this pastie:
>
> >http://pastie.org/552179
>
> > However, we also use the Facebox plugin (http://famspam.com/facebox/)
> > in this app, and we don't want the "loading..." div overlay to show
> > when a facebox ajax request is triggered (the example link trigger is
> > also on the above pastie), since facebox has it's on "loading" thing.
>
> > I can't seem to do that. I binding the ajaxSend and ajaxComplete
> > callbacks to some css selector that would include everything except
> > the facebox links (a[rel*=facebox]), instead of the current $
> > (document) route, but I failed.
>
> > Does anyone have any ideas to help me with this?
>
> > Thanks a lot in advance,
> > Rodrigo.


[jQuery] Re: Need help with a custom selector to bind ajax callbacks

2009-07-23 Thread Rodrigo Tassinari

Anyone?

On 20 jul, 12:34, Rodrigo Tassinari de Oliveira
 wrote:
> Hello everyone,
>
> I'm stuck with an annoying problem in this webapp I'm developing.
>
> I've created a small code to be called automagically on every ajax
> request, which shows a "loading..." div overlay while the ajax request
> is being processed. This works fine, and the code used can be seen in
> this pastie:
>
> http://pastie.org/552179
>
> However, we also use the Facebox plugin (http://famspam.com/facebox/)
> in this app, and we don't want the "loading..." div overlay to show
> when a facebox ajax request is triggered (the example link trigger is
> also on the above pastie), since facebox has it's on "loading" thing.
>
> I can't seem to do that. I binding the ajaxSend and ajaxComplete
> callbacks to some css selector that would include everything except
> the facebox links (a[rel*=facebox]), instead of the current $
> (document) route, but I failed.
>
> Does anyone have any ideas to help me with this?
>
> Thanks a lot in advance,
> Rodrigo.


[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-04 Thread Erik R. Peterson
Where am I placing the link for each tag?  Are the link identified in  
the JS or the html?


E


On Jul 4, 2009, at 10:18 AM, Charlie wrote:


I gave you slideUp twice...oops...bad copy paste

Erik R. Peterson wrote:


Thanks Charlie,

I'll put it in now.  thanks.

E


On Jul 4, 2009, at 9:56 AM, Charlie wrote:

could shorten this all up and make it accessible for javascript  
disabled by putting the url into the href of your links.


Haven't looked at plugin but since you're just loading html will  
use load() in jQuery core:


hideLoading();
$("#cs_links a").click(function () {
   showLoading();
$("#cst_wrap_mid").slideUp();
$("#cst_wrap_mid").load($(this).attr("href"), function(){
$("#cst_wrap_mid").slideUp();
 hideLoading();

});
return false;
});

This would replace all of the switch cases. If javascript disabled  
appropriate page would open from href. Likely find that load is  
very fast and showloading may not be necessary


Erik R. Peterson wrote:



Can;t get it to work correctly.

Here is my existing code:

$(document).ready(function(){
//References
var sections = $("#cs_links a");
var loading = $("#loading");
var content = $("#cst_wrap_mid");

//Manage click events
sections.click(function(){
//show the loading bar
showLoading();
//load selected section
switch(this.id){
case "js_appoint":
content.slideUp();
content.load("/externals/appoint.htm",  
hideLoading);

content.slideDown();
break;

case "js_contact":
content.slideUp();
content.load("/externals/contact.htm",  
hideLoading);

content.slideDown();
break;

case "js_gifts":
content.slideUp();
content.load("/externals/gifts.htm", hideLoading);
content.slideDown();
break;

case "js_order":
content.slideUp();
content.load("/externals/order.htm", hideLoading);
content.slideDown();
break;

case "js_promise":
content.slideUp();
content.load("/externals/promise.htm",  
hideLoading);

content.slideDown();
break;

case "js_quest":
content.slideUp();
content.load("/externals/quest.htm", hideLoading);
content.slideDown();
break;

case "js_returns":
content.slideUp();
content.load("/externals/returns.htm",  
hideLoading);

content.slideDown();
break;

case "js_secure":
content.slideUp();
content.load("/externals/secure.htm", hideLoading);
content.slideDown();
break;

case "js_shipping":
content.slideUp();
content.load("/externals/shipping.htm",  
hideLoading);

content.slideDown();
break;


case "js_terms":
content.slideUp();
content.load("/externals/terms.htm", hideLoading);
content.slideDown();
break;

case "js_types":
content.slideUp();
content.load("/externals/types.htm", hideLoading);
content.slideDown();
break;

default:
//hide loading bar if there is no selected section
hideLoading();
break;
}
});

//show loading bar
function showLoading(){
loading
.css({visibility:"visible"})
.css({opacity:"1"})
.css({display:"block"})
;
}
//hide loading bar
function hideLoading(){
loading.fadeTo(1000, 0);
};
});





On Jul 4, 2009, at 6:40 AM, MOZ wrote:



Hi,
on your page: http://www.enaturalskin.com/needhelp.htm
each time the window scroll to the top because of anchor #, use
preventDefault();  to avoid this, just a suggestion.

Also see the improved version: 
http://yensdesign.com/2009/06/safe-ajax-links-using-jquery/
This trick will make your website work though there is no  
javascript.


-Beschi.

On Jul 4, 4:14 am, "Erik R. Peterson"  wrote:

Hi buddy!

I'm undecided on the final buttons and graphics, but thanks to  
your

help I got the script down.

I actually fixed my own problem after posted this last email.

Have a great weekend.

Erik

On Jul 3, 2009, at 5:14 PM, Cesar Sanz wrote:




Hello.



I see you succed retrieving data using ajax,



Which is the problem?


- Original Message - From: "Erik R. Peterson"  



To: 
Sent: Friday, July 03, 2009 2:48 PM
Subject: [jQuery] Need help on How to load content via AJAX in  
jQuery



I found this script:
ht

[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-04 Thread Charlie





I gave you slideUp twice...oops...bad copy paste

Erik R. Peterson wrote:
Thanks
Charlie,
  
  
  I'll put it in now.  thanks.
  
  
  E
  
  
  
  
  On Jul 4, 2009, at 9:56 AM, Charlie wrote:
  
  
 could shorten this all up
and make it accessible for _javascript_ disabled by putting the url into
the href of your links.

Haven't looked at plugin but since you're just loading html will use
load() in jQuery core:

hideLoading(); 
$("#cs_links a").click(function () {
       showLoading();
        $("#cst_wrap_mid").slideUp();
        $("#cst_wrap_mid").load($(this).attr("href"), function(){      
       
                $("#cst_wrap_mid").slideUp();
             hideLoading(); 

            });
return false; 
});

This would replace all of the switch cases. If _javascript_ disabled
appropriate page would open from href. Likely find that load is very
fast and showloading may not be necessary

Erik R. Peterson wrote:

Can;t get it to work correctly. 
  
Here is my existing code: 
  
$(document).ready(function(){ 
//References 
var sections = $("#cs_links a"); 
var loading = $("#loading"); 
var content = $("#cst_wrap_mid"); 
 
//Manage click events 
sections.click(function(){ 
    //show the loading bar 
    showLoading(); 
    //load selected section 
    switch(this.id){ 
    case "js_appoint": 
    content.slideUp(); 
    content.load("/externals/appoint.htm", hideLoading); 
    content.slideDown(); 
    break; 
    
    case "js_contact": 
    content.slideUp(); 
    content.load("/externals/contact.htm", hideLoading); 
    content.slideDown(); 
    break; 
  
    case "js_gifts": 
    content.slideUp(); 
    content.load("/externals/gifts.htm", hideLoading); 
    content.slideDown(); 
    break; 
  
    case "js_order": 
    content.slideUp(); 
    content.load("/externals/order.htm", hideLoading); 
    content.slideDown(); 
    break; 
    
    case "js_promise": 
    content.slideUp(); 
    content.load("/externals/promise.htm", hideLoading); 
    content.slideDown(); 
    break; 
  
    case "js_quest": 
    content.slideUp(); 
    content.load("/externals/quest.htm", hideLoading); 
    content.slideDown(); 
    break; 
  
    case "js_returns": 
    content.slideUp(); 
    content.load("/externals/returns.htm", hideLoading); 
    content.slideDown(); 
    break; 
    
    case "js_secure": 
    content.slideUp(); 
    content.load("/externals/secure.htm", hideLoading); 
    content.slideDown(); 
    break; 
  
    case "js_shipping": 
    content.slideUp(); 
    content.load("/externals/shipping.htm", hideLoading); 
    content.slideDown(); 
    break; 
  
  
    case "js_terms": 
    content.slideUp(); 
    content.load("/externals/terms.htm", hideLoading); 
    content.slideDown(); 
    break; 
    
    case "js_types": 
    content.slideUp(); 
    content.load("/externals/types.htm", hideLoading); 
    content.slideDown(); 
    break;    
    
    default: 
    //hide loading bar if there is no selected section 
    hideLoading(); 
    break; 
    } 
}); 
  
//show loading bar 
function showLoading(){ 
    loading 
    .css({visibility:"visible"}) 
    .css({opacity:"1"}) 
    .css({display:"block"}) 
    ; 
} 
//hide loading bar 
function hideLoading(){ 
    loading.fadeTo(1000, 0); 
}; 
}); 
  
  
  
  
  
On Jul 4, 2009, at 6:40 AM, MOZ wrote: 
  
  
Hi, 
on your page: http://www.enaturalskin.com/needhelp.htm

each time the window scroll to the top because of anchor #, use 
preventDefault();  to avoid this, just a suggestion. 

Also see the improved version: http://yensdesign.com/2009/06/safe-ajax-links-using-jquery/

This trick will make your website work though there is no _javascript_. 

-Beschi. 

On Jul 4, 4:14 am, "Erik R. Peterson" 
wrote: 
Hi
buddy! 
  
I'm undecided on the final buttons and graphics, but thanks to your 
help I got the script down. 
  
I actually fixed my own problem after posted this last email. 
  
Have a great weekend. 
  
Erik 
  
On Jul 3, 2009, at 5:14 PM,

[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-04 Thread Erik R. Peterson

Thanks Charlie,

I'll put it in now.  thanks.

E


On Jul 4, 2009, at 9:56 AM, Charlie wrote:

could shorten this all up and make it accessible for javascript  
disabled by putting the url into the href of your links.


Haven't looked at plugin but since you're just loading html will use  
load() in jQuery core:


hideLoading();
$("#cs_links a").click(function () {
   showLoading();
$("#cst_wrap_mid").slideUp();
$("#cst_wrap_mid").load($(this).attr("href"), function(){
$("#cst_wrap_mid").slideUp();
 hideLoading();

});
return false;
});

This would replace all of the switch cases. If javascript disabled  
appropriate page would open from href. Likely find that load is very  
fast and showloading may not be necessary


Erik R. Peterson wrote:



Can;t get it to work correctly.

Here is my existing code:

$(document).ready(function(){
//References
var sections = $("#cs_links a");
var loading = $("#loading");
var content = $("#cst_wrap_mid");

//Manage click events
sections.click(function(){
//show the loading bar
showLoading();
//load selected section
switch(this.id){
case "js_appoint":
content.slideUp();
content.load("/externals/appoint.htm", hideLoading);
content.slideDown();
break;

case "js_contact":
content.slideUp();
content.load("/externals/contact.htm", hideLoading);
content.slideDown();
break;

case "js_gifts":
content.slideUp();
content.load("/externals/gifts.htm", hideLoading);
content.slideDown();
break;

case "js_order":
content.slideUp();
content.load("/externals/order.htm", hideLoading);
content.slideDown();
break;

case "js_promise":
content.slideUp();
content.load("/externals/promise.htm", hideLoading);
content.slideDown();
break;

case "js_quest":
content.slideUp();
content.load("/externals/quest.htm", hideLoading);
content.slideDown();
break;

case "js_returns":
content.slideUp();
content.load("/externals/returns.htm", hideLoading);
content.slideDown();
break;

case "js_secure":
content.slideUp();
content.load("/externals/secure.htm", hideLoading);
content.slideDown();
break;

case "js_shipping":
content.slideUp();
content.load("/externals/shipping.htm", hideLoading);
content.slideDown();
break;


case "js_terms":
content.slideUp();
content.load("/externals/terms.htm", hideLoading);
content.slideDown();
break;

case "js_types":
content.slideUp();
content.load("/externals/types.htm", hideLoading);
content.slideDown();
break;

default:
//hide loading bar if there is no selected section
hideLoading();
break;
}
});

//show loading bar
function showLoading(){
loading
.css({visibility:"visible"})
.css({opacity:"1"})
.css({display:"block"})
;
}
//hide loading bar
function hideLoading(){
loading.fadeTo(1000, 0);
};
});





On Jul 4, 2009, at 6:40 AM, MOZ wrote:



Hi,
on your page: http://www.enaturalskin.com/needhelp.htm
each time the window scroll to the top because of anchor #, use
preventDefault();  to avoid this, just a suggestion.

Also see the improved version: 
http://yensdesign.com/2009/06/safe-ajax-links-using-jquery/
This trick will make your website work though there is no  
javascript.


-Beschi.

On Jul 4, 4:14 am, "Erik R. Peterson"  wrote:

Hi buddy!

I'm undecided on the final buttons and graphics, but thanks to your
help I got the script down.

I actually fixed my own problem after posted this last email.

Have a great weekend.

Erik

On Jul 3, 2009, at 5:14 PM, Cesar Sanz wrote:




Hello.



I see you succed retrieving data using ajax,



Which is the problem?


- Original Message - From: "Erik R. Peterson"  



To: 
Sent: Friday, July 03, 2009 2:48 PM
Subject: [jQuery] Need help on How to load content via AJAX in  
jQuery



I found this script:
http://yensdesign.com/2008/12/how-to-load-content-via-ajax-in-jquery/
I got it working, but it really looks bad in IE, along with  
erros.

Any alternatives or sugestions?
Here is my page:  http://www.enaturalskin.com/needhelp.htm
Many tha

[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-04 Thread Charlie





could shorten this all up and make it accessible for _javascript_
disabled by putting the url into the href of your links.

Haven't looked at plugin but since you're just loading html will use
load() in jQuery core:

hideLoading(); 
$("#cs_links a").click(function () {
       showLoading();
        $("#cst_wrap_mid").slideUp();
        $("#cst_wrap_mid").load($(this).attr("href"), function(){      
       
                $("#cst_wrap_mid").slideUp();
             hideLoading();


            });
return false; 
});

This would replace all of the switch cases. If _javascript_ disabled
appropriate page would open from href. Likely find that load is very
fast and showloading may not be necessary

Erik R. Peterson wrote:

Can;t get it to work correctly.
  
  
Here is my existing code:
  
  
$(document).ready(function(){
  
//References
  
var sections = $("#cs_links a");
  
var loading = $("#loading");
  
var content = $("#cst_wrap_mid");
  

  
//Manage click events
  
sections.click(function(){
  
    //show the loading bar
  
    showLoading();
  
    //load selected section
  
    switch(this.id){
  
    case "js_appoint":
  
    content.slideUp();
  
    content.load("/externals/appoint.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
    
    case "js_contact":
  
    content.slideUp();
  
    content.load("/externals/contact.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
  
    case "js_gifts":
  
    content.slideUp();
  
    content.load("/externals/gifts.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
  
    case "js_order":
  
    content.slideUp();
  
    content.load("/externals/order.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
    
    case "js_promise":
  
    content.slideUp();
  
    content.load("/externals/promise.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
  
    case "js_quest":
  
    content.slideUp();
  
    content.load("/externals/quest.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
  
    case "js_returns":
  
    content.slideUp();
  
    content.load("/externals/returns.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
    
    case "js_secure":
  
    content.slideUp();
  
    content.load("/externals/secure.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
  
    case "js_shipping":
  
    content.slideUp();
  
    content.load("/externals/shipping.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
  
  
    case "js_terms":
  
    content.slideUp();
  
    content.load("/externals/terms.htm", hideLoading);
  
    content.slideDown();
  
    break;
  
    
    case "js_types":
  
    content.slideUp();
  
    content.load("/externals/types.htm", hideLoading);
  
    content.slideDown();
  
    break;    
    
    default:
  
    //hide loading bar if there is no selected section
  
    hideLoading();
  
    break;
  
    }
  
});
  
  
//show loading bar
  
function showLoading(){
  
    loading
  
    .css({visibility:"visible"})
  
    .css({opacity:"1"})
  
    .css({display:"block"})
  
    ;
  
}
  
//hide loading bar
  
function hideLoading(){
  
    loading.fadeTo(1000, 0);
  
};
  
});
  
  
  
  
  
  
On Jul 4, 2009, at 6:40 AM, MOZ wrote:
  
  
  
Hi,

on your page: http://www.enaturalskin.com/needhelp.htm

each time the window scroll to the top because of anchor #, use

preventDefault();  to avoid this, just a suggestion.


Also see the improved version:
http://yensdesign.com/2009/06/safe-ajax-links-using-jquery/

This trick will make your website work though there is no _javascript_.


-Beschi.


On Jul 4, 4:14 am, "Erik R. Peterson"  wrote:

Hi buddy!
  
  
I'm undecided on the final buttons and graphics, but thanks to your
  
help I got the script down.
  
  
I actually fixed my own problem after posted this last email.
  
  
Have a great weekend.
  
  
Erik
  
  
On Jul 3, 2009, at 5:14 PM, Cesar Sanz wrote:
  
  
  
  
  Hello.

  
  
  I see you
succed

[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-04 Thread Erik R. Peterson


Can;t get it to work correctly.

Here is my existing code:

$(document).ready(function(){
//References
var sections = $("#cs_links a");
var loading = $("#loading");
var content = $("#cst_wrap_mid");

//Manage click events
sections.click(function(){
//show the loading bar
showLoading();
//load selected section
switch(this.id){
case "js_appoint":
content.slideUp();
content.load("/externals/appoint.htm", 
hideLoading);
content.slideDown();
break;

case "js_contact":
content.slideUp();
content.load("/externals/contact.htm", 
hideLoading);
content.slideDown();
break;

case "js_gifts":
content.slideUp();
content.load("/externals/gifts.htm", 
hideLoading);
content.slideDown();
break;

case "js_order":
content.slideUp();
content.load("/externals/order.htm", 
hideLoading);
content.slideDown();
break;

case "js_promise":
content.slideUp();
content.load("/externals/promise.htm", 
hideLoading);
content.slideDown();
break;

case "js_quest":
content.slideUp();
content.load("/externals/quest.htm", 
hideLoading);
content.slideDown();
break;

case "js_returns":
content.slideUp();
content.load("/externals/returns.htm", 
hideLoading);
content.slideDown();
break;

case "js_secure":
content.slideUp();
content.load("/externals/secure.htm", 
hideLoading);
content.slideDown();
break;

case "js_shipping":
content.slideUp();
content.load("/externals/shipping.htm", 
hideLoading);
content.slideDown();
break;


case "js_terms":
content.slideUp();
content.load("/externals/terms.htm", 
hideLoading);
content.slideDown();
break;

case "js_types":
content.slideUp();
content.load("/externals/types.htm", 
hideLoading);
content.slideDown();
break;  

default:
//hide loading bar if there is no selected 
section
hideLoading();
break;
}
});

//show loading bar
function showLoading(){
loading
.css({visibility:"visible"})
.css({opacity:"1"})
.css({display:"block"})
;
}
//hide loading bar
function hideLoading(){
loading.fadeTo(1000, 0);
};
});





On Jul 4, 2009, at 6:40 AM, MOZ wrote:



Hi,
on your page: http://www.enaturalskin.com/needhelp.htm
each time the window scroll to the top because of anchor #, use
preventDefault();  to avoid this, just a suggestion.

Also see the improved version: 
http://yensdesign.com/2009/06/safe-ajax-links-using-jquery/
This trick will make your website work though there is no javascript.

-Beschi.

On Jul 4, 4:14 am, "Erik R. Peterson"  wrote:

Hi buddy!

I'm undecided on the final buttons and graphics, but thanks to your
help I got the script down.

I actually fixed my own problem after posted this last email.

Have a great weekend.

Erik

On Jul 3, 2009, at 5:14 PM, Cesar Sanz wrote:




Hello.



I see you succed retrieving data using ajax,



Which is the problem?


- Origina

[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-04 Thread Erik R. Peterson


Works great...

Would you be able to show me how to make the links change via css  
after selected?


Erik



On Jul 4, 2009, at 6:40 AM, MOZ wrote:



Hi,
on your page: http://www.enaturalskin.com/needhelp.htm
each time the window scroll to the top because of anchor #, use
preventDefault();  to avoid this, just a suggestion.

Also see the improved version: 
http://yensdesign.com/2009/06/safe-ajax-links-using-jquery/
This trick will make your website work though there is no javascript.

-Beschi.

On Jul 4, 4:14 am, "Erik R. Peterson"  wrote:

Hi buddy!

I'm undecided on the final buttons and graphics, but thanks to your
help I got the script down.

I actually fixed my own problem after posted this last email.

Have a great weekend.

Erik

On Jul 3, 2009, at 5:14 PM, Cesar Sanz wrote:




Hello.



I see you succed retrieving data using ajax,



Which is the problem?


- Original Message - From: "Erik R. Peterson"  



To: 
Sent: Friday, July 03, 2009 2:48 PM
Subject: [jQuery] Need help on How to load content via AJAX in  
jQuery



I found this script:
http://yensdesign.com/2008/12/how-to-load-content-via-ajax-in-jquery/
I got it working, but it really looks bad in IE, along with erros.
Any alternatives or sugestions?
Here is my page:  http://www.enaturalskin.com/needhelp.htm
Many thanks.
Erik




[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-04 Thread MOZ

Hi,
on your page: http://www.enaturalskin.com/needhelp.htm
each time the window scroll to the top because of anchor #, use
preventDefault();  to avoid this, just a suggestion.

Also see the improved version: 
http://yensdesign.com/2009/06/safe-ajax-links-using-jquery/
This trick will make your website work though there is no javascript.

-Beschi.

On Jul 4, 4:14 am, "Erik R. Peterson"  wrote:
> Hi buddy!
>
> I'm undecided on the final buttons and graphics, but thanks to your  
> help I got the script down.
>
> I actually fixed my own problem after posted this last email.
>
> Have a great weekend.
>
> Erik
>
> On Jul 3, 2009, at 5:14 PM, Cesar Sanz wrote:
>
>
>
> > Hello.
>
> > I see you succed retrieving data using ajax,
>
> > Which is the problem?
>
> > - Original Message - From: "Erik R. Peterson" 
> > To: 
> > Sent: Friday, July 03, 2009 2:48 PM
> > Subject: [jQuery] Need help on How to load content via AJAX in jQuery
>
> >> I found this script:
> >>http://yensdesign.com/2008/12/how-to-load-content-via-ajax-in-jquery/
> >> I got it working, but it really looks bad in IE, along with erros.
> >> Any alternatives or sugestions?
> >> Here is my page:  http://www.enaturalskin.com/needhelp.htm
> >> Many thanks.
> >> Erik


[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-03 Thread Erik R. Peterson


Hi buddy!

I'm undecided on the final buttons and graphics, but thanks to your  
help I got the script down.


I actually fixed my own problem after posted this last email.

Have a great weekend.

Erik




On Jul 3, 2009, at 5:14 PM, Cesar Sanz wrote:



Hello.

I see you succed retrieving data using ajax,

Which is the problem?

- Original Message - From: "Erik R. Peterson" >

To: 
Sent: Friday, July 03, 2009 2:48 PM
Subject: [jQuery] Need help on How to load content via AJAX in jQuery



I found this script:
http://yensdesign.com/2008/12/how-to-load-content-via-ajax-in-jquery/
I got it working, but it really looks bad in IE, along with erros.
Any alternatives or sugestions?
Here is my page:  http://www.enaturalskin.com/needhelp.htm
Many thanks.
Erik




[jQuery] Re: Need help on How to load content via AJAX in jQuery

2009-07-03 Thread Cesar Sanz


Hello.

I see you succed retrieving data using ajax,

Which is the problem?

- Original Message - 
From: "Erik R. Peterson" 

To: 
Sent: Friday, July 03, 2009 2:48 PM
Subject: [jQuery] Need help on How to load content via AJAX in jQuery




I found this script:

http://yensdesign.com/2008/12/how-to-load-content-via-ajax-in-jquery/

I got it working, but it really looks bad in IE, along with erros.

Any alternatives or sugestions?

Here is my page:  http://www.enaturalskin.com/needhelp.htm

Many thanks.

Erik


[jQuery] Re: Need help in Login

2009-06-25 Thread Lee R Lemon III


http://www.reynoldsftw.com/2009/03/using-jquery-and-ajax-to-create-php-sessions/

important set your session up before anything else on the page or php
errors




On Jun 24, 3:50 am, bharani kumar 
wrote:
> Hi ,
> Am very much confusion in php login session tracking ,
>
> This is my requirement ,
>
> Am doing travel booking portal ,
>
> Before submit checkout , i have the radio option , that is existing user Yes
> No for new new user ,
>
> If user  clicks  yes , then am showing the login form ,
>
> Here i am entering the username and password , if i submit the button ,
>
> I don't want to refresh the page or no changes in URL ,
>
> After submitted , then i want to track the user details with as usual login
> functionlaity , that is need to track that user details and all ,
>
> If possible without page refresh ,
>
> Thanks
>
> B.S.Bharanikumar


[jQuery] Re: Need help in Login funcationality jquery

2009-06-24 Thread bharani kumar
Hi all ,
Its very urgent one ,

Can some one tell me using jquery login form,



On Wed, Jun 24, 2009 at 2:20 PM, bharani kumar <
bharanikumariyer...@gmail.com> wrote:

> Hi ,
> Am very much confusion in php login session tracking ,
>
> This is my requirement ,
>
> Am doing travel booking portal ,
>
> Before submit checkout , i have the radio option , that is existing user
> Yes No for new new user ,
>
>
> If user  clicks  yes , then am showing the login form ,
>
> Here i am entering the username and password , if i submit the button ,
>
>
> I don't want to refresh the page or no changes in URL ,
>
>
> After submitted , then i want to track the user details with as usual login
> functionlaity , that is need to track that user details and all ,
>
>
> If possible without page refresh ,
>
> Thanks
>
> B.S.Bharanikumar
>
>
>
>
>
>



-- 
Regards
B.S.Bharanikumar
http://php-mysql-jquery.blogspot.com/


[jQuery] Re: Need help cuz I don't get 'this'

2009-06-16 Thread Logictrap

Thanks for the tip and also the cycle plugin - It works great!


-- Forwarded message --
From: Mike Alsup 
Date: Jun 16, 4:17 pm
Subject: Need help cuz I don't get 'this'
To: jQuery (English)


> $(this).find('img').attr('src');

jQuery selectors accept a 2nd argument for context, which makes this a
bit more readable, imo:

var src = $('img',this).attr('src');


[jQuery] Re: Need help cuz I don't get 'this'

2009-06-16 Thread Mike Alsup

> $(this).find('img').attr('src');

jQuery selectors accept a 2nd argument for context, which makes this a
bit more readable, imo:

var src = $('img',this).attr('src');


[jQuery] Re: Need help cuz I don't get 'this'

2009-06-16 Thread Logictrap

>From a different forum I got this which works:

$(this).find('img').attr('src');

On Jun 16, 11:18 am, Logictrap  wrote:
> I'm using the jqery cycle plugin with an onAfter & OnBefore function.
>
> These functions process the current div as 'this' - what I sent was
> the code in my div that is getting passed as 'this'.
>
> I can see that using children is the way to get the attribute I want,
> but I don't quite understand how to use it or how to extend the
> example to get what I need.
>
> Another example might help or if you know a link that explains it more
> detail that would be great also.
>
> Thanks


[jQuery] Re: Need help cuz I don't get 'this'

2009-06-16 Thread Logictrap

I'm using the jqery cycle plugin with an onAfter & OnBefore function.

These functions process the current div as 'this' - what I sent was
the code in my div that is getting passed as 'this'.

I can see that using children is the way to get the attribute I want,
but I don't quite understand how to use it or how to extend the
example to get what I need.

Another example might help or if you know a link that explains it more
detail that would be great also.

Thanks



[jQuery] Re: Need help cuz I don't get 'this'

2009-06-16 Thread MorningZ

I don't think you understood what code to show

what you need to show is what is wrapped around your initial post's
code so that it will be easier to help you understand "this"


On Jun 16, 8:18 am, Logictrap  wrote:
> Thank you that worked!!!
>
> I think I may understand how to use children if you could also show
> how to get the img src attribute when 'this' contains:
>
> 
>   
>     
>       
>         http://www.test.org"; target="_blank">Test Logo td>
>     
>   
> 


[jQuery] Re: Need help cuz I don't get 'this'

2009-06-16 Thread Logictrap

Thank you that worked!!!

I think I may understand how to use children if you could also show
how to get the img src attribute when 'this' contains:


  

  
http://www.test.org"; target="_blank">Test Logo

  




[jQuery] Re: Need help cuz I don't get 'this'

2009-06-15 Thread Logictrap

Thank you that worked!!!

I think I may understand how to use children if you could also show
how to get the img src attrbitute when 'this' contains:


  

  
http://www.test.org"; target="_blank">Test Logo

  




On Jun 14, 9:25 am, Erik Beeson  wrote:
> Like MorningZ said, more info would be helpful, but this should work:
>
> $('#output').html('SRC: ' + $(this).children('img').attr('src'));
>
> --Erik
>
> On Sun, Jun 14, 2009 at 7:02 AM, Logictrap  wrote:
>
> > I need to get the src attribute of an img element that is a sub-
> > element of 'this' but I can't figure out how to traverse 'this' to get
> > there.
>
> > The contents of 'this' are:
>
> >      > height="200" alt="beach" />
>
> > this works:
>
> >     $('#output').html("ID: " + this.id);
>
> > This does not:
>
> >     $('#output').html("SRC: " + this.img.src);
>
> > How do I get the contents of the img.src attribute'?


[jQuery] Re: Need help cuz I don't get 'this'

2009-06-14 Thread Erik Beeson
Like MorningZ said, more info would be helpful, but this should work:

$('#output').html('SRC: ' + $(this).children('img').attr('src'));

--Erik


On Sun, Jun 14, 2009 at 7:02 AM, Logictrap  wrote:

>
> I need to get the src attribute of an img element that is a sub-
> element of 'this' but I can't figure out how to traverse 'this' to get
> there.
>
> The contents of 'this' are:
>
>  height="200" alt="beach" />
>
> this works:
>
> $('#output').html("ID: " + this.id);
>
> This does not:
>
> $('#output').html("SRC: " + this.img.src);
>
> How do I get the contents of the img.src attribute'?


[jQuery] Re: Need help cuz I don't get 'this'

2009-06-14 Thread MorningZ

Can you show more code around the ".html" statement?  this will help
others better help you understand what "this" is in that context


On Jun 14, 10:02 am, Logictrap  wrote:
> I need to get the src attribute of an img element that is a sub-
> element of 'this' but I can't figure out how to traverse 'this' to get
> there.
>
> The contents of 'this' are:
>
>       height="200" alt="beach" />
>
> this works:
>
>      $('#output').html("ID: " + this.id);
>
> This does not:
>
>      $('#output').html("SRC: " + this.img.src);
>
> How do I get the contents of the img.src attribute'?


[jQuery] Re: Need help with DIV manipulation

2009-06-03 Thread Gustavo Salomé
Try this:
Remove the href params, instead change the loadContent param to an id or
class, like this:

then change  your javascript to:
$(function(){
  $('li a').click(function(){
id=$(this).attr('id');
$("#content").load("pages.php?o="+id+"");
return false;
  });
});

2009/6/3 nanook72 

>
> bump
>
> On Jun 3, 6:49 am, nanook72  wrote:
> > Hi all,
> >
> > I need help with manipulating two div's, one holds the main content
> > and the other holds the images matching that content.  Right now I
> > have the menu changing the content of the main div just fine, however
> > I do not know how to change the images in the second div at the same
> > time based on the users selection from the menu.  Below is the code
> > I'm using to change the main div content.  Thanks in advance!
> >
> > Tim
> >
> > 
> > function loadContent(id) {
> > $("#content").load("pages.php?o="+id+"");
> > }
> > 
> >
> > 
> >
> >  href="javascript:loadContent
> > (1);">Home
> >  href="javascript:loadContent
> > (2);">AboutUS
>



-- 
Gustavo Salome Silva


[jQuery] Re: Need help with DIV manipulation

2009-06-03 Thread nanook72

bump

On Jun 3, 6:49 am, nanook72  wrote:
> Hi all,
>
> I need help with manipulating two div's, one holds the main content
> and the other holds the images matching that content.  Right now I
> have the menu changing the content of the main div just fine, however
> I do not know how to change the images in the second div at the same
> time based on the users selection from the menu.  Below is the code
> I'm using to change the main div content.  Thanks in advance!
>
> Tim
>
> 
>         function loadContent(id) {
>                 $("#content").load("pages.php?o="+id+"");
>         }
>         
>
> 
>
>                         Home
>                         AboutUS


[jQuery] Re: Need help optimizing/analyzing jquery / json

2009-05-27 Thread deltaf

I didn't look too closely at the files, but I suggest separating your
data from the executing code. Use JSON to create a series of data
objects and use a different script to run through those objects and
build your page based on search criteria, etc.

>From what I saw in cruise_json.js, there's a lot of repeated if
statements and variables. I have a feeling it would be easy to reduce
that code.

I could be missing the actual data file.. Also, it would be very
helpful for troubleshooting if the demo you provided would have
properly formatted code so that it would be easier to read. That's the
main reason I didn't look too carefully.

On May 27, 2:01 am, andymott  wrote:
> Hello Guys,
>
> I have created a site using jquerywww.arc-max.com/cruisesearch/the
> problem lies in the initial loading of the result page (the front page
> is a bit slow but that I can optimize that on my own) . I am using
> json to store the result set. The json file can get a bit bloated up
> anywhere between 200-400kb depending on the number of results . After
> optimizing the graphics and using gzip I have been able to reduce the
> load time to around 20 seconds depending on the number of results
> (this based on a first time load).
>
> Since i am not that good at  optimizing i wanted to know ...
>
> a) Can the jquery code or the json data be optimized further?  is it a
> badly written code ? I know this is very subjective but i am sure
> there are things that could be done that i have no clue about ...so
> would like to show it to you guys who have had some experience in
> analyzing codes.
>
> b) is this possible and how ?  to load two json object one with say 20
> results the other with all the results including the first 20.
> Initially the first json object gets loaded (small file faster
> download hence faster loading of page) while the bigger file gets
> loaded in the background and once the user starts using the filter the
> data gets pulled in from the complete result file (the bigger file).
>
> Thanks for our help
> andy


[jQuery] Re: need help with jqGrid

2009-04-17 Thread Led

thanks tony, but is not loading the results ... and no error

On 17 Abr, 15:36, Tony  wrote:
> Hello,
> The version of jquery  1.3.1 that you use is not compatible with
> jqGrid version 3.4
> Download the latest 3.4.3 version of jqGrid
>
> On Apr 17, 2:51 pm, Led  wrote:
>
>
>
> > tony , check that is not that.
>
> > On 17 Abr, 11:46, Tony  wrote:
>
> > > Hello,
> > > Already replayed. Please check your code - you have a unneeded coma in
> > > colModel
> > > Regards
> > > Tony
>
> > > On Apr 17, 1:33 pm, led  wrote:
>
> > > > I' m trying to use the jquery jqGrid plugin but i can't see it working
> > > > with ASP code.
> > > > this is the xml generated file.
>
> > > > 
> > > >    
> > > >    
> > > >   114
> > > >     
> > > >       191
> > > >       15
> > > >     
> > > >     
> > > >       192
> > > >       15
> > > >     
> > > >     
> > > >       193
> > > >       15
> > > >     
> > > > 
>
> > > > and this is the html:
>
> > > > 
> > > > 
> > > > jqGrid Demo
> > > > 
> > > > 
> > > > 
> > > >  > > > script>
> > > >