[jQuery] Accordion issues: Closes when clicking link

2008-05-27 Thread hubbs

I am using the jQuery Accordion plugin (http://bassistance.de/jquery-
plugins/jquery-plugin-accordion/) which is great.  I have one
problem.  Inside of some of my accordion divs I have links to pdf
files, external pages, etc.  When you click on any of these links, it
just closes the accordion, and does not take the user to the link.
Was I suppose to add an extra option in order to let the script follow
links?


[jQuery] Re: loading a PDF file using Ajax

2008-05-27 Thread pedalpete

I could be wrong, but i believe that because pdf requires you to run a
reader, you can't import the pdf directly within your content.

However, I think an iframe might work for you.
You can retrieve a pdf file via ajax, I'm sure. It's just a matter of
getting it displayed once you get it.

The only way to figure it out I think is to try.
If ajax to a div doesn't work, try an iframe and target to that.


[jQuery] array problem

2008-05-27 Thread Vallard

I'm trying to run the following code:

var nav = [ #home, #contact, #gallery, #about ];
$(document).ready(function(){
for(var i = 0; i  nav.length; i++){
$(nav[i]).mouseover(function(){
$(nav[i]).animate({
marginTop: -5px
});
});
$(nav[i]).mouseout(function(){
$(nav[i]).animate({
marginTop: 0px
});
});
}
});

however, those effects never get added.  If I don't do the for loop
and do each item individually it works fine.  Do I just have a dumb
bug in here?

Thanks for any help, and thanks for developing this great lib.


[jQuery] Help with combox

2008-05-27 Thread LaBoss

Hello my people,

I am in some problems with a self populated combobox

I want to make something from this:


category
-- PlayStation - 1
-- XBOX - 2
(From here they are automatically populated so I will by this as an
example)

Platform
-- PSP - 1
-- PS3 - 2
-- XBOX 360 -3

Games
-- Jogo1 PSP - 1
-- Game 2 PS3 - 2
-- Game 3 PS3 - 3


So how  is to edit, stated that the box were Selected with the value
coming from the mysql (the table news)

ie the news had


category = 1
platform = 2
game = 2

then the selects were well


category
-- PlayStation  - 1 - selected
--- XBOX - 2

Platform
-- PSP - 1
-- PS3 - 2 - selected
( disappeared a xbox 360 porque a plataforma escolhida foi a
plataforma Playstation)

Games
-- Game 2 PS3 - 2 - selected
-- Game 3 PS3 - 3
(PSP Jogo1 the game disappeared pk selects the category is the PS3)

The way I auto popolate ja jquery with the following code:

$().ready(function() {
$([EMAIL PROTECTED]).change(function(){
$('[EMAIL PROTECTED]').html('option value=A
carregar Plataformas/option');
$.post('procura_plataforma.php', { categoria : $
(this).val() }, function(resposta){
$('[EMAIL PROTECTED]').html(resposta);
}

);
});
$([EMAIL PROTECTED]).change(function(){
$('[EMAIL PROTECTED]').html('option value=A carregar
dados/option');
$.post('procura_jogos.php', { estado : $(this).val() },
function(resposta){
$('[EMAIL PROTECTED]').html(resposta);
}

);
});
});


The problem now this, if I have selected the category Playstation
(with data from the sql), to open the page it does not select the
population of platforms and select automatic the value (in this case
- PS3 - 2) and turn does not make it to select the games

I am desperate even with this will be someone who can help me?



Greetings and thank you


[jQuery] Re: datepicker select to update a div, and strange datepicker css issue

2008-05-27 Thread pedalpete

I've made some progress with this, but my code is looking really
strange.

To rehash, I am trying to get the datepicker to update a span, not an
input.
But i was getting an error.
Now I can update the span, but I can't split the date variable before
I update (it gives blank time and gmt details that I don't need
anyway).

For some reason I have to have a space before the selectedDate
variable, or it isn't recognized and i get an error.
Anybody know why this is?

Here's my working code...

[code]
$('.dateItem')
.datePicker({inline:true})
.bind(
'dateSelected',
function(e, selectedDate, $td)
{
var getDate = ' '+selectedDate;
var splitDate = getDate.split(00:00:00);
$('.holdDate').html(splitDate[0]);
}
);
[/code]


[jQuery] removeAttr for rowspan

2008-05-27 Thread snobo

Since upgrading to 1.2.5 (the same applies to 1.2.6), an attempt to $
('... td').removeAttr('rowSpan') triggers an error in IE6/7.
Previously (up to 1.2.4b) it effectively set rowSpan to 1. It still
works that way in FF.

I'm not sure is it a bug or a feature, but of course it has broken my
application, so... I guess it should be either fixed or explicitly
noted in the docs. I wonder, will it cause the same problem for some
other attributes?


[jQuery] Re: jQuery Google CDN

2008-05-27 Thread Jeremiah Johnson

I don't understand why the Ajaxian article and the API docs prefer the 
google.load() route.  Since the paths are published in the Google CDN, I would 
personally prefer those but I may be missing something important.  By using the 
google.load, it seems like you could get the smart versioning or ensure that 
any future path changes will be silent to your app; on the other hand, by using 
the published path I know what URL will get cached and I 'know' what I'm 
getting.  Is there something else about google.load() that I should be thinking 
about?
 
- jeremiah Date: Tue, 27 May 2008 09:55:15 -0700 Subject: [jQuery] Re: jQuery 
Google CDN From: [EMAIL PROTECTED] To: jquery-en@googlegroups.com   Nice 
one!   www.subprint.com  On May 27, 10:57 am, Jake McGraw [EMAIL 
PROTECTED] wrote:  Just tried it out, works very nice, glad to see Google 
hopping on the  YUI band wagon for hosting library files.   - jake   
On Tue, May 27, 2008 at 11:49 AM, Glen Lipka [EMAIL PROTECTED] wrote:   
Not sure if everyone saw this. Looks great to me. I think I will switch   
asap.  http://code.google.com/apis/ajaxlibs/Originally read here: 
 http://ajaxian.com/archives/announcing-ajax-libraries-api-speed-up-yo...  
  Glen
_
E-mail for the greater good. Join the i’m Initiative from Microsoft.
http://im.live.com/Messenger/IM/Join/Default.aspx?source=EML_WL_ GreaterGood

[jQuery] Re: jquery wrapper for widgets

2008-05-27 Thread Scott González

http://docs.jquery.com/Core/jQuery.noConflict#extreme

On May 26, 8:56 pm, garazy [EMAIL PROTECTED] wrote:
 Hi,

 I'd like to use jquery to create widgets that are deployed to other
 websites. However to do that I'd need to wrap jquery in a container so
 I know that it wouldn't conflict with any other javascript running on
 the site for example mywidget.$ rather than just using $.

 Is there a way to do this or has it already been done?

 Thanks,

 Gary


[jQuery] Re: Accordion issues: Closes when clicking link

2008-05-27 Thread hubbs

I figured it out.  I needed to specify a header (header:
'a.accordTitle',)

On May 27, 10:04 am, hubbs [EMAIL PROTECTED] wrote:
 I am using the jQuery Accordion plugin (http://bassistance.de/jquery-
 plugins/jquery-plugin-accordion/) which is great.  I have one
 problem.  Inside of some of my accordion divs I have links to pdf
 files, external pages, etc.  When you click on any of these links, it
 just closes the accordion, and does not take the user to the link.
 Was I suppose to add an extra option in order to let the script follow
 links?


[jQuery] Re: highlight effect on error

2008-05-27 Thread pedalpete

Have you checked out the validation plugin? it's really great, and
provides a message as to what you are expecting the user to do, etc.

For what you currently have, why do the '.fadeIn/.fadeOut',etc.
Why not just do .addClass?
and then when the right input is accepted, .removeClass?


[jQuery] Re: ajax and XML - issue with file extensions?

2008-05-27 Thread David Decraene

hagalaz, you are right,
using $.get() instead of $.ajax() fixes the problem,

but that does mean that this is a genuine bug?
Can somebody look into it?

example:

this works for path = file.owl:
$.get(path, function(xml){callback(that.parse(xml, options));});

this does not work for path = file.owl:
$.ajax({ url: path, dataType: xml, success: function(xml)
{callback(that.parse(xml, options));}});

david decraene
http://jowl.ontologyonline.org

On 27 mei, 08:45, hagalaz [EMAIL PROTECTED] wrote:
 I had similar issues with the ajax function. Then I switched to .get
 and .post and all worked seamlessly. (I create xml content dynamically
 with PHP)

 On May 26, 9:35 pm, David Decraene [EMAIL PROTECTED]
 wrote:

  I have noticed some rather peculiar behavior with the ajax function:

  I have a file called person.owl, which contains xml syntax, and when
  trying to load that file the ajax call triggers the error function
  (parsererror) / fails to load.

  However, if I rename the file to person.xml (e.g. change the
  extension) I have no problems whatsoever anymore, the file loads
  successfully.

  Anything I can do to avoid this behaviour (with exception of
  renaming?), it seems to be reproducible.

  Spotted the bug when working on a plugin I'm writing, the owl (web
  ontology language) extension is something encountered frequent in this
  setting:
  jOWL, a semantic javascript library athttp://jowl.ontologyonline.org/

  David Decraene.http://ontologyonline.org


[jQuery] :contains ... troubling behavior

2008-05-27 Thread EuGeNe

Hi there,

I am troubled by the behavior of the :contains filter

I have an a tag

a class=undo href=/tag/poesie/5undo/a

I can select it with

$(a.undo) and play with the chain not problem e.g. $
(a.undo).remove() works fine

if I use

$(':contains(a href=/tag/sagesse/4 class=undoundo/a)')
or
$('a:contains(a href=/tag/sagesse/4 class=undoundo/a)')
or
$('a.undo:contains(a href=/tag/sagesse/4 class=undoundo/a)')

I get the same result pointing to the same tag but I can't play
with it i.e. whatever I do to it doens't have an impact on the DOM.

I am sure it is something I don't understand about JS or jQuery ...
could somebody enlighten me?

Thanks

EuGeNe -- http://www.3kwa.com


[jQuery] Re: $('*').not(':text').click(function() { $(':text').eq(2).focus() } ) ; wrong syntax?

2008-05-27 Thread paulj

Many thanks, Karl. Your solution works fine.

Paul

On 27 May, 01:53, Karl Swedberg [EMAIL PROTECTED] wrote:
 Hi Paul,

 You could try this:

 $(document).click(function(event) {
if (!$(event.target).is(':text')) {
  $(':text').eq(2).focus();
}

 });

 I'm pretty sure that should do it.

 --Karl
 
 Karl Swedbergwww.englishrules.comwww.learningjquery.com

 On May 26, 2008, at 5:52 PM, paulj wrote:



[jQuery] Re: Help learning...

2008-05-27 Thread Aaron

I been playing around with the hover and fadeIn and fadeOut functions
in jquery and I can't get them working on my website(NOTE:website is
not online yet still working on the website). I learned javascript and
I do have programming background.
I don't know what I am exactly doing wrong.

Here is what I have so far:

$(document).ready(function() {
$(div#image).hover(
  function () {
   $(li:hidden:first).fadeIn(slow));
  },
  function () {
$(li).fadeOut(slow).remove();
  }
);

this was just for playing around.  I added div#image there to indicate
it had css properties and it's an image and is called image  in css.
But what I put there was #image .

in here I was trying to just get an example to work which it failed I
made a list in my html doc and I made a javascript file and added the
script in with the script html tag ect and also added the css and
the jquery javascript in my html doc.

this script was supposed to fade in a list when my mouse is over the
div#image  which dosen't I see the list and it's displayed above the
image and is visable. so I tried to use the hidden function but it
failed and didn't make any difference.

is there somthing I am missing??

On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:
 Hi  I am currently building a website. I  am trying to  use the hover
 and fadein and fadeout functions from jquery.

 I don't have a full understanding of it.

 I plan to make a new file that is a javascript file that will constain
 all javascripts of my webpage in that file. I have my html file in one
 file and have one css file for the webpage.

 What I am trying to make right now is have the users main image shown
 on the html page meaning the main page of the users webpage. I want to
 have the users user there mouse to put over the image of them which
 would then fade in a table  with all their pictures that they
 uploaded.
 and if  the mouse goes off the persons image and or the faded in table
 it would then fade out.

 that's what I want so far.

 I don't know  how to use    hoever and the fadein and fade out
 functions all together and how It would fade in  a table  or at least
 fade in a image that I created that would be a background for where
 the images would get displayed  like a photo album ect.

 if anyone can give me an example code of what is needed for hover to
 work.

 I know  hoever(this here would be when the mouse is over the
 element,this is when the mouse goes off the element the fade out ect.)

 but how can I have it when the mouse is over tell the computer to fade
 in a table or a image that will have the other images the user
 uploaded to appear in that table or image.


[jQuery] Re: array problem

2008-05-27 Thread Ariel Flesler

$(document).ready(function(){
   $('#home, #contact, #gallery, #about').hover(
function(){
$(this).stop().animate({marginTop: -5px});
},
function(){
$(this).stop().animate({marginTop: 0px});
}
});
});

You can use a class selector instead of the ids.

--
Ariel Flesler
http://flesler.blogspot.com

On 27 mayo, 14:13, Vallard [EMAIL PROTECTED] wrote:
 I'm trying to run the following code:

 var nav = [ #home, #contact, #gallery, #about ];
 $(document).ready(function(){
     for(var i = 0; i  nav.length; i++){
         $(nav[i]).mouseover(function(){
             $(nav[i]).animate({
                 marginTop: -5px
             });
         });
         $(nav[i]).mouseout(function(){
             $(nav[i]).animate({
                 marginTop: 0px
             });
         });
     }

 });

 however, those effects never get added.  If I don't do the for loop
 and do each item individually it works fine.  Do I just have a dumb
 bug in here?

 Thanks for any help, and thanks for developing this great lib.


[jQuery] Re: Help learning...

2008-05-27 Thread Josh Nathanson


Your selectors need quotes around them:

$(li:hidden:first).fadeIn(slow);  


etc.

-- Josh


- Original Message - 
From: Aaron [EMAIL PROTECTED]

To: jQuery (English) jquery-en@googlegroups.com
Sent: Tuesday, May 27, 2008 11:31 AM
Subject: [jQuery] Re: Help learning...



I been playing around with the hover and fadeIn and fadeOut functions
in jquery and I can't get them working on my website(NOTE:website is
not online yet still working on the website). I learned javascript and
I do have programming background.
I don't know what I am exactly doing wrong.

Here is what I have so far:

$(document).ready(function() {
$(div#image).hover(
 function () {
  $(li:hidden:first).fadeIn(slow));
 },
 function () {
   $(li).fadeOut(slow).remove();
 }
   );

this was just for playing around.  I added div#image there to indicate
it had css properties and it's an image and is called image  in css.
But what I put there was #image .

in here I was trying to just get an example to work which it failed I
made a list in my html doc and I made a javascript file and added the
script in with the script html tag ect and also added the css and
the jquery javascript in my html doc.

this script was supposed to fade in a list when my mouse is over the
div#image  which dosen't I see the list and it's displayed above the
image and is visable. so I tried to use the hidden function but it
failed and didn't make any difference.

is there somthing I am missing??

On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:

Hi I am currently building a website. I am trying to use the hover
and fadein and fadeout functions from jquery.

I don't have a full understanding of it.

I plan to make a new file that is a javascript file that will constain
all javascripts of my webpage in that file. I have my html file in one
file and have one css file for the webpage.

What I am trying to make right now is have the users main image shown
on the html page meaning the main page of the users webpage. I want to
have the users user there mouse to put over the image of them which
would then fade in a table with all their pictures that they
uploaded.
and if the mouse goes off the persons image and or the faded in table
it would then fade out.

that's what I want so far.

I don't know how to use hoever and the fadein and fade out
functions all together and how It would fade in a table or at least
fade in a image that I created that would be a background for where
the images would get displayed like a photo album ect.

if anyone can give me an example code of what is needed for hover to
work.

I know hoever(this here would be when the mouse is over the
element,this is when the mouse goes off the element the fade out ect.)

but how can I have it when the mouse is over tell the computer to fade
in a table or a image that will have the other images the user
uploaded to appear in that table or image.


[jQuery] Grouping Definition list items

2008-05-27 Thread macgregor

I have a survey marked up with a definition list like so:

dl
dtQuestion 1/dt
ddAnswer 1input type=radio //dd
dd class=commentsAnswer 2input type=radio //dd
dd class=feedback
textarea/textarea
/dd
dtQuestion 2/dt
ddAnswer 1input type=radio //dd
ddAnswer 2input type=radio //dd
dd class=commentsAnswer 3input type=radio //dd
dd class=feedback
textarea/textarea
/dd
/dl


Is there any way to select the dd elements for a particular dt? I
would like to be able to show/hide the textarea when the radio button
inside dd.comments is clicked/selected.


[jQuery] Re: my code only works under firefox

2008-05-27 Thread arden liu
Hi, Scott
After I added incrementing parameter, it works fine in IE, but it still does
not work under Opera 9.27 and Apple Safari 3.1.1.
Thanks again.
Arden
=
var ipVal=0;
  function refreshProgress()
  {
var uploadTicket = $(#uploadTicket).val();
ipVal = ipVal + 1;
$.getJSON(
   'c:url value='/uploadprogress.spring'/',
   {uploadTicket:uploadTicket, ip:ipVal},
   function(data){
 $(#test1).val(data.demo);
   });
 window.setTimeout(refreshProgress(), 1500);
  }
=
On Tue, May 27, 2008 at 12:54 PM, Scott Sauyet [EMAIL PROTECTED] wrote:


 arden liu wrote:

 The following code only works under Firefox, I do not know why it does not
 work under IE.


 It might help if we had the HTML output rather than the raw JSP code.

 But my first thought is that perhaps IE is caching the results and not
 calling your URL again.  Could you add an incrementing parameter to the
 data?

  -- Scott



[jQuery] Re: Help learning...

2008-05-27 Thread Aaron

Yep got them sorry I must of when posting deleted the selectors.

On May 27, 3:24 pm, Josh Nathanson [EMAIL PROTECTED] wrote:
 Your selectors need quotes around them:

 $(li:hidden:first).fadeIn(slow);  

 etc.

 -- Josh



 - Original Message -
 From: Aaron [EMAIL PROTECTED]
 To: jQuery (English) jquery-en@googlegroups.com
 Sent: Tuesday, May 27, 2008 11:31 AM
 Subject: [jQuery] Re: Help learning...

 I been playing around with the hover and fadeIn and fadeOut functions
 in jquery and I can't get them working on my website(NOTE:website is
 not online yet still working on the website). I learned javascript and
 I do have programming background.
 I don't know what I am exactly doing wrong.

 Here is what I have so far:

 $(document).ready(function() {
 $(div#image).hover(
       function () {
    $(li:hidden:first).fadeIn(slow));
       },
       function () {
         $(li).fadeOut(slow).remove();
       }
     );

 this was just for playing around.  I added div#image there to indicate
 it had css properties and it's an image and is called image  in css.
 But what I put there was #image .

 in here I was trying to just get an example to work which it failed I
 made a list in my html doc and I made a javascript file and added the
 script in with the script html tag ect and also added the css and
 the jquery javascript in my html doc.

 this script was supposed to fade in a list when my mouse is over the
 div#image  which dosen't I see the list and it's displayed above the
 image and is visable. so I tried to use the hidden function but it
 failed and didn't make any difference.

 is there somthing I am missing??

 On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:
  Hi I am currently building a website. I am trying to use the hover
  and fadein and fadeout functions from jquery.

  I don't have a full understanding of it.

  I plan to make a new file that is a javascript file that will constain
  all javascripts of my webpage in that file. I have my html file in one
  file and have one css file for the webpage.

  What I am trying to make right now is have the users main image shown
  on the html page meaning the main page of the users webpage. I want to
  have the users user there mouse to put over the image of them which
  would then fade in a table with all their pictures that they
  uploaded.
  and if the mouse goes off the persons image and or the faded in table
  it would then fade out.

  that's what I want so far.

  I don't know how to use hoever and the fadein and fade out
  functions all together and how It would fade in a table or at least
  fade in a image that I created that would be a background for where
  the images would get displayed like a photo album ect.

  if anyone can give me an example code of what is needed for hover to
  work.

  I know hoever(this here would be when the mouse is over the
  element,this is when the mouse goes off the element the fade out ect.)

  but how can I have it when the mouse is over tell the computer to fade
  in a table or a image that will have the other images the user
  uploaded to appear in that table or image.- Hide quoted text -

 - Show quoted text -


[jQuery] how to change the value of a hidden inputtype?

2008-05-27 Thread Natrium

I have a hidden inputtype:

input type=hidden name=test1 id=test1 value= /


How can I change the value of it by using JQuery?

This is what I am doing.
$('#test1').value = hello world;


What am I doing wrong?


[jQuery] Re: my code only works under firefox

2008-05-27 Thread arden liu
Hi,
The following is HTML output.
I will try to add an incrementing parameter.
Thanks for your help.
Arden
==
?xml version=1.0 encoding=UTF-8 ?






!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN 
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd;
html xmlns=http://www.w3.org/1999/xhtml;
head
 meta http-equiv=Content-Type content=text/html; charset=UTF-8 /
 link href=/arden/styles/layout.css rel=stylesheet type=text/css/
 title
  Insert title here
 /title
 link href=/arden/images/favicon.ico rel=shortcut icon/

  meta http-equiv=Content-Type content=text/html; charset=UTF-8 /

  script type=text/javascript
src=/arden/javascripts/jquery/jquery-1.2.6.js/script
  script type=text/javascript
  function refreshProgress()
  {
var uploadTicket = $(#uploadTicket).val();
$.getJSON(
   '/arden/uploadprogress.spring',
   {uploadTicket:uploadTicket},
   function(data){
 $(#test1).val(data.demo);
   });
 window.setTimeout(refreshProgress(), 1500);
  }

   $(function(){
$(#uploadForm).submit(function(){
 $(:submit,this).attr(disabled, disabled);
 window.setTimeout(refreshProgress(), 1500);
});
   });
  /script

/head
body
 div id=container
  div id=header
  header
  /div

  div id=menu
   ul
li a href=/arden/home.springHome/a/li
li a href=/arden/photo.springPhoto/a/li
li a href=/arden/hiking.springHiking/a/li
li a href=/arden/computer.springComputer/a/li
   /ul
  /div
  div id=contentwrapper

  form id=uploadForm method=post action=imageuploadnew.spring
enctype=multipart/form-data
   table
tr
 tdFile:/td
 td
  input type=hidden id=uploadTicket name=uploadTicket value=3/
  input type=hidden name=albumId value=1/
  input type=file name=file01/
  input type=text id=test1 name=test/
 /td
/tr
tr
 td/td
 td
  input type=submit id=submitButton value=Submit/
 /td
/tr
   /table
  /form
 /div
  div id=footer
   ul
lia href=/arden/about.springAbout/a/li
lia href=/arden/powerby.springPower By/a/li
lia href=/arden/language.springLanguage/a/li
   /ul
  /div
 /div
/body
/html
==
On Tue, May 27, 2008 at 12:54 PM, Scott Sauyet [EMAIL PROTECTED] wrote:


 arden liu wrote:

 The following code only works under Firefox, I do not know why it does not
 work under IE.


 It might help if we had the HTML output rather than the raw JSP code.

 But my first thought is that perhaps IE is caching the results and not
 calling your URL again.  Could you add an incrementing parameter to the
 data?

  -- Scott



[jQuery] Re: how to change the value of a hidden inputtype?

2008-05-27 Thread Josh Nathanson


You can do this:
$('#test1').val( 'hello world' );

OR
$('#test1')[0].value = 'hello world'; // adding the array index returns the 
node instead of the jQuery object


-- Josh



- Original Message - 
From: Natrium [EMAIL PROTECTED]

To: jQuery (English) jquery-en@googlegroups.com
Sent: Tuesday, May 27, 2008 12:33 PM
Subject: [jQuery] how to change the value of a hidden inputtype?




I have a hidden inputtype:

input type=hidden name=test1 id=test1 value= /


How can I change the value of it by using JQuery?

This is what I am doing.
$('#test1').value = hello world;


What am I doing wrong? 




[jQuery] Display loading image while alternate image loads.

2008-05-27 Thread Andy Matthews
I have a default image loaded into an img tag with an id of specialImage.
I also have a select box which displays a list of vehicles. The value of
each option is a filename (75682.jpg, 75123.jpg, etc.).
 
When the user selects a vehicle, I want to change the src of the img tag but
I'm running into a few issues that I'm not sure how to get around.
 
1) Because I'm not using an AJAX call, I don't know if the file actually
exists on the server. A few images are then showing as broken which is a big
no no.
 
2) The images being loaded in aren't huge, but they might be 40k or so.
Because I'm simply changing the src, I can't display a loading image while
the requested image is loading.
 
Are there ways around this? I'm thinking I could do an AJAX call to get the
response headers for the file. When I trigger the AJAX call, I'd display the
loading image. Then, if the response comes back 200, then I can display the
actual file, if not, I can display a no image available image.
 
Any thoughts on this method? Is there a better way to do this?
 

 
Andy Matthews
Senior ColdFusion Developer

Office:  615.627.9747
Fax:  615.467.6249
www.dealerskins.com http://www.dealerskins.com/ 
 
Total customer satisfaction is my number 1 priority! If you are not
completely satisfied with the service I have provided, please let me know
right away so I can correct the problem, or notify my manager Aaron West at
[EMAIL PROTECTED]
 
2008 Email NADA.jpg

[jQuery] Re: how to change the value of a hidden inputtype?

2008-05-27 Thread Natrium

this is how it works:

$('#test1').val(hello world);

On 27 mei, 21:33, Natrium [EMAIL PROTECTED] wrote:
 I have a hidden inputtype:

 input type=hidden name=test1 id=test1 value= /

 How can I change the value of it by using JQuery?

 This is what I am doing.
 $('#test1').value = hello world;

 What am I doing wrong?


[jQuery] change innerHTML

2008-05-27 Thread arden liu
In my html, I have the following span to show upload percentage:
span id=progressBarText0%/span

I tried to update the percentage using the following javascript:
$(#progressBarText).innerHTML = 76%;

But it does not work. :(
Thanks.
Arden


[jQuery] Re: Help learning...

2008-05-27 Thread Aaron

Here is the exact code exactly copied and pasted from my file to here:

$(document).ready(function() {
$(#image).hover(
  function () {
   $(li:hidden:first).fadeIn(slow));
  },
  function () {
$(li).fadeOut(slow).remove();
  }
);

On May 27, 3:24 pm, Josh Nathanson [EMAIL PROTECTED] wrote:
 Your selectors need quotes around them:

 $(li:hidden:first).fadeIn(slow);  

 etc.

 -- Josh



 - Original Message -
 From: Aaron [EMAIL PROTECTED]
 To: jQuery (English) jquery-en@googlegroups.com
 Sent: Tuesday, May 27, 2008 11:31 AM
 Subject: [jQuery] Re: Help learning...

 I been playing around with the hover and fadeIn and fadeOut functions
 in jquery and I can't get them working on my website(NOTE:website is
 not online yet still working on the website). I learned javascript and
 I do have programming background.
 I don't know what I am exactly doing wrong.

 Here is what I have so far:

 $(document).ready(function() {
 $(div#image).hover(
       function () {
    $(li:hidden:first).fadeIn(slow));
       },
       function () {
         $(li).fadeOut(slow).remove();
       }
     );

 this was just for playing around.  I added div#image there to indicate
 it had css properties and it's an image and is called image  in css.
 But what I put there was #image .

 in here I was trying to just get an example to work which it failed I
 made a list in my html doc and I made a javascript file and added the
 script in with the script html tag ect and also added the css and
 the jquery javascript in my html doc.

 this script was supposed to fade in a list when my mouse is over the
 div#image  which dosen't I see the list and it's displayed above the
 image and is visable. so I tried to use the hidden function but it
 failed and didn't make any difference.

 is there somthing I am missing??

 On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:
  Hi I am currently building a website. I am trying to use the hover
  and fadein and fadeout functions from jquery.

  I don't have a full understanding of it.

  I plan to make a new file that is a javascript file that will constain
  all javascripts of my webpage in that file. I have my html file in one
  file and have one css file for the webpage.

  What I am trying to make right now is have the users main image shown
  on the html page meaning the main page of the users webpage. I want to
  have the users user there mouse to put over the image of them which
  would then fade in a table with all their pictures that they
  uploaded.
  and if the mouse goes off the persons image and or the faded in table
  it would then fade out.

  that's what I want so far.

  I don't know how to use hoever and the fadein and fade out
  functions all together and how It would fade in a table or at least
  fade in a image that I created that would be a background for where
  the images would get displayed like a photo album ect.

  if anyone can give me an example code of what is needed for hover to
  work.

  I know hoever(this here would be when the mouse is over the
  element,this is when the mouse goes off the element the fade out ect.)

  but how can I have it when the mouse is over tell the computer to fade
  in a table or a image that will have the other images the user
  uploaded to appear in that table or image.- Hide quoted text -

 - Show quoted text -


[jQuery] Re: change innerHTML

2008-05-27 Thread arden liu
Hi,
I tried the following, which works fine.
$(#progressBarText).attr(innerHTML, data.uploadProgress.percent + %);
Thanks.
Arden

On Tue, May 27, 2008 at 4:45 PM, arden liu [EMAIL PROTECTED] wrote:

 In my html, I have the following span to show upload percentage:
 span id=progressBarText0%/span

 I tried to update the percentage using the following javascript:
 $(#progressBarText).innerHTML = 76%;

 But it does not work. :(
 Thanks.
 Arden



[jQuery] Re: Display loading image while alternate image loads.

2008-05-27 Thread Dan G. Switzer, II
Andy,

 

You can use the onerror event of an image to determine if an image loaded or
not. Also, you could load the image using JS's Image object-that way you
could display a loading image. Here's some example code:

 

http://www.rgagnon.com/jsdetails/js-0083.html

 

-Dan

 

  _  

From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Andy Matthews
Sent: Tuesday, May 27, 2008 4:50 PM
To: [jQuery]
Subject: [jQuery] Display loading image while alternate image loads.

 

I have a default image loaded into an img tag with an id of specialImage.
I also have a select box which displays a list of vehicles. The value of
each option is a filename (75682.jpg, 75123.jpg, etc.).

 

When the user selects a vehicle, I want to change the src of the img tag but
I'm running into a few issues that I'm not sure how to get around.

 

1) Because I'm not using an AJAX call, I don't know if the file actually
exists on the server. A few images are then showing as broken which is a big
no no.

 

2) The images being loaded in aren't huge, but they might be 40k or so.
Because I'm simply changing the src, I can't display a loading image while
the requested image is loading.

 

Are there ways around this? I'm thinking I could do an AJAX call to get the
response headers for the file. When I trigger the AJAX call, I'd display the
loading image. Then, if the response comes back 200, then I can display the
actual file, if not, I can display a no image available image.

 

Any thoughts on this method? Is there a better way to do this?

 



 

Andy Matthews
Senior ColdFusion Developer

Office:  615.627.9747
Fax:  615.467.6249

www.dealerskins.com http://www.dealerskins.com/ 

 

Total customer satisfaction is my number 1 priority! If you are not
completely satisfied with the service I have provided, please let me know
right away so I can correct the problem, or notify my manager Aaron West at
[EMAIL PROTECTED]

 

image001.jpg

[jQuery] Re: change innerHTML

2008-05-27 Thread Brandon Aaron
You can do this several ways:

$('#progressBarText')[0].innerHTML = '76%';

$('#progressBarText').attr('innerHTML', '76%');

And finally the preferred method:
$('#progressBarText').html('76%');

The docs for the html method: http://docs.jquery.com/Attributes/html#val

--
Brandon Aaron

On Tue, May 27, 2008 at 3:45 PM, arden liu [EMAIL PROTECTED] wrote:

 In my html, I have the following span to show upload percentage:
 span id=progressBarText0%/span

 I tried to update the percentage using the following javascript:
 $(#progressBarText).innerHTML = 76%;

 But it does not work. :(
 Thanks.
 Arden



[jQuery] How can I either clone just one class and children or append better html code

2008-05-27 Thread tripdragon

 have this code that works! But looks like butt. As well as that this
is a recipe for hell every-time I need to update it.
I had clone working on the generated html code from the Rails server
code. But in my simple tests the clone was cloning the class or id and
it then more just make clones of the clones. Woot. So it became a
power of 2 which as you know. ...

From my short reading I cannot find any tools to fix jquery to paste
code cleaner due to javascript restriction spacing..

script type=text/javascript
$(document).ready(function(){

  $('#addmore').click(function() {
$('#block').append('div id=blockh1BITE ME! /h1 div
class=eplisttable th tdTitle/td tdEpisodenumber/td
tdStatus/td tdWatched/td tdHave/td tdNext/td
tdPublished/td /thtr td input
id=episode_episode_attributes__title
name=episode[episode_attributes][][title] size=30 type=text / /
td td input id=episode_episode_attributes__episodenumber
name=episode[episode_attributes][][episodenumber] size=30
type=text / /td td select
id=episode_episode_attributes__status
name=episode[episode_attributes][][status]option
value=1Watching it/option option value=2Saw it/option/
select /td td input id=episode_episode_attributes__watched
name=episode[episode_attributes][][watched] type=checkbox
value=1 /input name=episode[episode_attributes][][watched]
type=hidden value=0 / /td td input
id=episode_episode_attributes__have name=episode[episode_attributes]
[][have] type=checkbox value=1 /input
name=episode[episode_attributes][][have] type=hidden value=0 /
/td td input id=episode_episode_attributes__next
name=episode[episode_attributes][][next] type=checkbox value=1 /
input name=episode[episode_attributes][][next] type=hidden
value=0 / /td td input
id=episode_episode_attributes__published
name=episode[episode_attributes][][published] type=checkbox
value=1 /input name=episode[episode_attributes][][published]
type=hidden value=0 / /td/tr/table h2Notes/h2 p
textarea cols=100 id=episode_episode_attributes__notes
name=episode[episode_attributes][][notes] rows=2/textarea /
pa href=# class=pukh2Remove ep from list/h2/a/div');
  });




$('.puk h2')
.livequery('click', function(event) {
$(this).parents('.eplist').remove();
return false;
});



});
/script


[jQuery] Re: Display loading image while alternate image loads.

2008-05-27 Thread Josh Nathanson
Hi Andy,

In regards to whether the file exists...I know you're using ColdFusion, is it 
possible to use the CF function FileExists in your CF code to determine if the 
jpg exists, and then maybe disable that option, or not show it at all?  That 
way it would degrade gracefully.

-- Josh
  - Original Message - 
  From: Dan G. Switzer, II 
  To: jquery-en@googlegroups.com 
  Sent: Tuesday, May 27, 2008 1:56 PM
  Subject: [jQuery] Re: Display loading image while alternate image loads.


  Andy,

   

  You can use the onerror event of an image to determine if an image loaded or 
not. Also, you could load the image using JS's Image object-that way you could 
display a loading image. Here's some example code:

   

  http://www.rgagnon.com/jsdetails/js-0083.html

   

  -Dan

   


--

  From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Andy 
Matthews
  Sent: Tuesday, May 27, 2008 4:50 PM
  To: [jQuery]
  Subject: [jQuery] Display loading image while alternate image loads.

   

  I have a default image loaded into an img tag with an id of specialImage. I 
also have a select box which displays a list of vehicles. The value of each 
option is a filename (75682.jpg, 75123.jpg, etc.).

   

  When the user selects a vehicle, I want to change the src of the img tag but 
I'm running into a few issues that I'm not sure how to get around.

   

  1) Because I'm not using an AJAX call, I don't know if the file actually 
exists on the server. A few images are then showing as broken which is a big no 
no.

   

  2) The images being loaded in aren't huge, but they might be 40k or so. 
Because I'm simply changing the src, I can't display a loading image while the 
requested image is loading.

   

  Are there ways around this? I'm thinking I could do an AJAX call to get the 
response headers for the file. When I trigger the AJAX call, I'd display the 
loading image. Then, if the response comes back 200, then I can display the 
actual file, if not, I can display a no image available image.

   

  Any thoughts on this method? Is there a better way to do this?

   

  

   

  Andy Matthews
  Senior ColdFusion Developer

  Office:  615.627.9747
  Fax:  615.467.6249

  www.dealerskins.com

   

  Total customer satisfaction is my number 1 priority! If you are not 
completely satisfied with the service I have provided, please let me know right 
away so I can correct the problem, or notify my manager Aaron West at [EMAIL 
PROTECTED]

   
image001.jpg

[jQuery] Re: Display loading image while alternate image loads.

2008-05-27 Thread Andy Matthews
Dan!
 
That works BEAUTIFULLY! Thanks for the tip...I'll be adding that one to my
toolbox. I never knew that was possible.

  _  

From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Dan G. Switzer, II
Sent: Tuesday, May 27, 2008 3:57 PM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Display loading image while alternate image loads.



Andy,

 

You can use the onerror event of an image to determine if an image loaded or
not. Also, you could load the image using JS's Image object-that way you
could display a loading image. Here's some example code:

 

http://www.rgagnon.com/jsdetails/js-0083.html

 

-Dan

 

  _  

From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Andy Matthews
Sent: Tuesday, May 27, 2008 4:50 PM
To: [jQuery]
Subject: [jQuery] Display loading image while alternate image loads.

 

I have a default image loaded into an img tag with an id of specialImage.
I also have a select box which displays a list of vehicles. The value of
each option is a filename (75682.jpg, 75123.jpg, etc.).

 

When the user selects a vehicle, I want to change the src of the img tag but
I'm running into a few issues that I'm not sure how to get around.

 

1) Because I'm not using an AJAX call, I don't know if the file actually
exists on the server. A few images are then showing as broken which is a big
no no.

 

2) The images being loaded in aren't huge, but they might be 40k or so.
Because I'm simply changing the src, I can't display a loading image while
the requested image is loading.

 

Are there ways around this? I'm thinking I could do an AJAX call to get the
response headers for the file. When I trigger the AJAX call, I'd display the
loading image. Then, if the response comes back 200, then I can display the
actual file, if not, I can display a no image available image.

 

Any thoughts on this method? Is there a better way to do this?

 



 

Andy Matthews
Senior ColdFusion Developer

Office:  615.627.9747
Fax:  615.467.6249

www.dealerskins.com http://www.dealerskins.com/ 

 

Total customer satisfaction is my number 1 priority! If you are not
completely satisfied with the service I have provided, please let me know
right away so I can correct the problem, or notify my manager Aaron West at
[EMAIL PROTECTED]

 

image001.jpg

[jQuery] Re: jQuery Cycle question

2008-05-27 Thread Bruce MacKay


Hello Mike,

Thanks for your interest.

A link is here...
http://ramosus.massey.ac.nz/jQuery.htm

Cheers/Bruce


At 12:24 a.m. 28/05/2008, you wrote:


 In its simplest form my problem is this.  Suppose I have two
 slideshows, A and B.  Slideshow A runs properly.  However, when I
 replace slideshow A with slideshow B through an ajax call, the
 captions associated with slideshow A are also shown along with those
 of slideshow B.  The images associated with each slideshow are not
 being confounded, just the captions that are fed into the ssoutput div.

How are you replacing the slideshow?  Are you stopping slideshow A
before starting slideshow B?  Can you post a link?




[jQuery] Re: Display loading image while alternate image loads.

2008-05-27 Thread Andy Matthews
Josh...if I was checking server side I wouldn't even have posted. However,
this is all client side so I need something for that end. Dan's suggestion
works flawlessly.
 
Thanks though.

  _  

From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Josh Nathanson
Sent: Tuesday, May 27, 2008 4:37 PM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Display loading image while alternate image loads.


Hi Andy,
 
In regards to whether the file exists...I know you're using ColdFusion, is
it possible to use the CF function FileExists in your CF code to determine
if the jpg exists, and then maybe disable that option, or not show it at
all?  That way it would degrade gracefully.
 
-- Josh

- Original Message - 
From: Dan G.  mailto:[EMAIL PROTECTED] Switzer, II 
To: jquery-en@googlegroups.com 
Sent: Tuesday, May 27, 2008 1:56 PM
Subject: [jQuery] Re: Display loading image while alternate image loads.


Andy,

 

You can use the onerror event of an image to determine if an image loaded or
not. Also, you could load the image using JS's Image object-that way you
could display a loading image. Here's some example code:

 

http://www.rgagnon.com/jsdetails/js-0083.html

 

-Dan

 

  _  

From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Andy Matthews
Sent: Tuesday, May 27, 2008 4:50 PM
To: [jQuery]
Subject: [jQuery] Display loading image while alternate image loads.

 

I have a default image loaded into an img tag with an id of specialImage.
I also have a select box which displays a list of vehicles. The value of
each option is a filename (75682.jpg, 75123.jpg, etc.).

 

When the user selects a vehicle, I want to change the src of the img tag but
I'm running into a few issues that I'm not sure how to get around.

 

1) Because I'm not using an AJAX call, I don't know if the file actually
exists on the server. A few images are then showing as broken which is a big
no no.

 

2) The images being loaded in aren't huge, but they might be 40k or so.
Because I'm simply changing the src, I can't display a loading image while
the requested image is loading.

 

Are there ways around this? I'm thinking I could do an AJAX call to get the
response headers for the file. When I trigger the AJAX call, I'd display the
loading image. Then, if the response comes back 200, then I can display the
actual file, if not, I can display a no image available image.

 

Any thoughts on this method? Is there a better way to do this?

 



 

Andy Matthews
Senior ColdFusion Developer

Office:  615.627.9747
Fax:  615.467.6249

www.dealerskins.com http://www.dealerskins.com/ 

 

Total customer satisfaction is my number 1 priority! If you are not
completely satisfied with the service I have provided, please let me know
right away so I can correct the problem, or notify my manager Aaron West at
[EMAIL PROTECTED]

 

image001.jpg

[jQuery] Re: Image Map Help - Map Hilight

2008-05-27 Thread [EMAIL PROTECTED]

Good call on the co-ordinates ... atfer you mentioned it I noticed
that the editor was stripping them out.  S I had to 'disable rich
text' and that did the trick.

One last question I have is do you know why I am getting all of the
empty space at the bottom of the image? ... 
http://www.360painting.com/franchise_locations.cfm

On May 26, 7:18 pm, Hamish Campbell [EMAIL PROTECTED] wrote:
 I'm guessing this isn't anything to do with jQuery - can't find any
 references to the library in your source code.

 Nevertheless, had a look at the page - your image maps look like this:

 map name=Map id=Maparea href=/# /area href=/# /area
 href=#texas alt=Texas /area href=#floridabrowardcounty
 alt=Florida /area href=#georgia alt=Georgia /area
 href=#alaska alt=alaska /area href=#oregon alt=Oregon /area 
 href=/# /area href=#hawaii alt=Hawaii /area

 href=#washington alt=Washington /...

 Normally you'd expect co-ordinates within those area tags - that's why
 the image map isn't working. Where did you get the script?

 Cheers,

 Hamish

 On May 27, 11:13 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
 wrote:



  I am using Drupal for CMS and am having trouble with my image working
  properly -http://www.360painting.com/node/33.  The image is showing
  correctly, but the hot spots are not there (hmm?).  I figured I did
  something wrong with my file, so I posted the demo of the usa map that
  comes with the download -http://www.360painting.com/node/32-and it
  is still not cooperating.

  Any advice and or tips would be great!  Thanks.

  L- Hide quoted text -

 - Show quoted text -


[jQuery] Load specific id on click

2008-05-27 Thread IschaGast

I have a page with an archive of all newsletters:
http://ischagast.nl/janhekmanschool/nieuwsbrief/archief/

What I want is that when clicking a month the results of that month
appear under the months just like this site:
http://loweblog.com/archives/

I thought building that with jquery would be simple, something like
this:

$('#content_main div.weblog_archive li a').click(function() {
$('div.article').load(this.href);
return false
});

This works good but I only want to load the div.article and thats
something I could not get to work.
I thought maybe something like this could work but it does not:

.load(this.href + div.article);

What works?


[jQuery] Re: load() function in synchronous manner.

2008-05-27 Thread Karl Rudd

http://docs.jquery.com/Ajax/jQuery.ajaxSetup

Karl Rudd

On Wed, May 28, 2008 at 12:31 AM, Arun Kumar
[EMAIL PROTECTED] wrote:

 Not this case, I want to know how to use it synchronously.

 On May 27, 4:47 pm, Karl Rudd [EMAIL PROTECTED] wrote:
 Ok that's nothing to do with sync vs async. As I said, some examples
 of the code you're using would be helpful.

 Karl Rudd

 On Tue, May 27, 2008 at 9:14 PM, Arun Kumar

 [EMAIL PROTECTED] wrote:

  How can I use this load() function to load a page in sync?

  In IE, Object doesn't support this method or property.

  On May 27, 3:52 pm, Karl Rudd [EMAIL PROTECTED] wrote:
  If you're getting errors it usually means something is working in a
  different way it was meant to work. What sort of errors are you
  getting? Some examples of the code would be helpful.

  Karl Rudd

  On Tue, May 27, 2008 at 3:32 PM, Arun Kumar

  [EMAIL PROTECTED] wrote:

   I know.

   The reason for using this is, I am loading a page using load()
   function. Then I am performing some operations on the fields in that
   page. If the load function is used to load in asynchronous manner, I
   will get some errors in IE.

   This is the reason for loading it in sync.

   How can I use this load() function to load a page in sync?

   On May 27, 2:42 am, Karl Rudd [EMAIL PROTECTED] wrote:
   Yes but the more important question to ask is why do you want to load
   something synchronously. Bear in mind that loading something
   synchronously will lock the _entire_ browser up until it's finished.
   (At least that's been my impression of why it's not used).

   Karl Rudd

   On Tue, May 27, 2008 at 1:54 AM, Arun Kumar

   [EMAIL PROTECTED] wrote:

Can I use jQuery load() function to load a dynamic page in 
synchronous
manner? (async: false)



[jQuery] Re: load() function in synchronous manner.

2008-05-27 Thread Karl Rudd

Woops sorry, hit Send too soon.

http://docs.jquery.com/Ajax/jQuery.ajaxSetup

And the options are defined here, in the Options tab:

http://docs.jquery.com/Ajax/jQuery.ajax#options

The $.ajaxSetup() call applies to all AJAX based calls after that,
until they're changed.

Karl Rudd

On Wed, May 28, 2008 at 12:31 AM, Arun Kumar
[EMAIL PROTECTED] wrote:

 Not this case, I want to know how to use it synchronously.

 On May 27, 4:47 pm, Karl Rudd [EMAIL PROTECTED] wrote:
 Ok that's nothing to do with sync vs async. As I said, some examples
 of the code you're using would be helpful.

 Karl Rudd

 On Tue, May 27, 2008 at 9:14 PM, Arun Kumar

 [EMAIL PROTECTED] wrote:

  How can I use this load() function to load a page in sync?

  In IE, Object doesn't support this method or property.

  On May 27, 3:52 pm, Karl Rudd [EMAIL PROTECTED] wrote:
  If you're getting errors it usually means something is working in a
  different way it was meant to work. What sort of errors are you
  getting? Some examples of the code would be helpful.

  Karl Rudd

  On Tue, May 27, 2008 at 3:32 PM, Arun Kumar

  [EMAIL PROTECTED] wrote:

   I know.

   The reason for using this is, I am loading a page using load()
   function. Then I am performing some operations on the fields in that
   page. If the load function is used to load in asynchronous manner, I
   will get some errors in IE.

   This is the reason for loading it in sync.

   How can I use this load() function to load a page in sync?

   On May 27, 2:42 am, Karl Rudd [EMAIL PROTECTED] wrote:
   Yes but the more important question to ask is why do you want to load
   something synchronously. Bear in mind that loading something
   synchronously will lock the _entire_ browser up until it's finished.
   (At least that's been my impression of why it's not used).

   Karl Rudd

   On Tue, May 27, 2008 at 1:54 AM, Arun Kumar

   [EMAIL PROTECTED] wrote:

Can I use jQuery load() function to load a dynamic page in 
synchronous
manner? (async: false)



[jQuery] Re: :contains ... troubling behavior

2008-05-27 Thread Karl Swedberg


Hi there,

I suspect that the problem has to do with putting an HTML string  
inside the contains parens, when it is supposed to take only text.  
Does it work if you just do $('a:contains(undo)') ?


--Karl

Karl Swedberg
www.englishrules.com
www.learningjquery.com




On May 27, 2008, at 2:06 PM, EuGeNe wrote:



Hi there,

I am troubled by the behavior of the :contains filter

I have an a tag

a class=undo href=/tag/poesie/5undo/a

I can select it with

$(a.undo) and play with the chain not problem e.g. $
(a.undo).remove() works fine

if I use

$(':contains(a href=/tag/sagesse/4 class=undoundo/a)')
or
$('a:contains(a href=/tag/sagesse/4 class=undoundo/a)')
or
$('a.undo:contains(a href=/tag/sagesse/4 class=undoundo/a)')

I get the same result pointing to the same tag but I can't play
with it i.e. whatever I do to it doens't have an impact on the DOM.

I am sure it is something I don't understand about JS or jQuery ...
could somebody enlighten me?

Thanks

EuGeNe -- http://www.3kwa.com




[jQuery] Re: Help learning...

2008-05-27 Thread Karl Swedberg


Actually, the only selector here that you shouldn't have quotes around  
is document. Can you try it without the quotes? Also, it looks like  
you might be missing a line at the end, although it might be a copy/ 
paste error. Try this:


$(document).ready(function() {
$(#image).hover(
 function () {
   $(li:hidden:first).fadeIn(slow));
 },
 function () {
   $(li).fadeOut(slow).remove();
 }
   );
});


--Karl

Karl Swedberg
www.englishrules.com
www.learningjquery.com




On May 27, 2008, at 4:05 PM, Aaron wrote:



Here is the exact code exactly copied and pasted from my file to here:

$(document).ready(function() {
$(#image).hover(
 function () {
   $(li:hidden:first).fadeIn(slow));
 },
 function () {
   $(li).fadeOut(slow).remove();
 }
   );

On May 27, 3:24 pm, Josh Nathanson [EMAIL PROTECTED] wrote:

Your selectors need quotes around them:

$(li:hidden:first).fadeIn(slow);

etc.

-- Josh



- Original Message -
From: Aaron [EMAIL PROTECTED]
To: jQuery (English) jquery-en@googlegroups.com
Sent: Tuesday, May 27, 2008 11:31 AM
Subject: [jQuery] Re: Help learning...

I been playing around with the hover and fadeIn and fadeOut functions
in jquery and I can't get them working on my website(NOTE:website is
not online yet still working on the website). I learned javascript  
and

I do have programming background.
I don't know what I am exactly doing wrong.

Here is what I have so far:

$(document).ready(function() {
$(div#image).hover(
  function () {
   $(li:hidden:first).fadeIn(slow));
  },
  function () {
$(li).fadeOut(slow).remove();
  }
);

this was just for playing around.  I added div#image there to  
indicate

it had css properties and it's an image and is called image  in css.
But what I put there was #image .

in here I was trying to just get an example to work which it failed I
made a list in my html doc and I made a javascript file and added the
script in with the script html tag ect and also added the css and
the jquery javascript in my html doc.

this script was supposed to fade in a list when my mouse is over the
div#image  which dosen't I see the list and it's displayed above the
image and is visable. so I tried to use the hidden function but it
failed and didn't make any difference.

is there somthing I am missing??

On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:

Hi I am currently building a website. I am trying to use the hover
and fadein and fadeout functions from jquery.



I don't have a full understanding of it.


I plan to make a new file that is a javascript file that will  
constain
all javascripts of my webpage in that file. I have my html file in  
one

file and have one css file for the webpage.


What I am trying to make right now is have the users main image  
shown
on the html page meaning the main page of the users webpage. I  
want to

have the users user there mouse to put over the image of them which
would then fade in a table with all their pictures that they
uploaded.
and if the mouse goes off the persons image and or the faded in  
table

it would then fade out.



that's what I want so far.



I don't know how to use hoever and the fadein and fade out
functions all together and how It would fade in a table or at least
fade in a image that I created that would be a background for where
the images would get displayed like a photo album ect.



if anyone can give me an example code of what is needed for hover to
work.



I know hoever(this here would be when the mouse is over the
element,this is when the mouse goes off the element the fade out  
ect.)


but how can I have it when the mouse is over tell the computer to  
fade

in a table or a image that will have the other images the user
uploaded to appear in that table or image.- Hide quoted text -


- Show quoted text -




[jQuery] superfish - drop down menu not displaying in IE6

2008-05-27 Thread jquery newbie

Hi Joel,

Great plugin. Thanks for sharing and supporting it!

I'm having a problem with the menu isn't dropping down in IE6 -- you
can see the problem in http://best-learn-spanish.com/s/index2.php

However, everything is working fine in Firefox.

I tried adding the bgiframe code but perhaps I missed something?

BTW, I tried changing the call to just .nav but then I get a
javascript error in IE6: serial is not an object and the error: el has
no properties when I hovered over a menu item in firefox.

Thus, I changed my superfish call back to jQuery(ul.nav)...

It probably has something to do with the structure of my html and/or
the css. Since you're more familiar with superfish, I thought that you
might be able to spot the error quickly?

Thanks,

jquery newbie



[jQuery] 1.2.5 and 1.2.6 not working at all for me - what am I missing?

2008-05-27 Thread kape

OK, I'm sure that someone would have mentioned that the latest
releases don't work, so that can't be it.  It's obvious that I'm
missing something.

I've been using jQuery 1.2.3 for months now, and today I wanted to use
the ui.slider plugin which requires offsetWidth() which is not in
1.2.3.  So I figured I'd just download the latest release, i.e. 1.2.6
and be done with it.  I did just that, but when I ran my app, there
were a whole bunch of JS errors.  I figured that's to be expected, my
code isn't perfect.  So I started debuging them.  So far, I'm still
trying to debug the very first one.

I have something as simple as:

jQuery(document).ready(function() {
  alert(jQuery('body').html());
});

If I use 1.2.3 everything works and onLoad I get the html of the body
element.  If I change the one line to 1.2.5 or 1.2.6, I get an alert
with undefined.  The reason I'm using jQuery() instead of $() is
that I am also using prototype for their portal plugin.  I wish I
wasn't but the jQuery verion just isn't cutting it yet.  And yes, I
have the jQuery.noConflict(); line first in my JS code.

So, what am I missing?  Do I need to download any other file besides
jquery-1.2.5.pack.js for example?  Are the new releases not working
with prototype?  Are they using different syntax?  I mean, I assume
that if the new releases would have such drastic changes, they
wouldn't be 1.2.6 they would be 2.0.

Anyway, hopefully someone can point out whatever it is that I'm
missing here.

Thanks,

Kape


[jQuery] jcarousel - circular problem going backwards on initial load

2008-05-27 Thread ericHurst

For some reason, when my page first loads the carousel, the prev arrow
is unusable until the user has clicked on the next arrow. After
clicking the next arrow, they user is able to click the prev arrow to
their hearts content. I noticed on the 'circular' example on sorgalla
that this is not an issue with the example. My .js is exactly the
same, I think. Also, I have tested without the other javascript on the
page. Any thoughts?

example at www.mycomicspage.com.

Thanks - Eric


[jQuery] Re: [validate] bug

2008-05-27 Thread Mike Nichols

Hm...sorry I guess I don't follow. The bug/patch I was talking about
was that if you set 'onsubmit=false' on the validate plugin the
'submitHandler' isn't called and so breaks ajax functionality...I am
not sure how the latest jquery release fixes this since the validate
code hasn't accomodated this scenario. Not sure what I'm missing.

On May 26, 3:42 pm, Jörn Zaefferer [EMAIL PROTECTED]
wrote:
 Please just update to jQuery 1.2.6.

 Jörn

 On Mon, May 26, 2008 at 7:59 PM, Mike Nichols [EMAIL PROTECTED] wrote:

  Thanks Jörn,
  Does this mean I need to resubmit the patch to dev.jquery.com then?
  I'd be happy to do so as it fixes a showstopperbug.

  Mike

  On May 23, 1:41 am, Jörn Zaefferer [EMAIL PROTECTED]
  wrote:
  I'm currently wait for the result of the discussion about the change
  to attr. It looks like the 1.2.5 behaviour is intended - once that is
  settled, I'll update the validationpluginaccordingly and release
  1.3.1.

  About patches: I'd like to close down the issue part on
  plugins.jquery.com and stick with dev.jquery.com only. That didn't
  quite work out so far. Posting to this list of jquery-dev about open
  issues as a reminder definitely helps.

  Jörn

  On Thu, May 22, 2008 at 7:16 PM, Mike Nichols [EMAIL PROTECTED] wrote:

   There needs to be a check for value !== null in the attributeRules
   method of the jquery.validateplugin. It bombs otherwise when
   collecting the rules . Not sure if this is because of using the 1.2.5
   jq release.
   Also I have a patch herehttp://plugins.jquery.com/node/1667thatis
   three months old...do I need to submit this somewhere else to be
   considered? This patch lets forms get submitted via Formpluginwhen
   onsubmit='false'

   Thanks in advance!
   Mike


[jQuery] month not displaying in datepicker inside superfish menu

2008-05-27 Thread pedalpete

I'm trying to figure out what the layout for the datepicker looks like
in plain html so I can figure out why the month doesn't display when
the datepicker is inside of a superfish menu.

Rather than display the month and the year arrows in a single row, the
year and month arrows are displayed in seperate rows, and the month
text does not appear at all.

looking at the css file and datepicker.js files, it appears that the
month is held in an h2,
[code]
// set the title...
$('h2', 
this.context).html(Date.monthNames[this.displayedMonth] +
' ' + this.displayedYear);
[/code]

but even adding
[code]
h2 {
position: absolute;
top: 3px;
left: 3px;
}
[/code]

doesn't display the month anywhere on the page.

Anybody know why the month won't display in this context?

To see the page (not completely working at this location, but you can
see the issue, go to http://www.hearwhere.com/filterDates.php and
hover over where it says all dates in the grey search bar.
The superfish menu will dropdown revealing the datepicker.

Thanks
Pete


[jQuery] Re: 1.2.5 and 1.2.6 not working at all for me - what am I missing?

2008-05-27 Thread John Resig

What if you use jquery-1.2.6.js (not packed).

--John

On Wed, May 28, 2008 at 12:26 AM, kape [EMAIL PROTECTED] wrote:

 OK, I'm sure that someone would have mentioned that the latest
 releases don't work, so that can't be it.  It's obvious that I'm
 missing something.

 I've been using jQuery 1.2.3 for months now, and today I wanted to use
 the ui.slider plugin which requires offsetWidth() which is not in
 1.2.3.  So I figured I'd just download the latest release, i.e. 1.2.6
 and be done with it.  I did just that, but when I ran my app, there
 were a whole bunch of JS errors.  I figured that's to be expected, my
 code isn't perfect.  So I started debuging them.  So far, I'm still
 trying to debug the very first one.

 I have something as simple as:

 jQuery(document).ready(function() {
  alert(jQuery('body').html());
 });

 If I use 1.2.3 everything works and onLoad I get the html of the body
 element.  If I change the one line to 1.2.5 or 1.2.6, I get an alert
 with undefined.  The reason I'm using jQuery() instead of $() is
 that I am also using prototype for their portal plugin.  I wish I
 wasn't but the jQuery verion just isn't cutting it yet.  And yes, I
 have the jQuery.noConflict(); line first in my JS code.

 So, what am I missing?  Do I need to download any other file besides
 jquery-1.2.5.pack.js for example?  Are the new releases not working
 with prototype?  Are they using different syntax?  I mean, I assume
 that if the new releases would have such drastic changes, they
 wouldn't be 1.2.6 they would be 2.0.

 Anyway, hopefully someone can point out whatever it is that I'm
 missing here.

 Thanks,

 Kape



[jQuery] Re: superfish - drop down menu not displaying in IE6

2008-05-27 Thread Joel Birch

Hello,

I currently only had time for a quick scan of your code. Things seem
to be quite in order except that the nav class needs to be set on
the ul not the parent div. This will definitely cause the menu not to
function so try changing that and see how you go.

Also, you only need to apply the bgIframe if you suspect that your
submenus will need to overlap select form elements in places. Can I
ask you: does it seem like I need to make that clearer on the
documentation pages? Many people are adding it automatically as if it
is required. Please let me know if the docs are misleading in this
regard.

Cheers
Joel Birch.


[jQuery] Re: Grouping Definition list items

2008-05-27 Thread Jason Huck

Have you tried using .next() ? Something along these lines (untested):

$('dd.comments input[type=radio]').toggle(
function(){ $(this).next('dd.feedback').show(); },
function(){ $(this).next('dd.feedback').hide(); }
});

- jason



On May 27, 3:57 pm, macgregor [EMAIL PROTECTED] wrote:
 I have a survey marked up with a definition list like so:

 dl
         dtQuestion 1/dt
         ddAnswer 1input type=radio //dd
         dd class=commentsAnswer 2input type=radio //dd
         dd class=feedback
                 textarea/textarea
         /dd
         dtQuestion 2/dt
         ddAnswer 1input type=radio //dd
         ddAnswer 2input type=radio //dd
         dd class=commentsAnswer 3input type=radio //dd
         dd class=feedback
                 textarea/textarea
         /dd
 /dl

 Is there any way to select the dd elements for a particular dt? I
 would like to be able to show/hide the textarea when the radio button
 inside dd.comments is clicked/selected.


[jQuery] Re: Help learning...

2008-05-27 Thread Josh Nathanson


One other thing...there is an extra parenthesis:

$(li:hidden:first).fadeIn(slow)) -- remove that sucker!

-- Josh


- Original Message - 
From: Karl Swedberg [EMAIL PROTECTED]

To: jquery-en@googlegroups.com
Sent: Tuesday, May 27, 2008 3:31 PM
Subject: [jQuery] Re: Help learning...




Actually, the only selector here that you shouldn't have quotes around  
is document. Can you try it without the quotes? Also, it looks like  
you might be missing a line at the end, although it might be a copy/ 
paste error. Try this:


$(document).ready(function() {
$(#image).hover(
 function () {
   $(li:hidden:first).fadeIn(slow));
 },
 function () {
   $(li).fadeOut(slow).remove();
 }
   );
});


--Karl

Karl Swedberg
www.englishrules.com
www.learningjquery.com




On May 27, 2008, at 4:05 PM, Aaron wrote:



Here is the exact code exactly copied and pasted from my file to here:

$(document).ready(function() {
$(#image).hover(
 function () {
   $(li:hidden:first).fadeIn(slow));
 },
 function () {
   $(li).fadeOut(slow).remove();
 }
   );

On May 27, 3:24 pm, Josh Nathanson [EMAIL PROTECTED] wrote:

Your selectors need quotes around them:

$(li:hidden:first).fadeIn(slow);

etc.

-- Josh



- Original Message -
From: Aaron [EMAIL PROTECTED]
To: jQuery (English) jquery-en@googlegroups.com
Sent: Tuesday, May 27, 2008 11:31 AM
Subject: [jQuery] Re: Help learning...

I been playing around with the hover and fadeIn and fadeOut functions
in jquery and I can't get them working on my website(NOTE:website is
not online yet still working on the website). I learned javascript  
and

I do have programming background.
I don't know what I am exactly doing wrong.

Here is what I have so far:

$(document).ready(function() {
$(div#image).hover(
  function () {
   $(li:hidden:first).fadeIn(slow));
  },
  function () {
$(li).fadeOut(slow).remove();
  }
);

this was just for playing around.  I added div#image there to  
indicate

it had css properties and it's an image and is called image  in css.
But what I put there was #image .

in here I was trying to just get an example to work which it failed I
made a list in my html doc and I made a javascript file and added the
script in with the script html tag ect and also added the css and
the jquery javascript in my html doc.

this script was supposed to fade in a list when my mouse is over the
div#image  which dosen't I see the list and it's displayed above the
image and is visable. so I tried to use the hidden function but it
failed and didn't make any difference.

is there somthing I am missing??

On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:

Hi I am currently building a website. I am trying to use the hover
and fadein and fadeout functions from jquery.



I don't have a full understanding of it.


I plan to make a new file that is a javascript file that will  
constain
all javascripts of my webpage in that file. I have my html file in  
one

file and have one css file for the webpage.


What I am trying to make right now is have the users main image  
shown
on the html page meaning the main page of the users webpage. I  
want to

have the users user there mouse to put over the image of them which
would then fade in a table with all their pictures that they
uploaded.
and if the mouse goes off the persons image and or the faded in  
table

it would then fade out.



that's what I want so far.



I don't know how to use hoever and the fadein and fade out
functions all together and how It would fade in a table or at least
fade in a image that I created that would be a background for where
the images would get displayed like a photo album ect.



if anyone can give me an example code of what is needed for hover to
work.



I know hoever(this here would be when the mouse is over the
element,this is when the mouse goes off the element the fade out  
ect.)


but how can I have it when the mouse is over tell the computer to  
fade

in a table or a image that will have the other images the user
uploaded to appear in that table or image.- Hide quoted text -


- Show quoted text -




[jQuery] Re: beginner variable problem

2008-05-27 Thread Wizzud

$(document).ready(function(){
  var parags = $(#contests ul li p);
  $(#contests ul li span a).each(function(i){
  var parag_count = i;
  $(this).toggle(
  function(){
  parags.eq(parag_count).css(background, yellow);
  return false;
},
  function(){
  parags.eq(parag_count).css(background, none);
  return false;
}
);
});
});

An alternative (just one of many) ...

$(document).ready(function(){
  var paras = $(#contests ul li)
  .find('span a').each(function(i){
 var indx = i;
 $(this).toggle(
function(){ return paraBg(indx, 'yellow'); }
  , function(){ return paraBg(indx, 'none'); } );
}).end().find('p')
 , paraBg = function(indx, bg){
 paras.eq(indx).css(background, bg);
 return false;
   };
});

(untested)

On May 27, 5:12 pm, bobh [EMAIL PROTECTED] wrote:
 hi,

 I'm encountering a problem with a variable in a toggle event.

 see my example online here:http://www.allnighters.net/jq-issue/

 my js code:

 $(document).ready(function(){
 $(#contests ul li span a).toggle(
 function(){
 var parag_count = $(#contests ul li span 
 a).index(this);
 alert(parag_count);
 $(#contests ul li p:eq(+ parag_count 
 +)).css(background,
 yellow);
 return false;
 },
 function(){
 $(#contests ul li p:eq(+ parag_count 
 +)).css(background,
 none);
 return false;
 }
 );

 });

 and my html:
 div id=contests style=width: 400px; margin-left: 20px;
 ul
 li class=uneven
 spana href=#4x2 Karma Hotel Tickets/a/span
 pDeze wedstrijd loopt af op 23 April om 23u./p
 /li
 li class=even
 spana href=#5x2 F*uck Lany... Here's Stephan
 Bodzin/a/span
 pDeze wedstrijd loopt af op 23 April om 23u./p
 /li
 ...
 /ul
 /div

 the problem is that I don't know how to pass the 'parag_count'
 variable on to the 2nd function of the toggle event.

 thanks in advance.


[jQuery] Re: Help learning...

2008-05-27 Thread Aaron

I also should tell you I am using internet explorer 7 when doing these
tests ect.
thanks for the replies so far. To me it looks like it supposed to work
now, I notice what you guys pointed out were mistakes I made like that
extra ).  Anything else you can think of that may be preventing my
code to run.  My browser is not giving any erros but indicates the
script is running but the lower left hand corner saying done. I do
get  asked if I want to run a active x object and I clicked yes. I
don't  know what's really wrong I spent over 4 weeks on just trying to
get this to work.

On May 27, 7:05 pm, Josh Nathanson [EMAIL PROTECTED] wrote:
 One other thing...there is an extra parenthesis:

 $(li:hidden:first).fadeIn(slow)) -- remove that sucker!

 -- Josh



 - Original Message -
 From: Karl Swedberg [EMAIL PROTECTED]
 To: jquery-en@googlegroups.com
 Sent: Tuesday, May 27, 2008 3:31 PM
 Subject: [jQuery] Re: Help learning...

  Actually, the only selector here that you shouldn't have quotes around  
  is document. Can you try it without the quotes? Also, it looks like  
  you might be missing a line at the end, although it might be a copy/
  paste error. Try this:

  $(document).ready(function() {
  $(#image).hover(
       function () {
     $(li:hidden:first).fadeIn(slow));
       },
       function () {
         $(li).fadeOut(slow).remove();
       }
     );
  });

  --Karl
  
  Karl Swedberg
 www.englishrules.com
 www.learningjquery.com

  On May 27, 2008, at 4:05 PM, Aaron wrote:

  Here is the exact code exactly copied and pasted from my file to here:

  $(document).ready(function() {
  $(#image).hover(
       function () {
     $(li:hidden:first).fadeIn(slow));
       },
       function () {
         $(li).fadeOut(slow).remove();
       }
     );

  On May 27, 3:24 pm, Josh Nathanson [EMAIL PROTECTED] wrote:
  Your selectors need quotes around them:

  $(li:hidden:first).fadeIn(slow);

  etc.

  -- Josh

  - Original Message -
  From: Aaron [EMAIL PROTECTED]
  To: jQuery (English) jquery-en@googlegroups.com
  Sent: Tuesday, May 27, 2008 11:31 AM
  Subject: [jQuery] Re: Help learning...

  I been playing around with the hover and fadeIn and fadeOut functions
  in jquery and I can't get them working on my website(NOTE:website is
  not online yet still working on the website). I learned javascript  
  and
  I do have programming background.
  I don't know what I am exactly doing wrong.

  Here is what I have so far:

  $(document).ready(function() {
  $(div#image).hover(
        function () {
     $(li:hidden:first).fadeIn(slow));
        },
        function () {
          $(li).fadeOut(slow).remove();
        }
      );

  this was just for playing around.  I added div#image there to  
  indicate
  it had css properties and it's an image and is called image  in css.
  But what I put there was #image .

  in here I was trying to just get an example to work which it failed I
  made a list in my html doc and I made a javascript file and added the
  script in with the script html tag ect and also added the css and
  the jquery javascript in my html doc.

  this script was supposed to fade in a list when my mouse is over the
  div#image  which dosen't I see the list and it's displayed above the
  image and is visable. so I tried to use the hidden function but it
  failed and didn't make any difference.

  is there somthing I am missing??

  On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:
  Hi I am currently building a website. I am trying to use the hover
  and fadein and fadeout functions from jquery.

  I don't have a full understanding of it.

  I plan to make a new file that is a javascript file that will  
  constain
  all javascripts of my webpage in that file. I have my html file in  
  one
  file and have one css file for the webpage.

  What I am trying to make right now is have the users main image  
  shown
  on the html page meaning the main page of the users webpage. I  
  want to
  have the users user there mouse to put over the image of them which
  would then fade in a table with all their pictures that they
  uploaded.
  and if the mouse goes off the persons image and or the faded in  
  table
  it would then fade out.

  that's what I want so far.

  I don't know how to use hoever and the fadein and fade out
  functions all together and how It would fade in a table or at least
  fade in a image that I created that would be a background for where
  the images would get displayed like a photo album ect.

  if anyone can give me an example code of what is needed for hover to
  work.

  I know hoever(this here would be when the mouse is over the
  element,this is when the mouse goes off the element the fade out  
  ect.)

  but how can I have it when the mouse is over tell the computer to  
  fade
  in a table or a image that will have the other images the user
  uploaded to appear in that table or image.- Hide quoted text -

  - Show quoted text -- Hide quoted text 

[jQuery] Re: Help learning...

2008-05-27 Thread Aaron

Ok I done what you guys asked me to try and tried it and it didn't do
anything.  My list is still displayed on the html doc like a normal
list  and when my mouse goes over the image I get nothing. So first
off my list is not hidden to start off and when my mouse goes over the
image I get nothing fading in.
I removed the extra )  but I thought I needed it to end the function
input??

On May 27, 7:05 pm, Josh Nathanson [EMAIL PROTECTED] wrote:
 One other thing...there is an extra parenthesis:

 $(li:hidden:first).fadeIn(slow)) -- remove that sucker!

 -- Josh



 - Original Message -
 From: Karl Swedberg [EMAIL PROTECTED]
 To: jquery-en@googlegroups.com
 Sent: Tuesday, May 27, 2008 3:31 PM
 Subject: [jQuery] Re: Help learning...

  Actually, the only selector here that you shouldn't have quotes around  
  is document. Can you try it without the quotes? Also, it looks like  
  you might be missing a line at the end, although it might be a copy/
  paste error. Try this:

  $(document).ready(function() {
  $(#image).hover(
       function () {
     $(li:hidden:first).fadeIn(slow));
       },
       function () {
         $(li).fadeOut(slow).remove();
       }
     );
  });

  --Karl
  
  Karl Swedberg
 www.englishrules.com
 www.learningjquery.com

  On May 27, 2008, at 4:05 PM, Aaron wrote:

  Here is the exact code exactly copied and pasted from my file to here:

  $(document).ready(function() {
  $(#image).hover(
       function () {
     $(li:hidden:first).fadeIn(slow));
       },
       function () {
         $(li).fadeOut(slow).remove();
       }
     );

  On May 27, 3:24 pm, Josh Nathanson [EMAIL PROTECTED] wrote:
  Your selectors need quotes around them:

  $(li:hidden:first).fadeIn(slow);

  etc.

  -- Josh

  - Original Message -
  From: Aaron [EMAIL PROTECTED]
  To: jQuery (English) jquery-en@googlegroups.com
  Sent: Tuesday, May 27, 2008 11:31 AM
  Subject: [jQuery] Re: Help learning...

  I been playing around with the hover and fadeIn and fadeOut functions
  in jquery and I can't get them working on my website(NOTE:website is
  not online yet still working on the website). I learned javascript  
  and
  I do have programming background.
  I don't know what I am exactly doing wrong.

  Here is what I have so far:

  $(document).ready(function() {
  $(div#image).hover(
        function () {
     $(li:hidden:first).fadeIn(slow));
        },
        function () {
          $(li).fadeOut(slow).remove();
        }
      );

  this was just for playing around.  I added div#image there to  
  indicate
  it had css properties and it's an image and is called image  in css.
  But what I put there was #image .

  in here I was trying to just get an example to work which it failed I
  made a list in my html doc and I made a javascript file and added the
  script in with the script html tag ect and also added the css and
  the jquery javascript in my html doc.

  this script was supposed to fade in a list when my mouse is over the
  div#image  which dosen't I see the list and it's displayed above the
  image and is visable. so I tried to use the hidden function but it
  failed and didn't make any difference.

  is there somthing I am missing??

  On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:
  Hi I am currently building a website. I am trying to use the hover
  and fadein and fadeout functions from jquery.

  I don't have a full understanding of it.

  I plan to make a new file that is a javascript file that will  
  constain
  all javascripts of my webpage in that file. I have my html file in  
  one
  file and have one css file for the webpage.

  What I am trying to make right now is have the users main image  
  shown
  on the html page meaning the main page of the users webpage. I  
  want to
  have the users user there mouse to put over the image of them which
  would then fade in a table with all their pictures that they
  uploaded.
  and if the mouse goes off the persons image and or the faded in  
  table
  it would then fade out.

  that's what I want so far.

  I don't know how to use hoever and the fadein and fade out
  functions all together and how It would fade in a table or at least
  fade in a image that I created that would be a background for where
  the images would get displayed like a photo album ect.

  if anyone can give me an example code of what is needed for hover to
  work.

  I know hoever(this here would be when the mouse is over the
  element,this is when the mouse goes off the element the fade out  
  ect.)

  but how can I have it when the mouse is over tell the computer to  
  fade
  in a table or a image that will have the other images the user
  uploaded to appear in that table or image.- Hide quoted text -

  - Show quoted text -- Hide quoted text -

 - Show quoted text -


[jQuery] Re: Image Map Help - Map Hilight

2008-05-27 Thread Adam Weis
It looks like pressing ENTER in your CMS is inserting br / tags after each
set of coordinates.  You may have to remove all the spaces at the end of
each area tag or edit the HTML.

area shape=circle coords=347,46,12 href=#vermont alt=Vermontbr /
area shape=circle coords=371,31,12 href=#newhampshire alt=New
Hampshirebr /
area shape=circle coords=415,90,11 href=#rhodeisland alt=Rhode
Islandbr /
area shape=circle coords=415,67,12 href=#massachusetts
alt=Massachusettsbr /


Hope that helps.

-Adam

On Tue, May 27, 2008 at 6:08 PM, [EMAIL PROTECTED] [EMAIL PROTECTED]
wrote:


 Good call on the co-ordinates ... atfer you mentioned it I noticed
 that the editor was stripping them out.  S I had to 'disable rich
 text' and that did the trick.

 One last question I have is do you know why I am getting all of the
 empty space at the bottom of the image? ...
 http://www.360painting.com/franchise_locations.cfm

 On May 26, 7:18 pm, Hamish Campbell [EMAIL PROTECTED] wrote:
  I'm guessing this isn't anything to do with jQuery - can't find any
  references to the library in your source code.
 
  Nevertheless, had a look at the page - your image maps look like this:
 
  map name=Map id=Maparea href=/# /area href=/# /area
  href=#texas alt=Texas /area href=#floridabrowardcounty
  alt=Florida /area href=#georgia alt=Georgia /area
  href=#alaska alt=alaska /area href=#oregon alt=Oregon /area
 href=/# /area href=#hawaii alt=Hawaii /area
 
  href=#washington alt=Washington /...
 
  Normally you'd expect co-ordinates within those area tags - that's why
  the image map isn't working. Where did you get the script?
 
  Cheers,
 
  Hamish
 
  On May 27, 11:13 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
  wrote:
 
 
 
   I am using Drupal for CMS and am having trouble with my image working
   properly -http://www.360painting.com/node/33.  The image is showing
   correctly, but the hot spots are not there (hmm?).  I figured I did
   something wrong with my file, so I posted the demo of the usa map that
   comes with the download -http://www.360painting.com/node/32-and it
   is still not cooperating.
 
   Any advice and or tips would be great!  Thanks.
 
   L- Hide quoted text -
 
  - Show quoted text -



[jQuery] Re: jQuery Cycle question

2008-05-27 Thread malsup

 Hello Mike,

 Thanks for your interest.

 A link is here...http://ramosus.massey.ac.nz/jQuery.htm

 Cheers/Bruce


Since the first slideshow was never explicitly stopped you actually
have two running slideshows, one of which is cycling elements that are
no longer part of the DOM.  But that first slideshow still has its
'after' callback invoked and that's why you see two captions.  More
recent versions of the Cycle plugin automatically stop a running
slideshow if you start another one on the same container, so if you
upgrade your problem should go away.

Cheers.

Mike


[jQuery] Re: How can I either clone just one class and children or append better html code

2008-05-27 Thread Wizzud

Not entirely clear what is required to be cloned - the code you have
shouldn't really be cloned 'as is' because it has ids in it, which
would require a fair amount of manipulation to make it valid.
If you simply want to format it into a more readable/maintainable form
then, as an example...

var code = [
  'div id=block'
,   'h1BITE ME! /h1'
,   'div class=eplist'
, 'table'
,'th'// should this be a tr?
,  'tdTitle/td'
,  'tdEpisodenumber/td'

// ... etc, etc ...

, 'h2Remove ep from list/h2'
,   '/a'
, '/div'
].join('');

But, yes you can clone just one instance of a class, eg ...
$('.class:first').clone()

On May 27, 10:06 pm, tripdragon [EMAIL PROTECTED] wrote:
  have this code that works! But looks like butt. As well as that this
 is a recipe for hell every-time I need to update it.
 I had clone working on the generated html code from the Rails server
 code. But in my simple tests the clone was cloning the class or id and
 it then more just make clones of the clones. Woot. So it became a
 power of 2 which as you know. ...

 From my short reading I cannot find any tools to fix jquery to paste
 code cleaner due to javascript restriction spacing..

 script type=text/javascript
 $(document).ready(function(){

   $('#addmore').click(function() {
 $('#block').append('div id=blockh1BITE ME! /h1 div
 class=eplisttable th tdTitle/td tdEpisodenumber/td
 tdStatus/td tdWatched/td tdHave/td tdNext/td
 tdPublished/td /thtr td input
 id=episode_episode_attributes__title
 name=episode[episode_attributes][][title] size=30 type=text / /
 td td input id=episode_episode_attributes__episodenumber
 name=episode[episode_attributes][][episodenumber] size=30
 type=text / /td td select
 id=episode_episode_attributes__status
 name=episode[episode_attributes][][status]option
 value=1Watching it/option option value=2Saw it/option/
 select /td td input id=episode_episode_attributes__watched
 name=episode[episode_attributes][][watched] type=checkbox
 value=1 /input name=episode[episode_attributes][][watched]
 type=hidden value=0 / /td td input
 id=episode_episode_attributes__have name=episode[episode_attributes]
 [][have] type=checkbox value=1 /input
 name=episode[episode_attributes][][have] type=hidden value=0 /
 /td td input id=episode_episode_attributes__next
 name=episode[episode_attributes][][next] type=checkbox value=1 /input 
 name=episode[episode_attributes][][next] type=hidden

 value=0 / /td td input
 id=episode_episode_attributes__published
 name=episode[episode_attributes][][published] type=checkbox
 value=1 /input name=episode[episode_attributes][][published]
 type=hidden value=0 / /td/tr/table h2Notes/h2 p
 textarea cols=100 id=episode_episode_attributes__notes
 name=episode[episode_attributes][][notes] rows=2/textarea /
 pa href=# class=pukh2Remove ep from list/h2/a/div');
   });

 $('.puk h2')
 .livequery('click', function(event) {
 $(this).parents('.eplist').remove();
 return false;
 });

 });

 /script


[jQuery] Re: Help learning...

2008-05-27 Thread Josh Nathanson


Aaron -- run don't walk to get Firefox and the Firebug extension.  You 
should always use this combo to do your initial testing, then once it works 
ok, check out how IE6 and 7 are performing.  That probably would have saved 
you three weeks and six days of those four weeks.  It shows the exact error 
if there are any, and also you can log information to the console to show 
what is being returned from your selectors.


I wouldn't be surprised if your selector was not returning anything. 
Otherwise, I think that extra parenthesis would have thrown an error.  Can 
you maybe post your html markup so we can see if you have the selector 
correct.


-- Josh


- Original Message - 
From: Aaron [EMAIL PROTECTED]

To: jQuery (English) jquery-en@googlegroups.com
Sent: Tuesday, May 27, 2008 4:24 PM
Subject: [jQuery] Re: Help learning...



I also should tell you I am using internet explorer 7 when doing these
tests ect.
thanks for the replies so far. To me it looks like it supposed to work
now, I notice what you guys pointed out were mistakes I made like that
extra ).  Anything else you can think of that may be preventing my
code to run.  My browser is not giving any erros but indicates the
script is running but the lower left hand corner saying done. I do
get  asked if I want to run a active x object and I clicked yes. I
don't  know what's really wrong I spent over 4 weeks on just trying to
get this to work.

On May 27, 7:05 pm, Josh Nathanson [EMAIL PROTECTED] wrote:

One other thing...there is an extra parenthesis:

$(li:hidden:first).fadeIn(slow)) -- remove that sucker!

-- Josh



- Original Message -
From: Karl Swedberg [EMAIL PROTECTED]
To: jquery-en@googlegroups.com
Sent: Tuesday, May 27, 2008 3:31 PM
Subject: [jQuery] Re: Help learning...

 Actually, the only selector here that you shouldn't have quotes around
 is document. Can you try it without the quotes? Also, it looks like
 you might be missing a line at the end, although it might be a copy/
 paste error. Try this:

 $(document).ready(function() {
 $(#image).hover(
 function () {
 $(li:hidden:first).fadeIn(slow));
 },
 function () {
 $(li).fadeOut(slow).remove();
 }
 );
 });

 --Karl
 
 Karl Swedberg
www.englishrules.com
www.learningjquery.com

 On May 27, 2008, at 4:05 PM, Aaron wrote:

 Here is the exact code exactly copied and pasted from my file to here:

 $(document).ready(function() {
 $(#image).hover(
 function () {
 $(li:hidden:first).fadeIn(slow));
 },
 function () {
 $(li).fadeOut(slow).remove();
 }
 );

 On May 27, 3:24 pm, Josh Nathanson [EMAIL PROTECTED] wrote:
 Your selectors need quotes around them:

 $(li:hidden:first).fadeIn(slow);

 etc.

 -- Josh

 - Original Message -
 From: Aaron [EMAIL PROTECTED]
 To: jQuery (English) jquery-en@googlegroups.com
 Sent: Tuesday, May 27, 2008 11:31 AM
 Subject: [jQuery] Re: Help learning...

 I been playing around with the hover and fadeIn and fadeOut functions
 in jquery and I can't get them working on my website(NOTE:website is
 not online yet still working on the website). I learned javascript
 and
 I do have programming background.
 I don't know what I am exactly doing wrong.

 Here is what I have so far:

 $(document).ready(function() {
 $(div#image).hover(
 function () {
 $(li:hidden:first).fadeIn(slow));
 },
 function () {
 $(li).fadeOut(slow).remove();
 }
 );

 this was just for playing around. I added div#image there to
 indicate
 it had css properties and it's an image and is called image in css.
 But what I put there was #image .

 in here I was trying to just get an example to work which it failed I
 made a list in my html doc and I made a javascript file and added the
 script in with the script html tag ect and also added the css and
 the jquery javascript in my html doc.

 this script was supposed to fade in a list when my mouse is over the
 div#image which dosen't I see the list and it's displayed above the
 image and is visable. so I tried to use the hidden function but it
 failed and didn't make any difference.

 is there somthing I am missing??

 On May 26, 2:29 pm, Aaron [EMAIL PROTECTED] wrote:
 Hi I am currently building a website. I am trying to use the hover
 and fadein and fadeout functions from jquery.

 I don't have a full understanding of it.

 I plan to make a new file that is a javascript file that will
 constain
 all javascripts of my webpage in that file. I have my html file in
 one
 file and have one css file for the webpage.

 What I am trying to make right now is have the users main image
 shown
 on the html page meaning the main page of the users webpage. I
 want to
 have the users user there mouse to put over the image of them which
 would then fade in a table with all their pictures that they
 uploaded.
 and if the mouse goes off the persons image and or the faded in
 table
 it would then fade out.

 that's what I want so far.

 I don't know how to use hoever and the fadein and fade out
 functions all together and how It 

[jQuery] Re: my code only works under firefox

2008-05-27 Thread Michael Geary

Post a link to the broken page, along with a description of how to duplicate
the problem if there's anything more to it than just loading the page.



[jQuery] Re: jQuery Cycle question

2008-05-27 Thread Bruce MacKay


Thanks Mike, that did solve the problem.

Cheers/Bruce


At 11:25 a.m. 28/05/2008, you wrote:


 Hello Mike,

 Thanks for your interest.

 A link is here...http://ramosus.massey.ac.nz/jQuery.htm

 Cheers/Bruce


Since the first slideshow was never explicitly stopped you actually
have two running slideshows, one of which is cycling elements that are
no longer part of the DOM.  But that first slideshow still has its
'after' callback invoked and that's why you see two captions.  More
recent versions of the Cycle plugin automatically stop a running
slideshow if you start another one on the same container, so if you
upgrade your problem should go away.

Cheers.

Mike




[jQuery] Re: superfish - drop down menu not displaying in IE6

2008-05-27 Thread jquery newbie

Hi Joel,

Thanks for your quick reply. That's makes sense. Now my code is ul
class=nav and it's working fine in both IE6 and FF.

I added the bgiframe just in case the menu was blocked by the
background image. Also, on this page, I was having problems with the
menu blocking the podcast player : 
http://www.best-learn-spanish.com/s/listen.php?catid=28

and it seems like the bgiframe fixed that problem in IE6 but not in
FF. Any ideas for fixing it in FF?

Thanks again,

jdl

Joel Birch wrote:
 Hello,

 I currently only had time for a quick scan of your code. Things seem
 to be quite in order except that the nav class needs to be set on
 the ul not the parent div. This will definitely cause the menu not to
 function so try changing that and see how you go.

 Also, you only need to apply the bgIframe if you suspect that your
 submenus will need to overlap select form elements in places. Can I
 ask you: does it seem like I need to make that clearer on the
 documentation pages? Many people are adding it automatically as if it
 is required. Please let me know if the docs are misleading in this
 regard.

 Cheers
 Joel Birch.


[jQuery] Re: How can I either clone just one class and children or append better html code

2008-05-27 Thread tripdragon

sweet the :first did the trick. constantly reformatting the code drove
me bonkers



On May 27, 7:42 pm, Wizzud [EMAIL PROTECTED] wrote:
 Not entirely clear what is required to be cloned - the code you have
 shouldn't really be cloned 'as is' because it has ids in it, which
 would require a fair amount of manipulation to make it valid.
 If you simply want to format it into a more readable/maintainable form
 then, as an example...

 var code = [
   'div id=block'
 ,   'h1BITE ME! /h1'
 ,   'div class=eplist'
 ,     'table'
 ,        'th'    // should this be a tr?
 ,          'tdTitle/td'
 ,          'tdEpisodenumber/td'

 // ... etc, etc ...

 ,     'h2Remove ep from list/h2'
 ,   '/a'
 , '/div'
 ].join('');

 But, yes you can clone just one instance of a class, eg ...
 $('.class:first').clone()

 On May 27, 10:06 pm, tripdragon [EMAIL PROTECTED] wrote:

   have this code that works! But looks like butt. As well as that this
  is a recipe for hell every-time I need to update it.
  I had clone working on the generated html code from the Rails server
  code. But in my simple tests the clone was cloning the class or id and
  it then more just make clones of the clones. Woot. So it became a
  power of 2 which as you know. ...

  From my short reading I cannot find any tools to fix jquery to paste
  code cleaner due to javascript restriction spacing..

  script type=text/javascript
  $(document).ready(function(){

    $('#addmore').click(function() {
  $('#block').append('div id=blockh1BITE ME! /h1 div
  class=eplisttable th tdTitle/td tdEpisodenumber/td
  tdStatus/td tdWatched/td tdHave/td tdNext/td
  tdPublished/td /thtr td input
  id=episode_episode_attributes__title
  name=episode[episode_attributes][][title] size=30 type=text / /
  td td input id=episode_episode_attributes__episodenumber
  name=episode[episode_attributes][][episodenumber] size=30
  type=text / /td td select
  id=episode_episode_attributes__status
  name=episode[episode_attributes][][status]option
  value=1Watching it/option option value=2Saw it/option/
  select /td td input id=episode_episode_attributes__watched
  name=episode[episode_attributes][][watched] type=checkbox
  value=1 /input name=episode[episode_attributes][][watched]
  type=hidden value=0 / /td td input
  id=episode_episode_attributes__have name=episode[episode_attributes]
  [][have] type=checkbox value=1 /input
  name=episode[episode_attributes][][have] type=hidden value=0 /
  /td td input id=episode_episode_attributes__next
  name=episode[episode_attributes][][next] type=checkbox value=1 
  /input name=episode[episode_attributes][][next] type=hidden

  value=0 / /td td input
  id=episode_episode_attributes__published
  name=episode[episode_attributes][][published] type=checkbox
  value=1 /input name=episode[episode_attributes][][published]
  type=hidden value=0 / /td/tr/table h2Notes/h2 p
  textarea cols=100 id=episode_episode_attributes__notes
  name=episode[episode_attributes][][notes] rows=2/textarea /
  pa href=# class=pukh2Remove ep from list/h2/a/div');
    });

  $('.puk h2')
      .livequery('click', function(event) {
          $(this).parents('.eplist').remove();
          return false;
      });

  });

  /script


[jQuery] Re: Image Map Help - Map Hilight

2008-05-27 Thread [EMAIL PROTECTED]

Thanks Adam, it seems to through the br in there too.

On May 27, 5:54 pm, Adam Weis [EMAIL PROTECTED] wrote:
 It looks like pressing ENTER in your CMS is inserting br / tags after each
 set of coordinates.  You may have to remove all the spaces at the end of
 each area tag or edit the HTML.

 area shape=circle coords=347,46,12 href=#vermont alt=Vermontbr /
 area shape=circle coords=371,31,12 href=#newhampshire alt=New
 Hampshirebr /
 area shape=circle coords=415,90,11 href=#rhodeisland alt=Rhode
 Islandbr /
 area shape=circle coords=415,67,12 href=#massachusetts
 alt=Massachusettsbr /

 Hope that helps.

 -Adam

 On Tue, May 27, 2008 at 6:08 PM, [EMAIL PROTECTED] [EMAIL PROTECTED]
 wrote:





  Good call on the co-ordinates ... atfer you mentioned it I noticed
  that the editor was stripping them out.  S I had to 'disable rich
  text' and that did the trick.

  One last question I have is do you know why I am getting all of the
  empty space at the bottom of the image? ...
 http://www.360painting.com/franchise_locations.cfm

  On May 26, 7:18 pm, Hamish Campbell [EMAIL PROTECTED] wrote:
   I'm guessing this isn't anything to do with jQuery - can't find any
   references to the library in your source code.

   Nevertheless, had a look at the page - your image maps look like this:

   map name=Map id=Maparea href=/# /area href=/# /area
   href=#texas alt=Texas /area href=#floridabrowardcounty
   alt=Florida /area href=#georgia alt=Georgia /area
   href=#alaska alt=alaska /area href=#oregon alt=Oregon /area
  href=/# /area href=#hawaii alt=Hawaii /area

   href=#washington alt=Washington /...

   Normally you'd expect co-ordinates within those area tags - that's why
   the image map isn't working. Where did you get the script?

   Cheers,

   Hamish

   On May 27, 11:13 am, [EMAIL PROTECTED] [EMAIL PROTECTED]
   wrote:

I am using Drupal for CMS and am having trouble with my image working
properly -http://www.360painting.com/node/33.  The image is showing
correctly, but the hot spots are not there (hmm?).  I figured I did
something wrong with my file, so I posted the demo of the usa map that
comes with the download -http://www.360painting.com/node/32-andit
is still not cooperating.

Any advice and or tips would be great!  Thanks.

L- Hide quoted text -

   - Show quoted text -- Hide quoted text -

 - Show quoted text -


[jQuery] Re: array problem

2008-05-27 Thread Vallard

Excellent Ariel!  Thank you.  Just one issue I think you had one
extra } in there, but this worked perfect for me!  Thank you very
much!
Vallard

On May 27, 12:23 pm, Ariel Flesler [EMAIL PROTECTED] wrote:
 $(document).ready(function(){
$('#home, #contact, #gallery, #about').hover(
 function(){
 $(this).stop().animate({marginTop: -5px});
 },
 function(){
 $(this).stop().animate({marginTop: 0px});
 }
 });

 });

 You can use a class selector instead of the ids.

 --
 Ariel Fleslerhttp://flesler.blogspot.com

 On 27 mayo, 14:13, Vallard [EMAIL PROTECTED] wrote:

  I'm trying to run the following code:

  var nav = [ #home, #contact, #gallery, #about ];
  $(document).ready(function(){
  for(var i = 0; i  nav.length; i++){
  $(nav[i]).mouseover(function(){
  $(nav[i]).animate({
  marginTop: -5px
  });
  });
  $(nav[i]).mouseout(function(){
  $(nav[i]).animate({
  marginTop: 0px
  });
  });
  }

  });

  however, those effects never get added.  If I don't do the for loop
  and do each item individually it works fine.  Do I just have a dumb
  bug in here?

  Thanks for any help, and thanks for developing this great lib.


[jQuery] Re: array problem

2008-05-27 Thread Ariel Flesler

Yes, sorry. Glad it helped.

--
Ariel Flesler
http://flesler.blogspot.com


On 27 mayo, 20:42, Vallard [EMAIL PROTECTED] wrote:
 Excellent Ariel!  Thank you.  Just one issue I think you had one
 extra } in there, but this worked perfect for me!  Thank you very
 much!
 Vallard

 On May 27, 12:23 pm, Ariel Flesler [EMAIL PROTECTED] wrote:



  $(document).ready(function(){
     $('#home, #contact, #gallery, #about').hover(
          function(){
              $(this).stop().animate({marginTop: -5px});
          },
          function(){
              $(this).stop().animate({marginTop: 0px});
          }
      });

  });

  You can use a class selector instead of the ids.

  --
  Ariel Fleslerhttp://flesler.blogspot.com

  On 27 mayo, 14:13, Vallard [EMAIL PROTECTED] wrote:

   I'm trying to run the following code:

   var nav = [ #home, #contact, #gallery, #about ];
   $(document).ready(function(){
       for(var i = 0; i  nav.length; i++){
           $(nav[i]).mouseover(function(){
               $(nav[i]).animate({
                   marginTop: -5px
               });
           });
           $(nav[i]).mouseout(function(){
               $(nav[i]).animate({
                   marginTop: 0px
               });
           });
       }

   });

   however, those effects never get added.  If I don't do the for loop
   and do each item individually it works fine.  Do I just have a dumb
   bug in here?

   Thanks for any help, and thanks for developing this great lib.- Ocultar 
   texto de la cita -

 - Mostrar texto de la cita -


[jQuery] thoughts ? Announcing AJAX Libraries API: Speed up your Ajax apps with Google’s infrastructure

2008-05-27 Thread Scottus

http://ajaxian.com/archives/announcing-ajax-libraries-api-speed-up-your-ajax-apps-with-googles-infrastructure

http://code.google.com/apis/ajaxlibs/

I just got to announce the Google AJAX Libraries API which exists to
make Ajax applications that use popular frameworks such as Prototype,
Script.aculo.us, jQuery, Dojo, and MooTools faster and easier for
developers.

Whenever I wrote an application that uses one of these frameworks, I
would picture a user accessing my application, having 33 copies of
prototype.js, and yet downloading yet another one from my site. It
would make me squirm. What a waste!

At the same time, I was reading research from Steve Souders and others
in the performance space that showed just how badly we are doing at
providing these libraries. As developers we should setup the caching
correctly so we only send that file down when absolutely necessary. We
should also gzip the files to browsers that accept them. Oh, and we
should probably use a minified version to get that little bit more out
of the system. We should also follow the practice of versioning the
files nicely. Instead, we find a lot of jquery.js files with no
version, that often have little tweaks added to the end of the fils,
and caching is not setup well at all so the file keeps getting sent
down for no reason.

When I joined Google I realised that we could help out here. What if
we hosted these files? Everyone would see some instant benefits:

* Caching can be done correctly, and once, by us... and developers
have to do nothing
* Gzip works
* We can serve minified versions
* The files are hosted by Google which has a distributed CDN at
various points around the world, so the files are close to the user
* The servers are fast
* By using the same URLs, if a critical mass of applications use
the Google infrastructure, when someone comes to your application the
file may already be loaded!
* A subtle performance (and security) issue revolves around the
headers that you send up and down. Since you are using a special
domain (NOTE: not google.com!), no cookies or other verbose headers
will be sent up, saving precious bytes.

This is why we have released the AJAX Libraries API. We sat down with
a few of the popular open source frameworks and they were all excited
about the idea, so we got to work with them, and now you have access
to their great work from our servers.

Details of what we are launching

You can access the libraries in two ways, and either way we take the
pain out of hosting the libraries, correctly setting cache headers,
staying up to date with the most recent bug fixes, etc.

The first way to access the scripts is simply be using a standard
script src=.. tag that points to the correct place.

For example, to load Prototype version 1.6.0.2 you would place the
following in your HTML:
PLAIN TEXT
HTML:

   1.

   2.
  script 
src=http://ajax.googleapis.com/ajax/libs/prototype/1.6.0.2/prototype.js;/script
   3.


The second way to access the scripts is via the Google AJAX API
Loader's google.load() method.

Here is an example using that technique to load and use jQuery for a
simple search mashup:
PLAIN TEXT
HTML:

   1.

   2.
  script src=http://www.google.com/jsapi;/script
   3.
  script
   4.
// Load jQuery
   5.
google.load(jquery, 1);
   6.

   7.
// on page load complete, fire off a jQuery json-p query
   8.
// against Google web search
   9.
google.setOnLoadCallback(function() {
  10.
  
$.getJSON(http://ajax.googleapis.com/ajax/services/search/web?q=google;v=1.0;callback=?;,
  11.

  12.
// on search completion, process the results
  13.
function (data) {
  14.
  if (data.responseDate.results 
  15.
  data.responseDate.results.length0) {
  16.
renderResults(data.responseDate.results);
  17.
  }
  18.
});
  19.
  });
  20.
  /script
  21.


You will notice that the version used was just 1. This is a smart
versioning feature that allows your application to specify a desired
version with as much precision as it needs. By dropping version
fields, you end up wild carding a field. For instance, consider a set
of versions: 1.9.1, 1.8.4, 1.8.2.

Specifying a version of 1.8.2 will select the obvious version. This
is because a fully specified version was used. Specifying a version of
1.8 would select version 1.8.4 since this is the highest versioned
release in the 1.8 branch. For much the same reason, a request for 1
will end up loading version 1.9.1.

Note, these versioning semantics work the same way when using
google.load and when using direct script urls.

By default, the JavaScript that gets sent back by the loader will be
minified, if there is a version supported. Thus, for the example above
we would return the minified version of jQuery. If you specifically
want the raw JavaScript itself, you can add the uncompressed

[jQuery] Re: 1.2.5 and 1.2.6 not working at all for me - what am I missing?

2008-05-27 Thread Victor

Kape:

Just read your post again. You are using prototype. I believe that it
conflicts with 1.2.5 and 1.2.6.

Victor

On May 27, 5:26 pm, kape [EMAIL PROTECTED] wrote:
 OK, I'm sure that someone would have mentioned that the latest
 releases don't work, so that can't be it.  It's obvious that I'm
 missing something.

 I've been using jQuery 1.2.3 for months now, and today I wanted to use
 the ui.slider plugin which requires offsetWidth() which is not in
 1.2.3.  So I figured I'd just download the latest release, i.e. 1.2.6
 and be done with it.  I did just that, but when I ran my app, there
 were a whole bunch of JS errors.  I figured that's to be expected, my
 code isn't perfect.  So I started debuging them.  So far, I'm still
 trying to debug the very first one.

 I have something as simple as:

 jQuery(document).ready(function() {
   alert(jQuery('body').html());

 });

 If I use 1.2.3 everything works and onLoad I get the html of the body
 element.  If I change the one line to 1.2.5 or 1.2.6, I get an alert
 with undefined.  The reason I'm using jQuery() instead of $() is
 that I am also using prototype for their portal plugin.  I wish I
 wasn't but the jQuery verion just isn't cutting it yet.  And yes, I
 have the jQuery.noConflict(); line first in my JS code.

 So, what am I missing?  Do I need to download any other file besides
 jquery-1.2.5.pack.js for example?  Are the new releases not working
 with prototype?  Are they using different syntax?  I mean, I assume
 that if the new releases would have such drastic changes, they
 wouldn't be 1.2.6 they would be 2.0.

 Anyway, hopefully someone can point out whatever it is that I'm
 missing here.

 Thanks,

 Kape


[jQuery] Re: jQuery Not Adding Class/Attributes in IE

2008-05-27 Thread Chris P

Anyone?

On May 26, 8:32 pm, Chris P [EMAIL PROTECTED] wrote:
 Hello all,

 For some reason this is not working in IE but fine in Safari/FF.

 jQuery('ul.nav a').addClass('scrollover').attr('type','scrollover');

 You can see it on my site (www.siolon.com).  It's suppose to add it in
 the navigation bar.

 Cheers.


[jQuery] Re: jQuery Not Adding Class/Attributes in IE

2008-05-27 Thread Chris P

Anyone on this?

On May 26, 8:32 pm, Chris P [EMAIL PROTECTED] wrote:
 Hello all,

 For some reason this is not working in IE but fine in Safari/FF.

 jQuery('ul.nav a').addClass('scrollover').attr('type','scrollover');

 You can see it on my site (www.siolon.com).  It's suppose to add it in
 the navigation bar.

 Cheers.


[jQuery] Loading help with contextmenu plugin.

2008-05-27 Thread Mauricio Farah

Hi, I don't know if it's the right place to post this, but I can't
find developer's email anywhere. In case that you don't know the
plugin http://www.trendskitchens.co.nz/jquery/contextmenu/ is the
homepage. Basically it let's you override right click on the browser
for the html elements you want, changing it for one that you define.

The javascript code for the menu is in the $document.ready(), like
this:

$(document).ready(function() {
  $('span.demo1').contextMenu('myMenu1', {
bindings: {
  'open': function(t) {
alert('Trigger was '+t.id+'\nAction was Open');
  },
  'email': function(t) {
alert('Trigger was '+t.id+'\nAction was Email');
  }
}
  });
}

And it works alright. But what I need to do is to show the menu on a
element I dynamically load using $(#id).html(new value);
After loading the new content, right click doesn't brings context menu
anymore on that element, and I don't know how to fix it.
I think it's more related to plain jQuery than the plugin.

I hope someone could help me with this.

Thanks in advance.


[jQuery] Could we have a Cluetip or tooltip on pause with Cycle plugin?

2008-05-27 Thread Maddlake

Wondering what it would take to add a cluetip or other formatted
tooltip on pause. Tried adding class to the markup, per Cluetip
instructions, and it disabled Cluetip on the page altogether.

I have Cycle set up as a slide show and have a carousel below, to
which I have added Cluetips. I would like to add tooltips to the slide
show as well if possible, just when someone mouses over the image and
pauses it.

Ideas?

Many thanks. I am new to this, but loving every (well almost) minute
of it.

Thanks in advance,

Maddlake


[jQuery] Re: jQuery Not Adding Class/Attributes in IE

2008-05-27 Thread Karl Rudd

IE is probably having issues with trying to set an attribute of
type, which is generally only used for input elements.

Karl Rudd

On Wed, May 28, 2008 at 2:14 PM, Chris P [EMAIL PROTECTED] wrote:

 Anyone on this?

 On May 26, 8:32 pm, Chris P [EMAIL PROTECTED] wrote:
 Hello all,

 For some reason this is not working in IE but fine in Safari/FF.

 jQuery('ul.nav a').addClass('scrollover').attr('type','scrollover');

 You can see it on my site (www.siolon.com).  It's suppose to add it in
 the navigation bar.

 Cheers.