[jQuery] Re: Superfish - button width

2008-07-02 Thread Joel Birch

Hi MossyOwls,

I've done this a couple of times. It was pretty easy but I can't
remember off the top of my head. You might be able to figure it out
from studying these two examples:

http://www.blushtomatoes.com.au/about/
http://www.strathcona.vic.edu.au/

Good luck.

Joel Birch.


[jQuery] Re: Shadowbox 2.0rc1

2008-07-02 Thread Gordon

I was having a few problems with the first shadowbox and was
interested to see if there were additions that would get me around
them, but it seems the license has changed and I don't think I can get
my employer to fork out for a license as money is currently very
tight.

On Jul 1, 5:44 pm, Michael J. I. Jackson [EMAIL PROTECTED]
wrote:
 If you're using the Shadowbox jQuery plugin, it has been updated. The
 new version features increased flexibility and stability for various
 media types. It also includes much better support for i18n and
 skinning. Just wanted to let you know in case you are using it.


[jQuery] Re: Minor fixes required in order to play nice with other libraries that extend Object (code inside)

2008-07-02 Thread Jörn Zaefferer

Okay, thanks for the clarification. Though I still can't reproduce the
problem your describe - the autocomplete iterates over the data array
with an index-based for loop, and anything added to the array
prototype is ignored.

Can you provide a testpage where the issue actually occurs in
combination to the autocomplete plugin?

Btw., Firebug displays the array in different ways, but the
letsBreakStuff property is there in both cases.

Jörn

On Tue, Jul 1, 2008 at 4:59 PM, Bramus! [EMAIL PROTECTED] wrote:

 Hi Jörn,

 exactly, the function gets iterated too and is considered as the last
 element of the array. When passed on to autocomplete, it will break as
 s.toLowerCase() is invalid when s isn't a string. Therefore; my patch
 over at http://dev.jquery.com/attachment/ticket/3080/jquery.autocomplete.diff
 (2 little additions to make autocomplete even more idiotproof than it
 already is ;))

 On a sidenote: The strangest part of it all is that the letsBreakStuff
 function doesn't get applied on normal arrays (see the correct array
 in the example mentioned earlier) but only to arrays created as an
 element of an Object (or so it seems in the wrong array mentioned
 earlier).

 Regards,
 Bram.

 On Jul 1, 3:47 pm, Jörn Zaefferer [EMAIL PROTECTED]
 wrote:
 Okay, so the issue is that letsBreakStuff gets iterated together with
 the rest of the array, while it should be ignored, as it doesn't have
 a numerical index, right?

 How does that relate to your patch?

 Jörn

 On Tue, Jul 1, 2008 at 11:36 AM, Bramus! [EMAIL PROTECTED] wrote:

  Hi Jörn,

  The problem in fact is Ext Related, yet can be reproduced without Ext:
  any library that expands the Array prototype with a function can be
  the wrongdoer.

  Create a new blank document (nothing needs to be in it), open up
  firebug and paste in the code below:

  Array.prototype.letsBreakStuff = function(){return this};
  correct = [
 baa,
 bah!,
 bar,
 bar!,
 beblog,
 bezar,
 blog,
 blub,
 blub!,
 boo,
 bramus
  ];

  As you can see this in fact does work correct.

  However, I'm a great JSON-addict, and my autocompletion data - just as
  any other call - is returned in the Object Literal Notation (and then
  run through a custom parse function to get an autocomplete compatible
  array).

  Now, open up Firebug again and paste in this code:

  Array.prototype.letsBreakStuff = function(){return this};
  wrong = { data:[
 baa,
 bah!,
 bar,
 bar!,
 beblog,
 bezar,
 blog,
 blub,
 blub!,
 boo,
 bramus
 ]
  }

  Check wrong.data, you'll see that the last item is the letsBreakStuff
  function.

  To make it all complete: the reason I named Ext is that I got the
  remove function as last item on wrong.data ... which is added by Ext:
  Ext.applyIf(Array.prototype,{indexOf:function(C){for(var
  B=0,A=this.length;BA;B++){if(this[B]==C){return B}}return
  -1},remove:function(B){var A=this.indexOf(B);if(A!=-1){this.splice(A,
  1)}return this}});

  Hope you now see why exactly I suggested that little patch ;)

  Regards,
  Bramus!

  On Jun 24, 3:57 pm, Jörn Zaefferer [EMAIL PROTECTED]
  wrote:
  I don't quite the how the issue is related to ExtJS. It sounds like
  you pass functions instead of strings to the autocomplete plugin,
  which is the actual issue here. Could you upload a testpage and post
  the URL here?

  Jörn

  On Tue, Jun 24, 2008 at 1:03 PM, Bramus! [EMAIL PROTECTED] wrote:

   Filed a ticket on dev.jquery including a .diff 
   file:http://dev.jquery.com/ticket/3080
   ;-)

   Regards,
   B!

   PS: [autocomplete] prefix seems to be cut off subject?

   On Jun 24, 11:15 am, Bramus! [EMAIL PROTECTED] wrote:
   Hi Jörn et all here at the list,

   I'm using the autocomplete plugin in a project I'm working on and I
   must say: it works great!. However: one part of the project uses ExtJS
   (their tree component is great) and that's where things go wrong.
   Problem is that somewhere in ExtJS they extend Object with a remove()
   function, breaking jQuery.autocomplete.

   After a little quest I found that - quite obviously - autocomplete
   breaks on string manipulations (Function.toLowerCase() doesn't really
   exist ;)) and has a minor issue when displaying the items whenever
   some library has extended Object.

   Here below are the 2 minor changes I implemented in order to make
   things work just fine again. Could you tuck 'm into the release as I
   can't commit any changes to the trunk.

   Change #1: Display issue: $.Autocompleter.Select, function fillList():
   replace:
   if (!data[i])
   with:
   if (!data[i] || (data[i].value.constructor === Function))

   Change #2: Selection issue: $.Autocompleter.Cache, function
   matchSubset()
   at line#1 of this function (directly after the opening { ) add:
   if (s.constructor === Function) return false;

   Regards,
   Bramus!



[jQuery] [form][ajaxSubmit] How to send a parameter in error callback ?

2008-07-02 Thread debussy007


Hi,

I would like to send a parameter in the error callback :

var optionsPrcPic = { 
beforeSubmit:  showRequestPic,  // pre-submit callback 
success:   showResponsePic,  // post-submit callback 
dataType: 'json',
url:   ?php echo $this-baseUrl;
?/members/profile/add-photo/pic/+pic,
error: errorPic,   //error callback
timeout:   60
};
function errorPic(xhr, status, ex) {
  [...]
}

I want to give to the error callback the 'pic' variable to know which pic
caused error.

Anyone has an idea ? 

Thanks !
-- 
View this message in context: 
http://www.nabble.com/-form--ajaxSubmit--How-to-send-a-parameter-in-error-callback---tp18233801s27240p18233801.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Re: Minor fixes required in order to play nice with other libraries that extend Object (code inside)

2008-07-02 Thread Jörn Zaefferer

One more thing: I'm using the autocomplete on a project where Ext is
also installed, and there are no compability issues.

Jörn

On Wed, Jul 2, 2008 at 10:24 AM, Jörn Zaefferer
[EMAIL PROTECTED] wrote:
 Okay, thanks for the clarification. Though I still can't reproduce the
 problem your describe - the autocomplete iterates over the data array
 with an index-based for loop, and anything added to the array
 prototype is ignored.

 Can you provide a testpage where the issue actually occurs in
 combination to the autocomplete plugin?

 Btw., Firebug displays the array in different ways, but the
 letsBreakStuff property is there in both cases.

 Jörn

 On Tue, Jul 1, 2008 at 4:59 PM, Bramus! [EMAIL PROTECTED] wrote:

 Hi Jörn,

 exactly, the function gets iterated too and is considered as the last
 element of the array. When passed on to autocomplete, it will break as
 s.toLowerCase() is invalid when s isn't a string. Therefore; my patch
 over at http://dev.jquery.com/attachment/ticket/3080/jquery.autocomplete.diff
 (2 little additions to make autocomplete even more idiotproof than it
 already is ;))

 On a sidenote: The strangest part of it all is that the letsBreakStuff
 function doesn't get applied on normal arrays (see the correct array
 in the example mentioned earlier) but only to arrays created as an
 element of an Object (or so it seems in the wrong array mentioned
 earlier).

 Regards,
 Bram.

 On Jul 1, 3:47 pm, Jörn Zaefferer [EMAIL PROTECTED]
 wrote:
 Okay, so the issue is that letsBreakStuff gets iterated together with
 the rest of the array, while it should be ignored, as it doesn't have
 a numerical index, right?

 How does that relate to your patch?

 Jörn

 On Tue, Jul 1, 2008 at 11:36 AM, Bramus! [EMAIL PROTECTED] wrote:

  Hi Jörn,

  The problem in fact is Ext Related, yet can be reproduced without Ext:
  any library that expands the Array prototype with a function can be
  the wrongdoer.

  Create a new blank document (nothing needs to be in it), open up
  firebug and paste in the code below:

  Array.prototype.letsBreakStuff = function(){return this};
  correct = [
 baa,
 bah!,
 bar,
 bar!,
 beblog,
 bezar,
 blog,
 blub,
 blub!,
 boo,
 bramus
  ];

  As you can see this in fact does work correct.

  However, I'm a great JSON-addict, and my autocompletion data - just as
  any other call - is returned in the Object Literal Notation (and then
  run through a custom parse function to get an autocomplete compatible
  array).

  Now, open up Firebug again and paste in this code:

  Array.prototype.letsBreakStuff = function(){return this};
  wrong = { data:[
 baa,
 bah!,
 bar,
 bar!,
 beblog,
 bezar,
 blog,
 blub,
 blub!,
 boo,
 bramus
 ]
  }

  Check wrong.data, you'll see that the last item is the letsBreakStuff
  function.

  To make it all complete: the reason I named Ext is that I got the
  remove function as last item on wrong.data ... which is added by Ext:
  Ext.applyIf(Array.prototype,{indexOf:function(C){for(var
  B=0,A=this.length;BA;B++){if(this[B]==C){return B}}return
  -1},remove:function(B){var A=this.indexOf(B);if(A!=-1){this.splice(A,
  1)}return this}});

  Hope you now see why exactly I suggested that little patch ;)

  Regards,
  Bramus!

  On Jun 24, 3:57 pm, Jörn Zaefferer [EMAIL PROTECTED]
  wrote:
  I don't quite the how the issue is related to ExtJS. It sounds like
  you pass functions instead of strings to the autocomplete plugin,
  which is the actual issue here. Could you upload a testpage and post
  the URL here?

  Jörn

  On Tue, Jun 24, 2008 at 1:03 PM, Bramus! [EMAIL PROTECTED] wrote:

   Filed a ticket on dev.jquery including a .diff 
   file:http://dev.jquery.com/ticket/3080
   ;-)

   Regards,
   B!

   PS: [autocomplete] prefix seems to be cut off subject?

   On Jun 24, 11:15 am, Bramus! [EMAIL PROTECTED] wrote:
   Hi Jörn et all here at the list,

   I'm using the autocomplete plugin in a project I'm working on and I
   must say: it works great!. However: one part of the project uses ExtJS
   (their tree component is great) and that's where things go wrong.
   Problem is that somewhere in ExtJS they extend Object with a remove()
   function, breaking jQuery.autocomplete.

   After a little quest I found that - quite obviously - autocomplete
   breaks on string manipulations (Function.toLowerCase() doesn't really
   exist ;)) and has a minor issue when displaying the items whenever
   some library has extended Object.

   Here below are the 2 minor changes I implemented in order to make
   things work just fine again. Could you tuck 'm into the release as I
   can't commit any changes to the trunk.

   Change #1: Display issue: $.Autocompleter.Select, function fillList():
   replace:
   if (!data[i])
   with:
   if (!data[i] || (data[i].value.constructor === Function))

   Change #2: Selection issue: $.Autocompleter.Cache, 

[jQuery] the list not reflected the change

2008-07-02 Thread Don Quijote de Nicaragua

Hi, everyone, I have this code to show a list of product

qrRemision = New Query(vwlstRemisiones) //
vwlstRemisiones is a view
qrRemision.OrderBy = OrderBy.Asc(Fecha)
dtsCatalogo = New DataSet
dtsCatalogo = qrRemision.ExecuteDataSet()

When  an element changed again and I want to show  in the list not
reflected the change, I get the old value (the same value before the
change), any suggestions.
Thanks You.

Español
Hola a todos, tengo el siguiente codigo para mostrar una lista de
productos
-- CODE --
Cuanto hago un cambio en un elemento, la lista no la refleja, me
muestra el valor anterior, antes del cambio, alguna sugerencia.
Gracias.
Don Quijote de Nicaragua.
Elder Soto

COMPLETE CODE
Try
With Page.Request
imRecord =
Convert.ToByte(.Params(imRecord).ToString())
ipNumber =
Convert.ToInt16(.Params(pIndex).ToString())
End With
qrRemision = New Query(vwlstRemisiones)
qrRemision.OrderBy = OrderBy.Asc(Fecha)
dtsCatalogo = New DataSet
dtsCatalogo = qrRemision.ExecuteDataSet()
ipCount = fGetPageNumber(dtsCatalogo.Tables(0).Rows.Count,
ipSize)
If (ipNumber = 0) Then ipNumber = 1

Select Case imRecord
Case 1
If (ipNumber  1) Then ipNumber -= 1
Case 2
If (ipNumber  ipCount) Then ipNumber += 1
End Select
iLastRow = ipNumber * ipSize
iFirstRow = iLastRow - ipSize
If (iLastRow  dtsCatalogo.Tables(0).Rows.Count) Then
iLastRow = dtsCatalogo.Tables(0).Rows.Count
iFirstRow = (ipNumber - 1) * ipSize
End If
If (ipCount = 1) Then
sDisabled(0) =  disabled='disabled'
sDisabled(1) =  disabled='disabled'
Else
If (ipNumber = 1) Then
sDisabled(0) =  disabled='disabled'
ElseIf (ipNumber = ipCount) Then
sDisabled(1) =  disabled='disabled'
End If
End If

sHtml = table id='tbHead' class='sTableHead'
cellspacing='1'  NL
sHtml = tr  NL
sHtml = td  NL
sHtml = table style='width:430px'  NL
sHtml = tr  NL
sHtml = td  NL
sHtml = input type='button' id='btnNew' name='btnNew'
class='btnButton' 
sHtml = value='  strNameButton  ' onclick=' +
strAccionCat + '/  NL
sHtml = /td  NL
sHtml = td valign='middle'Buscar:/td  NL
sHtml = td  NL
sHtml = input type='text' id='txtFind' name='txtFind'
value=''/  NL
sHtml = input type='button' id='btnFind' name='btnFind'
class='btnButton
sHtml = ' value='Buscar' onclick= 'GuardarCatalogos(4);'/
  NL
sHtml = /td  NL
sHtml = /tr  NL
sHtml = /table  NL
sHtml = /td  NL
sHtml = td align='right'  NL
sHtml = table style='width:250px'  NL
sHtml = tr  NL
sHtml = IIf(ipCount, tdPaacute;gina:/td, td/
td)  NL
sHtml = td style='width:20px'  NL
'Boton Previo
sHtml = input type='button' id='btnPrev' name='btnPrev'
class='navButton
sHtml = ' value='' onclick='sLoadLstCatalogos(1, 
ipNumber  ,1, + Request.Params(iAction) + , +
Request.Params(Actividad) + );'
sHtml = sDisabled(0).ToString()  /  NL
sHtml = /td  NL
sHtml = IIf(ipCount, td align='center'  ipNumber 
/td, td/td)
sHtml = NL  td style='width:20px'  NL
'Boton Siguiente
sHtml = input type='button' id='btnNext' name='btnNext'
class='navButton
sHtml = ' value='' onclick='sLoadLstCatalogos(2, 
ipNumber  ,1, + Request.Params(iAction) + , +
Request.Params(Actividad) + );'
sHtml = sDisabled(1).ToString()  /  NL
sHtml = /td  NL
sHtml = IIf(ipCount, td align='left'de   ipCount 
/td, td/td)
sHtml = NL  /tr  NL
sHtml = /table  NL
sHtml = /td  NL
sHtml = /tr  NL
sHtml = /table  NL
'Encabezado de los catalogos
sHtml = table id='tbClientes' class='sTableList'
cellspacing='1'  NL
sHtml = tr  NL
sHtml = th class='sThList'CodRemision/th  NL
sHtml = th class='sThList'Fecha/th  NL
sHtml = th class='sThList'No Remision/th  NL
sHtml = th class='sThList'No Orden/th  NL
sHtml = th class='sThList'Cliente/th  NL
sHtml = th class='sThList'Transporte/th  NL
sHtml = th class='sThList' stytile='width:
2px;'Modificar/th  NL
sHtml = th class='sThList' stylile='width:2px'Borrar/
th/tr  NL
'---Listado de Remision ---'
With dtsCatalogo.Tables(0)
  

[jQuery] Replicating frame interface with jquery?

2008-07-02 Thread fambi

We're looking to replicate the traditional email client interface
without using frames, much the same way that Yahoo Mail beta has done.

Has anyone written a plugin or tutorial for this? If not, can anyone
give me a rough idea of how the resizing part of it all works?

Thanks


[jQuery] Re: dimensions, RTL and IE offset problem

2008-07-02 Thread iTsadok

OK, I found a workaround: I wrap the whole document with a div and use
that div's left offset value as a calibrator. This works in FF3 and
IE7, but not Safari.
My questions are:

1 - Is there a simpler way to do the wrapping than what I'm doing?
2 - Is there a better way to create the patched offset?
3 - Does anyone know why this doesn't work in Safari?

My code:
!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01//EN
http://www.w3.org/TR/html4/strict.dtd;
html
head
script type=text/javascript src=jquery.js /script

script
(function($) {
var outer;

$.fn.old_offset = $.fn.offset;
$.fn.offset = function () {
offset = this.old_offset();
offset.left -= outer.old_offset().left;
return offset;
}

$(function() {
outer = $(div style=\margin: 0; overflow: 
hidden; position:
absolute;\/div);
$(body).children().appendTo(outer);
$(body).append(outer);
outer.height($(window).height());
outer.width($(window).width());

$(window).resize(function () {
outer.height($(window).height());
outer.width($(window).width());
});
});
})(jQuery);

$(function() {

for(var i=0; i 200; i++) { 
$(#overflow_text).append('x'); }
offset = $(#coverme).offset();
$(#moveme).css(offset);

$(window).resize(function() {
$(#moveme).css($(#coverme).offset());
});
});

/script
/head
body dir=rtl style=margin: 0;
div style=background-color: blue; height: 200px; width: 200px
id=coverme/div
div style=background-color: green; height: 100px; width: 100px;
position: absolute; id=moveme/div
p id=overflow_text/p
span style=position:absolute; visibility:hidden; right:
-100pxtext/span
/body

Thanks


[jQuery] Re: Shadowbox 2.0rc1

2008-07-02 Thread Web Specialist
Congratulations. Awesome and very powerful!

Cheers
Marco Antonio

On Tue, Jul 1, 2008 at 2:40 PM, tlphipps [EMAIL PROTECTED] wrote:


 http://mjijackson.com/shadowbox/

 On Jul 1, 12:37 pm, Glen Lipka [EMAIL PROTECTED] wrote:
  Is there a homepage for this plugin?
  I cant seem to find it.
 
  Glen
 
  On Tue, Jul 1, 2008 at 9:44 AM, Michael J. I. Jackson 
 [EMAIL PROTECTED]
  wrote:
 
 
 
   If you're using the Shadowbox jQuery plugin, it has been updated. The
   new version features increased flexibility and stability for various
   media types. It also includes much better support for i18n and
   skinning. Just wanted to let you know in case you are using it.



[jQuery] Problem with .load

2008-07-02 Thread Eric Snyder

I have the following code:

$(document).ready(function(){
$(#FilterSubmit).click(function(){
var 
$pagename=http://www.agreatyouthmentoringorganization.net/includes/publicProfiles+$(#gender
 
option:selected).val()+$(#location option:selected).val();
$(#FilteredProfiles).html('img 
src=http://www.agreatyouthmentoringorganization.net/images/text-fetching 
data.gif alt=Fetching data');
$(#FilteredProfiles).load($pagename, {limit: 25}, function(data){
alert(data);
$(#FilteredProfiles).html(data);
});
});//End of the filterSubmit actions
});//end of ready function

It seems that I can get it to work only on the FF browser I am doing the 
dev work on. When I try it on any other FF or IE browser it fails. What 
happens is the loading data graphic gets displayed and it comes back 
with data and the alert fires but no data displays in the 
FilteredProfiles div.

I ahve looked and looked at this with no joy. Any help would be appreciated.


[jQuery] Targeting an element with multiple classes

2008-07-02 Thread jez_p

How do I target a specific class when elements may belong to multiple
classes?

For example:

p class=big redblah blah blah/p
p class=big greenblah blah blah/p
p class=small greenblah blah blah/p

How would I select the elements with the class of green?

I know that

'p[class=big green]'  
'p[class=small green]'

would work, but I cannot work out how I can just specify wherever
there is a class of green, and not have to include the other classes
also.

Thanks in advance.


[jQuery] Re: Targeting elements with more than one class

2008-07-02 Thread jez_p

Thanks Mike - that was the first thing I tried.  I have since found a
stupid typo, and it now works of course.  *slaps forehead repeatedly*.

On Jul 2, 1:51 am, Mike Alsup [EMAIL PROTECTED] wrote:
  Please excuse my noobiness, I just started playing with jQuery today
  and I cannot seem to find the answer to this:

  If you have elements with multiple classes, how do target just one
  class?

  For example:

  p class=big blueblah blah blah/p

  p class=big greenblah blah blah/p

  p class=small greenblah blah blah/p

  How do I target the p's with the class of green?

  Thanks in advance.

 $('p.green')


[jQuery] Re: [form][ajaxSubmit] How to send a parameter in error callback ?

2008-07-02 Thread Mike Alsup

 Hi,

 I would like to send a parameter in the error callback :

 var optionsPrcPic = {
         beforeSubmit:  showRequestPic,  // pre-submit callback
         success:       showResponsePic,  // post-submit callback
         dataType: 'json',
         url:       ?php echo $this-baseUrl;
 ?/members/profile/add-photo/pic/+pic,
         error: errorPic,   //error callback
         timeout:   60};

 function errorPic(xhr, status, ex) {
       [...]

 }

 I want to give to the error callback the 'pic' variable to know which pic
 caused error.

 Anyone has an idea ?

 Thanks !

Try this:

function showRequestPic(arr, $form, opts) {
opts.pic = // whatever the pic is
}

 function errorPic(xhr, status, ex) {
var pic = this.pic;
}


[jQuery] Re: expr in $(, expr) not as expected

2008-07-02 Thread Karl Swedberg

On Jul 2, 2008, at 7:57 AM, [rob desbois] wrote:



Hi, have a feeling this may be a silly question but here goes..

Test output from Firebug's console is below to explain my issue.

I select an array of divs by their parent:

divs = $(#sidebar  div).get()

[div#sidebar-search-tabcont, div#sidebar-events-tabcont]

I then want to find a particular one:

$(div, divs)

Object length=0 prevObject=Object jquery=1.2.6


Given that the 'expr' parameter to $(...) contains an array of divs,
why is using the selector div not returning anything from that?? Am
I misunderstanding expr?

Confused...
--rob


Hi Rob,

Your selector $('div', divs) is looking for all div elements contained  
in any of the divs stored in your variable. So, it's like doing $ 
(divs).find('div') . I think you may have been expecting it to work  
like $(divs).filter('div')? Do any of the divs selected by $(#sidebar  
 div).get() have child divs? If not, the second selector shouldn't  
be returning anything.


Hope that makes sense



--Karl


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



[jQuery] Re: Star Rating Plugin

2008-07-02 Thread Diego A.

Thanks for pointing that out.

Silly me thought it would be OK to test using the Simulate IE7
feature in IE8.
Turns out not even that works in IE...

Anyway, lesson learnt, all fixed now!

On Jul 2, 5:41 am, C.Everson [EMAIL PROTECTED] wrote:
 On Tue, 1 Jul 2008 10:53:00 -0700 (PDT), Diego A. wrote:
  Oops, forgot to post a link:
 http://www.fyneworks.com/jquery/star-rating/

 Thanks for these updates Diego,

 But it appears these pages do not work at all in IE7 either.

 You may be fine with thatg, but it does make the rest of us wonder if
 your plug-in's even work with IE7...

 ;-)

 Chuck


[jQuery] Re: Multiple File Upload Update

2008-07-02 Thread Diego A.

Thanks for pointing that out.

Silly me thought it would be OK to test using the Simulate IE7
feature in IE8.
Turns out not even that works in IE...

Anyway, lesson learnt, all fixed now!

DE JA VU!

On Jul 2, 5:37 am, C.Everson [EMAIL PROTECTED] wrote:
 On Tue, 1 Jul 2008 10:52:22 -0700 (PDT), Diego A. wrote:
 http://www.fyneworks.com/jquery/multiple-file-upload/

 Diego,

 Also the navigation menu on that page does not work in IE7.

 There is no way to reach the actual download link.

 I guess your using some alternate browser, but for public websites you
 always need to at least TEST to make sure it works in IE...

 ;-)

 Chuck


[jQuery] Re: Shadowbox 2.0rc1

2008-07-02 Thread Rick Faircloth

I don't see why you can't download the free version for testing
and then demo it to your boss.  If he/she wants it, $20 can be found.
(And if your boss can't find $20 extra dollars, you might want to
abandon that sinking ship! One less pizza and you've got a great plug-in! :o)

Rick

 -Original Message-
 From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Gordon
 Sent: Wednesday, July 02, 2008 4:19 AM
 To: jQuery (English)
 Subject: [jQuery] Re: Shadowbox 2.0rc1
 
 
 I was having a few problems with the first shadowbox and was
 interested to see if there were additions that would get me around
 them, but it seems the license has changed and I don't think I can get
 my employer to fork out for a license as money is currently very
 tight.
 
 On Jul 1, 5:44 pm, Michael J. I. Jackson [EMAIL PROTECTED]
 wrote:
  If you're using the Shadowbox jQuery plugin, it has been updated. The
  new version features increased flexibility and stability for various
  media types. It also includes much better support for i18n and
  skinning. Just wanted to let you know in case you are using it.
 
 No virus found in this incoming message.
 Checked by AVG.
 Version: 8.0.101 / Virus Database: 270.4.3/1529 - Release Date: 7/1/2008 7:23 
 PM



[jQuery] text input glow effect

2008-07-02 Thread cecil

Hello ... I'm really new to JQuery; today would be my first time using
it actually. i'd like to reproduce the input highlight effect that
safari applies. when the input is in focus, the border has somewhat of
a glow effect to it.

Does anyone know of technique that I could apply to allow this effect
to happen in IE  FF ?

Thank


[jQuery] Css workaround....jquery...

2008-07-02 Thread Aaron

HI I just noticed today when putting a some of my webpages up on my
server and seeing through firefox I see that the z-index dosen't work
in firefox is their a workaround way to get around this??

I want to make it to allow me to put text on top of images which would
be advance artwork of a table ect I want this for firefox and also
ie5-7.

would I use javascripts?? or could I use jquery to workaround this
issue??


[jQuery] Re: expr in $(, expr) not as expected

2008-07-02 Thread [rob desbois]

On Jul 2, 2:11 pm, Karl Swedberg [EMAIL PROTECTED] wrote:
 On Jul 2, 2008, at 7:57 AM, [rob desbois] wrote:





  Hi, have a feeling this may be a silly question but here goes..

  Test output from Firebug's console is below to explain my issue.

  I select an array of divs by their parent:
  divs = $(#sidebar  div).get()
  [div#sidebar-search-tabcont, div#sidebar-events-tabcont]

  I then want to find a particular one:
  $(div, divs)
  Object length=0 prevObject=Object jquery=1.2.6

  Given that the 'expr' parameter to $(...) contains an array of divs,
  why is using the selector div not returning anything from that?? Am
  I misunderstanding expr?

  Confused...
  --rob

 Hi Rob,

 Your selector $('div', divs) is looking for all div elements contained  
 in any of the divs stored in your variable. So, it's like doing $
 (divs).find('div') . I think you may have been expecting it to work  
 like $(divs).filter('div')? Do any of the divs selected by $(#sidebar  
   div).get() have child divs? If not, the second selector shouldn't  
 be returning anything.

 Hope that makes sense

 --Karl

 
 Karl Swedbergwww.englishrules.comwww.learningjquery.com

Aha! Yes it does.

Seems a bit odd though, the array (or jQuery/DOM object if so) *does*
contain 2 div elements, so I would naturally expect those to be found.

Thanks Karl,
--rob


[jQuery] Firefox/css/jquery..

2008-07-02 Thread Aaron

Hi I just noticed that firefox dosen't support the z-index what can I
do to get around this so many web browsers would be able to the same
effect that z-index has.

Can jquery do such a thing that would work on many web browsers???

I need to overlap an image over another image.

I have  picture that is supposed to be over an art image I made that
resembles a table which I want the image to be on top of.



[jQuery] Re: expr in $(, expr) not as expected

2008-07-02 Thread chris thatcher
Hi Rob, It's an easy issue to confuse at first so don't worry.  the expr
parameter is treated as a top level context and the query you're using,
'div', is actually saying 'find any descendant divs UNDER the top level
context'.  Now to help you figure out what query might possible to discern
one of the divs we could probably use a filter or something but I'd have to
know what you're criteria are.  Hope this gets you started.

Thatcher

On Wed, Jul 2, 2008 at 7:57 AM, [rob desbois] [EMAIL PROTECTED] wrote:


 Hi, have a feeling this may be a silly question but here goes..

 Test output from Firebug's console is below to explain my issue.

 I select an array of divs by their parent:
  divs = $(#sidebar  div).get()
 [div#sidebar-search-tabcont, div#sidebar-events-tabcont]

 I then want to find a particular one:
  $(div, divs)
 Object length=0 prevObject=Object jquery=1.2.6


 Given that the 'expr' parameter to $(...) contains an array of divs,
 why is using the selector div not returning anything from that?? Am
 I misunderstanding expr?

 Confused...
 --rob




-- 
Christopher Thatcher


[jQuery] Re: Shadowbox 2.0rc1

2008-07-02 Thread chris thatcher
I'm not advocating Shadowbox because I have nothing to do with it's
development, but I have been studying it and I think it's probably worth 20
buckaroos if your developing a commercial site (otherwise it's free!)

Thatcher

On Wed, Jul 2, 2008 at 4:18 AM, Gordon [EMAIL PROTECTED] wrote:


 I was having a few problems with the first shadowbox and was
 interested to see if there were additions that would get me around
 them, but it seems the license has changed and I don't think I can get
 my employer to fork out for a license as money is currently very
 tight.

 On Jul 1, 5:44 pm, Michael J. I. Jackson [EMAIL PROTECTED]
 wrote:
  If you're using the Shadowbox jQuery plugin, it has been updated. The
  new version features increased flexibility and stability for various
  media types. It also includes much better support for i18n and
  skinning. Just wanted to let you know in case you are using it.




-- 
Christopher Thatcher


[jQuery] Re: Fadein with ajax load()

2008-07-02 Thread Pickledegg

Thanks Equand, unfortunately my fadeIn doesn't seem to have any
effect. Hmm, maybe its because the contents of the div has already
been loaded at this point?

Perhaps I'll have to go a bit more technical than just using the load
method...

On Jul 1, 11:56 pm, Equand [EMAIL PROTECTED] wrote:
 try

 $('#id-of-my-div').load('somescript.php?name='+escape($(this).val()),
 {},function(){ $('#id-of-my-div').fadeIn(slow) 
 });http://docs.jquery.com/Ajax/load#urldatacallback

 On 1 июл, 14:26, Pickledegg [EMAIL PROTECTED] wrote:

  I'm using an ajax load() with an onChange event:

  $('#id-of-my-div').load('somescript.php?name='+escape($(this).val()));

  Which is lovely, but how can I add a fadeIn to it so that every time
  my div is updated, it fades into the div in a sultry  provocative
  fashion?

  Thanks.


[jQuery] Using ASCII characters in textfield

2008-07-02 Thread Gearóid O'Ceallaigh

I'm using an autocomplete function on a textfield but I'm having a
problem since the autocomplete array is filled with German words so
special characters (such as ü, ä and ö). I can insert the ASCII codes
for these characters in the array and when the autocomplete display
pulls down, the array elements are displayed correctly.

However, when the user selects an option with a German character, the
ASCII code of the element is displayed instead of the German
character.

For example, if the user selects Anlagenführer, the text field would
be populated with Anlagenfuuml;hrer.

Does anyone have any ideas of a workaround?


[jQuery] JQuery 1.2.6 and JQuery Form Plugin in IE7

2008-07-02 Thread Drager

I want to upload a file using JQuery Form Plugin but I have some
troubles.

It work ok with JQuery 1.2.3 but don't with version 1.2.6 and IE 7. In
Firefox2 it works great with both versions of JQuery.


* jQuery Form Plugin
* version: 2.12 (06/07/2008)
* @requires jQuery v1.2.2 or later


[jQuery] Re: Multiple File Upload Update

2008-07-02 Thread JohnieKarr

Diego,

What is the Major Bug that you fixed?

Thanks,
Johnie Karr
On Jul 1, 12:48 pm, Diego A. [EMAIL PROTECTED] wrote:
 Annoucement to anyone using this plugin:
 - MAJOR BUG FIX
 - New documentation website
 - Documentation available to download (works off-line just as it does
 online)


[jQuery] Re: Validate and erroneous display:none

2008-07-02 Thread LVR

Being more of a designer than a coder, I'm having trouble with
this.  I've not been able to find any examples of errorPlacement or
showErrors that seem to apply in this situation.  I don't understand
what you mean by adding a different class to the actual label -- would
I still be able to use highlight and unhighlight, or is that my
problem?  I apologize for my ignorance.  Thanks for your help so far,
I'll keep researching and experimenting...

LVR

On Jun 30, 11:09 am, Jörn Zaefferer [EMAIL PROTECTED]
wrote:
 Don't add the error class to thelabel. The validation plugin searches
 for the errorlabelbased on that error class - adding it to the
 actuallabelcauses thelabelto disappear.

 You could add a different class to the actuallabelso that the errorlabelcan 
 be hidden or removed entirely (via errorPlacement, or
 showErrors).

 Jörn

 On Mon, Jun 30, 2008 at 6:35 PM, LVR [EMAIL PROTECTED] wrote:

  I'm having a consistent problem with labels disappearing on keyup
  using theValidateplug-in.  All of the functionality of thevalidate
  plug-in is there -- it works great.  But elements are jumping around
  on the page!

  When a field is invalid, the labelfor tag turns thelabelred and
  bold.  So far, so good.  When the info becomes valid as it's entered,
  the wholelabeldisappears.  I think style=display:none; is being
  applied to thelabel. In my case, the css I use causes the form field
  to jump to the left, taking the place of thelabel. Subsequent key-up
  strokes (if they are used/needed) cause thelabelelement to re-appear
  and the form field to jump back into place.

  I'm using the most current versions of jQuery and theValidateplug-
  in.  I'm using XHTML Strict.  This behavior occurs on all platforms
  and browsers I've tested.  Thanks in advance for any help...

  Here's my code:

  script type=text/javascript
  $(document).ready(function(){
  $(#register).validate({
    highlight: function(element, errorClass) {
        $(element).addClass(errorClass);
        $(element.form).find(label[for= + element.id
  +]).addClass(errorClass);
        },
    unhighlight: function(element, errorClass) {
        $(element).removeClass(errorClass);
        $(element.form).find(label[for= + element.id
  +]).removeClass(errorClass);
        }
  });
  });
  /script

  Typical form elements:

  labelfor=firstspan class=rqdbull;/spanFirst Name:/label
     input name=first id=first size=25 maxlength=50
  class=required value= /br /
  labelfor=lastspan class=rqdbull;/spanLast Name:/label
     input name=last id=last size=25 maxlength=50
  class=required value= /br /

  Thanks...
  LVR


[jQuery] clueTip help please

2008-07-02 Thread chrism1977

Hi,

Being new to jQuery I am trying to adapt the functionality of the JTip
Theme a little.

It is great that the window closes when the mouse leaves the dialog
box but I am trying to combine this with the hoverIntent too.

Eg, the window fades in shortly after the user rolls over a text link
(thanks to hoverIntent), after that if the mouse is not over the
tooltip window or text link the tool tip will fade out, however it
will stay open if the mouse is over the window.

Many thanks for any advice on how this could be achieved, my main
problem is I do not understand how the hoverIntent close function can
check to see if the mouse is over the popup window.

The reason I'd like this is i'd like to have a small menu list,
similar to the right-click on a mouse appear on rollover - but I do
not want to force the users to manually close the tooltip or have to
roll over the window then off again for it to disappear.

I realise there will be some tweaking of values to get a satisfactory
feel to the menus, but think (hope!) hoverIntent will be able to
provide me with this.

Does this make sense?

Many Thanks!

Chris


[jQuery] [validate] jquery.delegate.js is missing?

2008-07-02 Thread jez_p

I should just explain that I'm very new to jQuery. That out of the
way, I have downloaded the validation plug-in which states that
jquery.delegate.js is required. It is not included within the package,
so where can I obtain it from, and once I have it how should I include
it within my project?

Thanks,

Jez


[jQuery] Re: [validate] jquery.delegate.js is missing?

2008-07-02 Thread John Resig

Popping jquery.delegate.js into Google provides this:
http://dev.jquery.com/export/5759/trunk/plugins/delegate/jquery.delegate.js

--John


On Wed, Jul 2, 2008 at 9:17 AM, jez_p [EMAIL PROTECTED] wrote:

 I should just explain that I'm very new to jQuery. That out of the
 way, I have downloaded the validation plug-in which states that
 jquery.delegate.js is required. It is not included within the package,
 so where can I obtain it from, and once I have it how should I include
 it within my project?

 Thanks,

 Jez



[jQuery] Selected/Highlighted by Mouse

2008-07-02 Thread Brian Ronk

I know that it's possible, but I'm wondering if there is something in
jQuery that will return the data or index of what a user has selected
with a mouse (or shift button).

I'd like to have a way to create a note on a page about a certain
selection that the user defines.  So, maybe I'd like to add a note
about my first paragraph.  I would be able to highlight it, and click
a button, and then write a note to tell myself it's (not) possible.
(which would be stored in the backend with the location of the note.

Internally, I want to add a [note] type of BBCode to the text that is
highlighted.

Does this make sense?  If so, anyone know how?  Thanks.


[jQuery] Re: Firefox/css/jquery..

2008-07-02 Thread MorningZ

I just noticed that firefox dosen't support the z-index

Of course FF supports z-index...

something is wrong with your code/markup, not with FireFox or jQuery

Got a live link to show what you cannot get working?


[jQuery] Re: Problem with .load

2008-07-02 Thread Ariel Flesler

Can you give us an online example of this ?

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

On 2 jul, 08:40, Eric Snyder [EMAIL PROTECTED] wrote:
 I have the following code:

 $(document).ready(function(){
     $(#FilterSubmit).click(function(){
         var
 $pagename=http://www.agreatyouthmentoringorganization.net/includes/publicProfiles+$(#gender
 option:selected).val()+$(#location option:selected).val();
         $(#FilteredProfiles).html('img
 src=http://www.agreatyouthmentoringorganization.net/images/text-fetching
 data.gif alt=Fetching data');
         $(#FilteredProfiles).load($pagename, {limit: 25}, function(data){
             alert(data);
             $(#FilteredProfiles).html(data);
         });
     });//End of the filterSubmit actions

 });//end of ready function

 It seems that I can get it to work only on the FF browser I am doing the
 dev work on. When I try it on any other FF or IE browser it fails. What
 happens is the loading data graphic gets displayed and it comes back
 with data and the alert fires but no data displays in the
 FilteredProfiles div.

 I ahve looked and looked at this with no joy. Any help would be appreciated.


[jQuery] Re: text input glow effect

2008-07-02 Thread MorningZ

Doesn't look very easy (yet anyways), but there's plenty of options

http://www.google.com/search?q=css+cross+browser+glow

jQuery could help apply the styles and like


[jQuery] Re: text input glow effect

2008-07-02 Thread Alexandre Plennevaux

On Wed, Jul 2, 2008 at 3:42 PM, cecil [EMAIL PROTECTED] wrote:

 Hello ... I'm really new to JQuery; today would be my first time using
 it actually. i'd like to reproduce the input highlight effect that
 safari applies. when the input is in focus, the border has somewhat of
 a glow effect to it.

 Does anyone know of technique that I could apply to allow this effect
 to happen in IE  FF ?

 Thank


Welcome on board !
you don't need javascript for that: simply with CSS :

input:focus{
background-image: url(highlightedinput.gif) ;
}

-- 
Alexandre Plennevaux
LAb[au]

http://www.lab-au.com


[jQuery] Re: Fadein with ajax load()

2008-07-02 Thread armsteadj1

try:

$('#id-of-my-div').load('somescript.php?name='+escape($(this).val()),
{}).fadeIn(slow);

On Jul 2, 9:35 am, Pickledegg [EMAIL PROTECTED] wrote:
 Thanks Equand, unfortunately my fadeIn doesn't seem to have any
 effect. Hmm, maybe its because the contents of the div has already
 been loaded at this point?

 Perhaps I'll have to go a bit more technical than just using the load
 method...

 On Jul 1, 11:56 pm, Equand [EMAIL PROTECTED] wrote:

  try

  $('#id-of-my-div').load('somescript.php?name='+escape($(this).val()),
  {},function(){ $('#id-of-my-div').fadeIn(slow) 
  });http://docs.jquery.com/Ajax/load#urldatacallback

  On 1 июл, 14:26, Pickledegg [EMAIL PROTECTED] wrote:

   I'm using an ajax load() with an onChange event:

   $('#id-of-my-div').load('somescript.php?name='+escape($(this).val()));

   Which is lovely, but how can I add a fadeIn to it so that every time
   my div is updated, it fades into the div in a sultry  provocative
   fashion?

   Thanks.


[jQuery] Re: [validate] jquery.delegate.js is missing?

2008-07-02 Thread jez_p

Thank you for your reply John.

I thought the author might appreciate the heads up that is not
included within the package when it is linked to within the included
demo/index.html, implying that it should have been included.

OK, so now I have it, do I simply put in the same folder as my
jquery.js, or do i have to do anything else with it?

Thanks,

Jez

On Jul 2, 3:57 pm, John Resig [EMAIL PROTECTED] wrote:
 Popping jquery.delegate.js into Google provides 
 this:http://dev.jquery.com/export/5759/trunk/plugins/delegate/jquery.deleg...

 --John

 On Wed, Jul 2, 2008 at 9:17 AM, jez_p [EMAIL PROTECTED] wrote:

  I should just explain that I'm very new to jQuery. That out of the
  way, I have downloaded the validation plug-in which states that
  jquery.delegate.js is required. It is not included within the package,
  so where can I obtain it from, and once I have it how should I include
  it within my project?

  Thanks,

  Jez


[jQuery] Modifying table cell text

2008-07-02 Thread P

I have a table that looks like this:

--

div class=highest-rated
table
tr
td class=titleLorem ipsum/td
  td class=categoryAudio/td
  td class=rating3/td
/tr
tr
td class=titleFoo/td
  td class=categoryVideo/td
  td class=rating2/td
/tr
tr
td class=titleBar/td
  td class=categoryVideo/td
  td class=rating2/td
/tr
tr
td class=titleHello world/td
  td class=categoryAudio/td
  td class=rating1/td
/tr
/table
/div

--

With a little jquery magic I would like to modify the text of the
rating cell and have it display an image.
This should be the outcome:

--

div class=highest-rated
table
tr
td class=titleLorem ipsum/td
  td class=categoryAudio/td
  td class=ratingimg src=images/rating-3.gif //td
/tr
tr
td class=titleFoo/td
  td class=categoryVideo/td
  td class=ratingimg src=images/rating-2.gif //td
/tr
tr
td class=titleBar/td
  td class=categoryVideo/td
  td class=ratingimg src=images/rating-2.gif //td
/tr
tr
td class=titleHello world/td
  td class=categoryAudio/td
  td class=ratingimg src=images/rating-1.gif //td
/tr
/table
/div

--


The number of table rows may vary on different pages.
How should I do this...?

Regards,
Per


[jQuery] Simple sliding help

2008-07-02 Thread kimolias


I can't find a way to slide left a horizontal list of images.
Here is what I managed to do:
http://treazy.com/pek/album/

As you can see, first, while sliding, the images suddenly bump and,
second, I can't seem to find how to remove 100px every time someone
clicks next (.css(margin-left) returns a string 0px which I can't
use as an integer to subtract 100 px).

Any help?
Thanks in advance.
Panagiotis 
-- 
View this message in context: 
http://www.nabble.com/Simple-sliding-help-tp18239408s27240p18239408.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Element's inner/children

2008-07-02 Thread noon

I have the following HTML structure:

div id=new-msgs
div class=msg.../div
div class=msg.../div
/div

I have the following code:

$('#new-msgs')
.appendTo('#prev-msgs')
.wrap('div id=p'+pCurrent+'/div');

I want everything inside #new-msgs to be appended to #prev-msgs, and
not #new-msgs as well.  Using a selector of #new-msgs * loses the
hierarchical structure that I want to maintain (div.msg has
children).  Also using .html() on #new-msgs and then appending
+wrapping results in multiple wraps.

What's the best way to get the contents of a container and append them
somewhere else?


[jQuery] Re: Selected/Highlighted by Mouse

2008-07-02 Thread Richard D. Worth
For how to do it with javascript, start here:

http://www.quirksmode.org/dom/range_intro.html

http://www.quirksmode.org/dom/w3c_range.html

I don't know of any plugins that help with this.

- Richard

On Wed, Jul 2, 2008 at 10:57 AM, Brian Ronk [EMAIL PROTECTED] wrote:


 I know that it's possible, but I'm wondering if there is something in
 jQuery that will return the data or index of what a user has selected
 with a mouse (or shift button).

 I'd like to have a way to create a note on a page about a certain
 selection that the user defines.  So, maybe I'd like to add a note
 about my first paragraph.  I would be able to highlight it, and click
 a button, and then write a note to tell myself it's (not) possible.
 (which would be stored in the backend with the location of the note.

 Internally, I want to add a [note] type of BBCode to the text that is
 highlighted.

 Does this make sense?  If so, anyone know how?  Thanks.



[jQuery] Newbe: Why can't I reference $('#...') in functions?

2008-07-02 Thread lwoods

Why can't I reference the DIV using the jQuery format?  Here is the
example (minus opening HTML):

script language=javascript src=js/jquery-1.2.3.pack.js/script
script language=javascript
!--
$(function(){
$(#button).bind('click',filldiv);
});
function filldiv(){
// $('#info').innerHTML='Test';  --- This doesn't work!
document.getElementById(info).innerHTML=Test;
}
//--
/script
/head

body
input type=button id=button name=button value=Testing /
div id=info/div
/body
/html


[jQuery] Jquery toggle fast

2008-07-02 Thread jquerysk

We just upgraded to the latest version 1.2.6 and start having problem
with toggle(fast)
It was working until certain time. If i call it without parameter, it
still works.
I checked the release note for 1.2.6 but didn't find anything about
not accepting these parameters( fast,slow..).


[jQuery] Re: Noob question about accessing element contents

2008-07-02 Thread Richard D. Worth
$('item', xml).eq(1).text()

- Richard

On Wed, Jul 2, 2008 at 11:51 AM, ml1 [EMAIL PROTECTED] wrote:


 I'm trying to find out the best practice for getting the contents of
 one particular element.  I know about the each() call.

 As I said I can use ways that seem not so efficient to get the
 contents of a single element but I want to know the best way.

 On Jul 1, 5:20 pm, Mike Alsup [EMAIL PROTECTED] wrote:
   I am using jquery to parse some xml.  I'm looking for the best
   practice to access an elements text contents.
 
   Let's say my xml looks like this:
 
   items
 item
Hello world!
  /item
  item
 Goodnight moon!
  /item
   items
 
   I can get a wrapped set of the elements this way: $('items  item',
   xml)
 
   And I can get the text of element 1 this way:  $('items  item:eq(1)',
   xml).text()
 
   But how do I get the contents once I am directly accessing the element
   instead of the jquery object?
 
   In other words I'd like to do something like this: $('items  item',
   xml)[1].text(), but since the element that's returned from the array
   [] doesn't support text() how do I get it's contents?
 
   I know I can wrap it in a second $ call, as in $($('items  item', xml)
   [1]).text() but that seems less than ideal.
 
  Why do you need to access the element?  Are you trying to get the
  contents of each 'item'?  If so, here's a way to do that:
 
  $('items  item').each(i,o) {
  // in this loop 'i' is the index of the loop iteration
  // and 'o' is the object of the iteration (item element in this
  case)
  var $item = $(o); //  could also do:  var $item = $(this);
  var txt = $item.text();
 
  });



[jQuery] Re: Newbe: Why can't I reference $('#...') in functions?

2008-07-02 Thread Liam Byrne


Would've thought it should be $(#info).html(Test), but nevertheless 
that example that you gave works fine for me.


Are you sure that the jquery file referenced in the first script tag is 
in that location, i.e


js/jquery-1.2.3.pack.js

and that it's using that filename ?

L

lwoods wrote:

Why can't I reference the DIV using the jQuery format?  Here is the
example (minus opening HTML):

script language=javascript src=js/jquery-1.2.3.pack.js/script
script language=javascript
!--
$(function(){
$(#button).bind('click',filldiv);
});
function filldiv(){
// $('#info').innerHTML='Test';  --- This doesn't work!
document.getElementById(info).innerHTML=Test;
}
//--
/script
/head

body
input type=button id=button name=button value=Testing /
div id=info/div
/body
/html


  




[jQuery] Re: Newbe: Why can't I reference $('#...') in functions?

2008-07-02 Thread Richard D. Worth
On Wed, Jul 2, 2008 at 11:53 AM, lwoods [EMAIL PROTECTED] wrote:


 Why can't I reference the DIV using the jQuery format?  Here is the
 example (minus opening HTML):

 script language=javascript src=js/jquery-1.2.3.pack.js/script
 script language=javascript
 !--
 $(function(){
$(#button).bind('click',filldiv);
 });
 function filldiv(){
// $('#info').innerHTML='Test';  --- This doesn't work!


$(#info) returns a jQuery object, an array-like collection of DOMElements
with all the jQuery methods. You're trying to access a DOMElement property
(innerHTML), but you're doing it on the jQuery object. If you want to get at
the DOMElement, you can use array index notation, like so:

$(#info)[0].innerHTML = 'Test'; // [0] since you want the first/only
element returned

But where's the fun in that? You're only using jQuery to select the element.
You might as well use document.getElementById ;). Plus, the query might not
return any elements (if no element has that id) and then you'll get an
exception like this:

'$(#info)[0] is undefined'

which means to be safe you have to check whether the element exists, etc.
Yuck. jQuery's .html() method takes care of all of this for you:

$(#info).html('Test');

It will set the html on 1 or more elements (all that match your query), and
it runs quite nicely on 0, with no exception.

- Richard


[jQuery] hasElementClass

2008-07-02 Thread Harald Armin Massa

hello,

I am in the process of converting some MochiKit code to jquery.

I was used to a comfortable funciton

hasElementClass(element, 'classname')

which checked if the element has at least the css_class named
classname

what is the best way to have this in jQuery?

Harald


[jQuery] Re: Newbe: Why can't I reference $('#...') in functions?

2008-07-02 Thread spicyj

I haven't tried it myself, but does it help if you replace the first
three lines with:

$(document).ready(function() {
$(#button).click(filldiv);
});

Just a first thought.
~Ben

lwoods wrote:
 Why can't I reference the DIV using the jQuery format?  Here is the
 example (minus opening HTML):

 script language=javascript src=js/jquery-1.2.3.pack.js/script
 script language=javascript
 !--
 $(function(){
   $(#button).bind('click',filldiv);
 });
 function filldiv(){
   // $('#info').innerHTML='Test';  --- This doesn't work!
   document.getElementById(info).innerHTML=Test;
   }
 //--
 /script
 /head

 body
 input type=button id=button name=button value=Testing /
 div id=info/div
 /body
 /html


[jQuery] Re: zebra striping + flashing/blinking effect?

2008-07-02 Thread sketchy

ahh i didn't know about blink, but the setInterval I think is what
i'm looking for. I couldn't get it to work tho. I don't think i
inserted the code right. This is what i did:

script type=text/javascript
$(document).ready( function() {
$(table.striped tbody tr).mouseover( function() {
$(this).animate({backgroundColor: #4d4d4d}, {queue:false, 
duration:
350 });
}).mouseout( function() {
if($(this).attr(class) == odd) {
$(this).animate({backgroundColor: #1a1a1a}, { 
queue:false,
duration:350});
} else {
$(this).animate({backgroundColor: #343434}, { 
queue:false,
duration:350});
}
});
$(table.striped tbody tr:odd).addClass(odd);
$(table.striped tbody tr:even).addClass(even);

setInterval(function() {
 $('tr:lt(2)').toggleClass('blinky');
}, 500);

});

/script

Since its set to have the first two tr to blink i don't need to put
div id=blinky before the tr I want to blink?
How can you add a fade in and fade out to setInterval? I think that
would make it alot smoother between blinks.

On Jul 1, 10:15 pm, Karl Swedberg [EMAIL PROTECTED] wrote:
 You could try this:

 blinkI'm blinking like it's 1999/blink

   :-)

 Or you could use a setInterval:

 setInterval(function() {
  $('tr:lt(2)').toggleClass('blinky');

 }, 500);

 That one toggles the blinky class on the first 2 TR elements every
 1/2 second.

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

 On Jul 1, 2008, at 9:15 PM, sketchy wrote:



  I think you misunderstood my post. It works fine but i'm looking to
  add more with an effect such as flashing/blinking rows to represent
  that its important to the visitor to check it out.

  On Jul 1, 2:55 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
  A zebra stripe doesn't need any Javascript given IE7, either. The
  tr:hover bit is accepted by the browser if your doctype is set to
  strict mode.

  On Jun 30, 10:15 pm, sketchy [EMAIL PROTECTED] wrote:

  I recently got acquainted with jquery and implemented this
  tutorial on
  zebra striping to my 
  site:http://docs.jquery.com/Tutorials:Zebra_Striping_Made_Easy

  and its awesome but i was wondering it its possible to add like a
  blinking/flashing effect to one or a couple of the rows. The effect
  would start when the visitor opens the page and then stop when they
  leave.

  My knowledge on jquery is quite limited right now so it would
  great if
  someone could help me out. Thanks


[jQuery] Superfish Question: Menu Disappear onclick

2008-07-02 Thread KClough

I've got a request from a client to have the menu disappear after an
item is clicked so the user knows that their click was registered.
Ideally, the next page would come up fast enough where the user
wouldn't need this visual cue, but many of these pages contain a lot
of data and take a few seconds to load initially.

I'm pretty new to jQuery, so I'm not really sure of the best way to do
this. I see that superfish has a hideSuperfishUl function, but I have
no clue how to call it externally to superfish, or how to add the
onclick to the menu elements to call this function.

Any help would be greatly appreciated.



[jQuery] inserting class into table element

2008-07-02 Thread Robert Djurasaj

Does anyone know how can i add a class into existing table element
using jQuery??

ex:table class=tablesorter


[jQuery] Superfish 1.4.2 released - plus new optional 'Supersubs' add-on plugin

2008-07-02 Thread Joel Birch

Hi everyone,

I've just updated the Superfish plugin to version 1.4.2. There are
substantial changes to the example CSS files - the main example file
in particular. The CSS in that file is greatly simplified which should
make creating new menus based upon it quite a lot easier. I have
brought the docs up to date too.
http://users.tpg.com.au/j_birch/plugins/superfish/

I've also been egged-on to create a new plugin which can be optionally
added to a Superfish menu. If used, it will dynamically alter the
submenu widths to the size of the largest list item within each one. I
discussed this plugin on the list over the last week under the name of
'autoSubWidths', but I have since completely recoded it after some
great advice from Dan Switzer. The JS file is thoroughly commented but
there is no documentation yet. However, a cheap and nasty test page is
here:
http://users.tpg.com.au/j_birch/plugins/supersubs/

Thanks go to everyone who have used Superfish and motivated me to
continue with their feedback and kind words.

Joel Birch.


[jQuery] Re: Superfish Question: Menu Disappear onclick

2008-07-02 Thread Joel Birch

Hello,

How about this - or something very like it:

$(document).ready(function() {
$('ul.nav').superfish().click(function(){
$(this).hide();
});
});

I guess clicking anywhere in the nav is suitable. Might not need to
attach the click handler to the links really. You may want to
experiment with .css('visibility','hidden') instead of hide() as the
latter could make other page elements move around disconcertingly.

Joel Birch.


[jQuery] unsubscribe me

2008-07-02 Thread Rohit Mandlik
Hi,

How can i unsubscribe from this forum so i will not get more mails from this
forum.
I forgot my username and password.
please help me

thanks
Rohit


[jQuery] Re: inserting class into table element

2008-07-02 Thread Richard D. Worth
$(table.tablesorter).addClass(newclass);

- Richard

On Wed, Jul 2, 2008 at 12:41 PM, Robert Djurasaj [EMAIL PROTECTED]
wrote:


 Does anyone know how can i add a class into existing table element
 using jQuery??

 ex:table class=tablesorter



[jQuery] Re: inserting class into table element

2008-07-02 Thread Robert Djurasaj

Hi Richard,

I currently have table ...and i would like to change it into table
class=tablesorter

will this do the trick?

robert

On Jul 2, 1:13 pm, Richard D. Worth [EMAIL PROTECTED] wrote:
 $(table.tablesorter).addClass(newclass);

 - Richard

 On Wed, Jul 2, 2008 at 12:41 PM, Robert Djurasaj [EMAIL PROTECTED]
 wrote:



  Does anyone know how can i add a class into existing table element
  using jQuery??

  ex:table class=tablesorter


[jQuery] Re: inserting class into table element

2008-07-02 Thread Robert Djurasaj

curently i have table and i would like to end up with table
class=tablesorter ...

will this do it??

On Jul 2, 1:13 pm, Richard D. Worth [EMAIL PROTECTED] wrote:
 $(table.tablesorter).addClass(newclass);

 - Richard

 On Wed, Jul 2, 2008 at 12:41 PM, Robert Djurasaj [EMAIL PROTECTED]
 wrote:



  Does anyone know how can i add a class into existing table element
  using jQuery??

  ex:table class=tablesorter


[jQuery] Re: inserting class into table element

2008-07-02 Thread Richard D. Worth
in that case you want

$(table).addclass(tablesorter);

though that will add the tablesorter class to all tables. If you want to add
it only to one table, best to have an id on the table, then do:

$(#myTableId).addClass(tablesorter);

- Richard

On Wed, Jul 2, 2008 at 1:26 PM, Robert Djurasaj [EMAIL PROTECTED]
wrote:


 Hi Richard,

 I currently have table ...and i would like to change it into table
 class=tablesorter

 will this do the trick?

 robert

 On Jul 2, 1:13 pm, Richard D. Worth [EMAIL PROTECTED] wrote:
  $(table.tablesorter).addClass(newclass);
 
  - Richard
 
  On Wed, Jul 2, 2008 at 12:41 PM, Robert Djurasaj 
 [EMAIL PROTECTED]
  wrote:
 
 
 
   Does anyone know how can i add a class into existing table element
   using jQuery??
 
   ex:table class=tablesorter



[jQuery] Re: unsubscribe me

2008-07-02 Thread Eric Martin

Click the Edit my membership on the right, then click the
Unsubscribe button...

On Jul 2, 10:05 am, Rohit Mandlik [EMAIL PROTECTED] wrote:
 Hi,

 How can i unsubscribe from this forum so i will not get more mails from this
 forum.
 I forgot my username and password.
 please help me

 thanks
 Rohit


[jQuery] Re: Superfish Question: Menu Disappear onclick

2008-07-02 Thread Joel Birch

Sorry - I interpreted your request wrong I think. Try this instead:

$(document).ready(function() {
$('ul.nav').superfish(/*options if required*/).find('li').click(function() {
$(this).hideSuperfishUl();
});
});

...untested, but you never know your luck. Actually, you can probably
just use .hide() instead of .hideSuperfish() there.

Joel Birch.


[jQuery] Re: Using ASCII characters in textfield

2008-07-02 Thread Jörn Zaefferer

Set encoding of the enclosing page to UTF-8 and encode the page and
the data, no matter if local data or retrieved via ajax, as UTF-8.
Avoid using entity encodings entirely - as long as the encoding is
right, you won't need them anyway.

It may be hard to get there, but its more then worth the trouble!

Jörn

On Wed, Jul 2, 2008 at 4:02 PM, Gearóid O'Ceallaigh [EMAIL PROTECTED] wrote:

 I'm using an autocomplete function on a textfield but I'm having a
 problem since the autocomplete array is filled with German words so
 special characters (such as ü, ä and ö). I can insert the ASCII codes
 for these characters in the array and when the autocomplete display
 pulls down, the array elements are displayed correctly.

 However, when the user selects an option with a German character, the
 ASCII code of the element is displayed instead of the German
 character.

 For example, if the user selects Anlagenführer, the text field would
 be populated with Anlagenfuuml;hrer.

 Does anyone have any ideas of a workaround?



[jQuery] Re: hasElementClass

2008-07-02 Thread John Resig

jQuery(element).hasClass('classname')

--John


On Wed, Jul 2, 2008 at 12:18 PM, Harald Armin Massa
[EMAIL PROTECTED] wrote:

 hello,

 I am in the process of converting some MochiKit code to jquery.

 I was used to a comfortable funciton

 hasElementClass(element, 'classname')

 which checked if the element has at least the css_class named
 classname

 what is the best way to have this in jQuery?

 Harald



[jQuery] Re: Issue using a long array in jquery autocomplete

2008-07-02 Thread Abba . Bryant

Check that there isn't a comma at the end of the last item in your
array. I had the same problem with autocomplete and it turned out that
I had a comma at the end of the last item due to an oversimplified
loop serverside to output the array.

IE

[ 'item', 'item', 'item', ] will break in IE but not FF etc.

you want

[ 'item', 'item', 'item ] notice no trailing ',' at the end of the
final item.


On Jul 1, 5:56 am, Gearóid O'Ceallaigh [EMAIL PROTECTED] wrote:
 Hi, thanks for the reply.

 I can't post the page since the site is being developed locally. I
 figured out several things that may prove useful however. I tried
 using a group of the data to see if this was the problem. IE6 returned
 the same error: Unterminated String Contstant but I noticed that the
 line it had a problem with had a German character ( ü ) in it. An
 element before this in the list also had this character but threw up
 no problem. The word in which the character is used was
  (something)führer so I rename all elements with the word führer and
 replaced them with fuhrer. The smaller array now worked.

 I tried applying the same technique (as a stop gap) to the larger
 array but again IE6 was complaining about an unterminated string
 constant. I then removed all cases of the character ü and replaced
 them with u. Now IE has the error Expected ']'  about halfway
 through the array. There is no syntax error around these lines - I've
 checked a few times.

 Is there a chance that these foreign characters are causing the errors
 within the script?

 On Jun 30, 3:59 pm, gf [EMAIL PROTECTED] wrote:

  On Jun 30, 3:38 am, Gearóid O'Ceallaigh [EMAIL PROTECTED] wrote:

   Hi,

   I'm using bassistance's autocomplete on a website (plugin page found
   here:http://plugins.jquery.com/project/autocompletex). Its perfect
   for I need since it allows the data for the autocomplete to be loaded
   from a local array. However, whilst the autocomplete works fine in
   most browsers - it seems that the length of the array is throwing up
   an error in IE6. The array contains maybe 500+ elements of data but
   even if I put them on a single line in the code, the error still gets
   thrown up.

   Has anyone else ever had this problem?

  It's possible but not real likely that IE6 has a bug preventing it
  from handling that many elements. Without seeing the error nobody can
  say for sure.

  Having programmed for a long-long time, my instinct is to say more
  likely it's some sort of quoting or delimiting bug in the array
  definition. With that many elements it's hard to scan through them by
  eye unless you have laid them out in a very organized fashion. Our
  eyes and brain are good at finding changes in a pattern of orderly
  rows and columns, not at finding a missing comma or quote in pages of
  characters. So, I always line my arrays up vertically into columns as
  much as possible. (A programming editor like vim with the align module
  makes it really easy.)

  My next thought is I would use an Ajax query to reduce the array of
  500 down to something a lot more manageable. You don't say how big
  each element is, but that many elements will slow page load and
  rendering making your user's browser bog down a bit.

  Do you have the offending page somewhere that others can see it so
  they can try to figure out what's wrong? Don't post the code here as
  it'll cause screams as people open up that many lines of code.


[jQuery] Re: Noob question about accessing element contents

2008-07-02 Thread Brian J. Fink

Let's say you've got the element stored in a variable as an
XMLElement, then it would be a simple matter to refer to the jQuery
object of the element itself, for example, for variable elem:

$(elem,xml).text()

On Jul 2, 12:10 pm, Richard D. Worth [EMAIL PROTECTED] wrote:
 $('item', xml).eq(1).text()

 - Richard

 On Wed, Jul 2, 2008 at 11:51 AM, ml1 [EMAIL PROTECTED] wrote:

  I'm trying to find out the best practice for getting the contents of
  one particular element.  I know about the each() call.

  As I said I can use ways that seem not so efficient to get the
  contents of a single element but I want to know the best way.

  On Jul 1, 5:20 pm, Mike Alsup [EMAIL PROTECTED] wrote:
I am using jquery to parse some xml.  I'm looking for the best
practice to access an elements text contents.

Let's say my xml looks like this:

items
  item
 Hello world!
   /item
   item
  Goodnight moon!
   /item
items

I can get a wrapped set of the elements this way: $('items  item',
xml)

And I can get the text of element 1 this way:  $('items  item:eq(1)',
xml).text()

But how do I get the contents once I am directly accessing the element
instead of the jquery object?

In other words I'd like to do something like this: $('items  item',
xml)[1].text(), but since the element that's returned from the array
[] doesn't support text() how do I get it's contents?

I know I can wrap it in a second $ call, as in $($('items  item', xml)
[1]).text() but that seems less than ideal.

   Why do you need to access the element?  Are you trying to get the
   contents of each 'item'?  If so, here's a way to do that:

   $('items  item').each(i,o) {
   // in this loop 'i' is the index of the loop iteration
   // and 'o' is the object of the iteration (item element in this
   case)
   var $item = $(o); //  could also do:  var $item = $(this);
   var txt = $item.text();

   });


[jQuery] Re: unsubscribe me

2008-07-02 Thread Brian J. Fink

@Eric: He said he forgot his username and password.
@Rohit: Then how did you log in to post this?

On Jul 2, 1:56 pm, Eric Martin [EMAIL PROTECTED] wrote:
 Click the Edit my membership on the right, then click the
 Unsubscribe button...

 On Jul 2, 10:05 am, Rohit Mandlik [EMAIL PROTECTED] wrote:

  Hi,

  How can i unsubscribe from this forum so i will not get more mails from this
  forum.
  I forgot my username and password.
  please help me

  thanks
  @Rohit


[jQuery] Re: Newbe: Why can't I reference $('#...') in functions?

2008-07-02 Thread Brian J. Fink

$() is exactly the same as $(document).ready()

On Jul 2, 12:20 pm, spicyj [EMAIL PROTECTED] wrote:
 I haven't tried it myself, but does it help if you replace the first
 three lines with:

 $(document).ready(function() {
 $(#button).click(filldiv);

 });

 Just a first thought.
 ~Ben

 lwoods wrote:
  Why can't I reference the DIV using the jQuery format?  Here is the
  example (minus opening HTML):

  script language=javascript src=js/jquery-1.2.3.pack.js/script
  script language=javascript
  !--
  $(function(){
 $(#button).bind('click',filldiv);
  });
  function filldiv(){
 // $('#info').innerHTML='Test';  --- This doesn't work!
 document.getElementById(info).innerHTML=Test;
 }
  //--
  /script
  /head

  body
  input type=button id=button name=button value=Testing /
  div id=info/div
  /body
  /html


[jQuery] Re: Modifying table cell text

2008-07-02 Thread P

Thank you! Problem solved.

On Jul 2, 5:41 pm, Richard D. Worth [EMAIL PROTECTED] wrote:
 $(.highest-rated td.rating).each(function() {
   var rating = $(this).text();
   $(this).html('img src=images/rating-' + rating + '.gif /');

 });

 - Richard

 On Wed, Jul 2, 2008 at 11:02 AM, P [EMAIL PROTECTED] wrote:

  I have a table that looks like this:

  --

  div class=highest-rated
  table
  tr
         td class=titleLorem ipsum/td
   td class=categoryAudio/td
   td class=rating3/td
  /tr
  tr
         td class=titleFoo/td
   td class=categoryVideo/td
   td class=rating2/td
  /tr
  tr
         td class=titleBar/td
   td class=categoryVideo/td
   td class=rating2/td
  /tr
  tr
         td class=titleHello world/td
   td class=categoryAudio/td
   td class=rating1/td
  /tr
  /table
  /div

  --

  With a little jquery magic I would like to modify the text of the
  rating cell and have it display an image.
  This should be the outcome:

  --

  div class=highest-rated
  table
  tr
         td class=titleLorem ipsum/td
   td class=categoryAudio/td
   td class=ratingimg src=images/rating-3.gif //td
  /tr
  tr
         td class=titleFoo/td
   td class=categoryVideo/td
   td class=ratingimg src=images/rating-2.gif //td
  /tr
  tr
         td class=titleBar/td
   td class=categoryVideo/td
   td class=ratingimg src=images/rating-2.gif //td
  /tr
  tr
         td class=titleHello world/td
   td class=categoryAudio/td
   td class=ratingimg src=images/rating-1.gif //td
  /tr
  /table
  /div

  --

  The number of table rows may vary on different pages.
  How should I do this...?

  Regards,
  Per


[jQuery] SUPERFISH IE 6 help

2008-07-02 Thread ethayer594

I'm having problems with the DDNAV in IE 6.

First off, I think it's causing my headers width to display smaller.

Second, the DDNAV extends the entire width of the browser.

This is the first time I have used this style DD menu so any help is
appreciated.
Thanks

site: http://www.goldfishnw.biz/TualatinFoodPantry/

CSS: http://www.goldfishnw.biz/TualatinFoodPantry/MainNav.css

CSS: http://www.goldfishnw.biz/TualatinFoodPantry/superfish.css


[jQuery] Re: Noob question about accessing element contents

2008-07-02 Thread Brian J. Fink

This forum is about using jQuery, so our answers will usually be
focused on the best JQUERY way, not necessarily the BEST way.

On Jul 2, 11:51 am, ml1 [EMAIL PROTECTED] wrote:
 I'm trying to find out the best practice for getting the contents of
 one particular element.  I know about the each() call.

 As I said I can use ways that seem not so efficient to get the
 contents of a single element but I want to know the best way.

 On Jul 1, 5:20 pm, Mike Alsup [EMAIL PROTECTED] wrote:

   I am using jquery to parse some xml.  I'm looking for the best
   practice to access an elements text contents.

   Let's say my xml looks like this:

   items
 item
Hello world!
  /item
  item
 Goodnight moon!
  /item
   items

   I can get a wrapped set of the elements this way: $('items  item',
   xml)

   And I can get the text of element 1 this way:  $('items  item:eq(1)',
   xml).text()

   But how do I get the contents once I am directly accessing the element
   instead of the jquery object?

   In other words I'd like to do something like this: $('items  item',
   xml)[1].text(), but since the element that’s returned from the array
   [] doesn’t support text() how do I get it’s contents?

   I know I can wrap it in a second $ call, as in $($('items  item', xml)
   [1]).text() but that seems less than ideal.

  Why do you need to access the element?  Are you trying to get the
  contents of each 'item'?  If so, here's a way to do that:

  $('items  item').each(i,o) {
  // in this loop 'i' is the index of the loop iteration
  // and 'o' is the object of the iteration (item element in this
  case)
  var $item = $(o); //  could also do:  var $item = $(this);
  var txt = $item.text();

  });


[jQuery] Re: unsubscribe me

2008-07-02 Thread spicyj

Your username is [EMAIL PROTECTED]

On Jul 2, 11:05 am, Rohit Mandlik [EMAIL PROTECTED] wrote:
 Hi,

 How can i unsubscribe from this forum so i will not get more mails from this
 forum.
 I forgot my username and password.
 please help me

 thanks
 Rohit


[jQuery] Re: unsubscribe me

2008-07-02 Thread Bil Corry

Rohit Mandlik wrote on 7/2/2008 12:05 PM: 
 How can i unsubscribe from this forum so i will not get more mails from this
 forum.
 I forgot my username and password.

How are you sending and receiving email from your gmail account if you don't 
know your username and password?  Your username and password is the same for 
both gmail and googlegroups.

To unsubscribe, go here and click on the button labeled unsubscribe:

http://groups.google.com/group/jquery-en/subscribe


- Bil




[jQuery] FF doesn't recognize elements created with .append?

2008-07-02 Thread JohnieKarr

Hello all,

I am working on this form (http://www.datamt.org/vornado/test.htm) and
everything works fine in IE, but in FF it does not.

What is supposed to happen is you select an item from the drop down
and it auto generates the description for you.  You can also click Add
An Item button to add a new row to the table, so you can create a new
item.

In FF creating the new row works fine, but whenever the drop menu is
changed, FF gives the following error:

Error: document.getElementById(yDesc) has no properties
Source File: file:///F:/Alan%20Wicks/data3.js
Line: 355

the function that contains line 355 is as follows:

function getDescription(dList,xNum){
var yDesc;
yDesc = 'itemDesc' + xNum;
if (dList == ){
document.getElementById(yDesc).value = ;
}
else {
document.getElementById(yDesc).value = descriptionList[dList];
}
}

the element is a select box, and is not created with HTML, but is
created using the .append feature.
$('table#items')
.append(newItem);
document.getElementById('numItems').value = x;


I'm assuming the problem is that FF doesn't recognize elements that
are created outside of the HTML?

Any help would be greatly appreciated.

I'm using LiveQuery to add the table row.  newItem is the variable
name of the row.  Below is how it is defined:

var newItem;
newItem = 'trtd style=text-align: center;';
newItem = newItem + 'select name=item' + x + '
onchange=getDescription(this.value,'+x+');';
newItem = newItem + 'option value= selected=selectedPlease
Select An Item\/option';
newItem = newItem + getOptions();
newItem = newItem + '\/select/td';
newItem = newItem + 'tdinput name=itemDesc' + x + ' 
size=70 /
/td';
newItem = newItem + 'tdinput name=qty' + x + ' size=5 
//
td';
newItem = newItem + '/tr';

Thanks,
Johnie Karr


[jQuery] Re: Superfish Question: Menu Disappear onclick

2008-07-02 Thread KClough

Thanks Joel, you rock.

I ended up going with
$(document).ready(function() {
$('ul.nav').superfish().click(function(){
$(this).find(ul).hide();
});
});

So the original menu is still there, sometimes new items open in a new
window, so I didn't want it to hide for good. This with hoverintent
makes superfish feel very responsive. I highly recommend it.



On Jul 2, 1:04 pm, Joel Birch [EMAIL PROTECTED] wrote:
 Hello,

 How about this - or something very like it:

 $(document).ready(function() {
     $('ul.nav').superfish().click(function(){
         $(this).hide();
     });

 });

 I guess clicking anywhere in the nav is suitable. Might not need to
 attach the click handler to the links really. You may want to
 experiment with .css('visibility','hidden') instead of hide() as the
 latter could make other page elements move around disconcertingly.

 Joel Birch.


[jQuery] Re: Firefox/css/jquery..

2008-07-02 Thread Aaron

the website is supposed to show a texted image, which is behind a
table, that table is like a light blueish looking box, and the text is
behind it yet I want it in front on top of that box.

On Jul 2, 11:00 am, MorningZ [EMAIL PROTECTED] wrote:
 I just noticed that firefox dosen't support the z-index

 Of course FF supports z-index...

 something is wrong with your code/markup, not with FireFox or jQuery

 Got a live link to show what you cannot get working?


[jQuery] Re: [validate] jquery.delegate.js is missing?

2008-07-02 Thread Jörn Zaefferer

Hi Jez,

the delegate plugin is bundled within jquery.validate.js since the
1.2.1 release (early Februar this year). You don't have to manually
include it.

It sounds like you got an outdated release, where did you find that?
The current plugin page doesn't mention the dependency anywhere
(http://plugins.jquery.com/project/validate)

Jörn

On Wed, Jul 2, 2008 at 5:22 PM, jez_p [EMAIL PROTECTED] wrote:

 Thank you for your reply John.

 I thought the author might appreciate the heads up that is not
 included within the package when it is linked to within the included
 demo/index.html, implying that it should have been included.

 OK, so now I have it, do I simply put in the same folder as my
 jquery.js, or do i have to do anything else with it?

 Thanks,

 Jez

 On Jul 2, 3:57 pm, John Resig [EMAIL PROTECTED] wrote:
 Popping jquery.delegate.js into Google provides 
 this:http://dev.jquery.com/export/5759/trunk/plugins/delegate/jquery.deleg...

 --John

 On Wed, Jul 2, 2008 at 9:17 AM, jez_p [EMAIL PROTECTED] wrote:

  I should just explain that I'm very new to jQuery. That out of the
  way, I have downloaded the validation plug-in which states that
  jquery.delegate.js is required. It is not included within the package,
  so where can I obtain it from, and once I have it how should I include
  it within my project?

  Thanks,

  Jez



[jQuery] Re: Firefox/css/jquery..

2008-07-02 Thread Peter Higgins

Hmm looks like you have a DNS mishap?

[EMAIL PROTECTED]:~$ host www.chillenvillen.com
www.chillenvillen.com is an alias for chillenvillen.com.
chillenvillen.com has address 68.178.232.100
chillenvillen.com has address 192.168.1.101

... and here I though you had plagiarized my dev server ;)

Regards

Aaron wrote:
 ya well take a look at the website, type in www.chillenvillen.com and
 you will see it.

 On Jul 2, 11:00 am, MorningZ [EMAIL PROTECTED] wrote:
   
 I just noticed that firefox dosen't support the z-index

 Of course FF supports z-index...

 something is wrong with your code/markup, not with FireFox or jQuery

 Got a live link to show what you cannot get working?
 



[jQuery] Re: Firefox/css/jquery..

2008-07-02 Thread Kevin Scholl

The z-index value need not be in quotes. You have:

z-index: 1

which should be simply:

z-index: 1

Also, you need a doctype in your HTML document, or you're going to run
into all manner of display issues.


On Jul 2, 2:32 pm, Aaron [EMAIL PROTECTED] wrote:
 the website is supposed to show a texted image, which is behind a
 table, that table is like a light blueish looking box, and the text is
 behind it yet I want it in front on top of that box.

 On Jul 2, 11:00 am, MorningZ [EMAIL PROTECTED] wrote:

  I just noticed that firefox dosen't support the z-index

  Of course FF supports z-index...

  something is wrong with your code/markup, not with FireFox or jQuery

  Got a live link to show what you cannot get working?


[jQuery] Re: Firefox/css/jquery..

2008-07-02 Thread Aaron

OK found out the problem. It was my domain name hosting service
provider they added a ipaddress thinking I was using their website
hosting service so I just deleted that record all should work find.
Thanks for telling me about this.

On Jul 2, 3:09 pm, Peter Higgins [EMAIL PROTECTED] wrote:
 Hmm looks like you have a DNS mishap?

 [EMAIL PROTECTED]:~$ hostwww.chillenvillen.comwww.chillenvillen.comis an 
 alias for chillenvillen.com.
 chillenvillen.com has address 68.178.232.100
 chillenvillen.com has address 192.168.1.101

 ... and here I though you had plagiarized my dev server ;)

 Regards

 Aaron wrote:
  ya well take a look at the website, type inwww.chillenvillen.comand
  you will see it.

  On Jul 2, 11:00 am, MorningZ [EMAIL PROTECTED] wrote:

  I just noticed that firefox dosen't support the z-index

  Of course FF supports z-index...

  something is wrong with your code/markup, not with FireFox or jQuery

  Got a live link to show what you cannot get working?


[jQuery] Re: Firefox/css/jquery..

2008-07-02 Thread Aaron

what is that 68.178.232.100 ip address is that yours??
over here I done the same and found that ip and above it was my
external ip and then the one that you see with the 192.ect.
I never assigned any 68.178...ect ip address.

On Jul 2, 3:09 pm, Peter Higgins [EMAIL PROTECTED] wrote:
 Hmm looks like you have a DNS mishap?

 [EMAIL PROTECTED]:~$ hostwww.chillenvillen.comwww.chillenvillen.comis an 
 alias for chillenvillen.com.
 chillenvillen.com has address 68.178.232.100
 chillenvillen.com has address 192.168.1.101

 ... and here I though you had plagiarized my dev server ;)

 Regards

 Aaron wrote:
  ya well take a look at the website, type inwww.chillenvillen.comand
  you will see it.

  On Jul 2, 11:00 am, MorningZ [EMAIL PROTECTED] wrote:

  I just noticed that firefox dosen't support the z-index

  Of course FF supports z-index...

  something is wrong with your code/markup, not with FireFox or jQuery

  Got a live link to show what you cannot get working?


[jQuery] Re: Star Rating Plugin

2008-07-02 Thread C.Everson

On Wed, 2 Jul 2008 07:32:14 -0700 (PDT), Diego A. wrote:

 Thanks for pointing that out.
 
 Silly me thought it would be OK to test using the Simulate IE7
 feature in IE8.
 Turns out not even that works in IE...

LOL - I can believe that.  I don't even have IE8 beta installed right now
as it is still too early IMHO to be worth more than a casual glance now
and then...
 
 Anyway, lesson learnt, all fixed now!

Thanks - much better now!

One small thing I did notice (when comparing IE7 with FF2)

At http://www.fyneworks.com/jquery/star-rating/#tab-Download

In IE7 on the download tab after the word Package and before V2.3 there
is a weird graphic display (maybe a messed up bullet?) that does not appear
in FF.

Not sure what is up there, but figured you'd want to know.

Chuck




[jQuery] jCarousel intergration

2008-07-02 Thread Havoc

Hi there,

  I'm trying to implement the jCarousel at:  . My carousel has
multiple ul containers. When a user presses a button the main ul
container gets swapped with another one. Is there a way to clear the
main ul container and reload the carousel?

Something like this:

var main_List = [
Pictures
]

var tab1 = [Pictures] var tab2 = [picutres]

button onClick=main_List = tab2;tab2

The main_List gets loaded correctly.

jQuery('#mycarousel').jcarousel({
wrap: 'circular',
itemVisibleInCallback: {onBeforeAnimation:
mycarousel_itemVisibleInCallback},
itemVisibleOutCallback: {onAfterAnimation:
mycarousel_itemVisibleOutCallback}
});

I just can't seem to call the carousel reset funtion properly.

Any ideas?

Thanks in advance


[jQuery] Re: [validate] jquery.delegate.js is missing?

2008-07-02 Thread jez_p

Thanks for replying Jörn.

I was confused by the line:

jquery.delegate.js - special event delegation, required

which is under the heading of Javascript files used at the bottom of
the demo page:

http://jquery.bassistance.de/validate/demo/ ,  which is also in the
demo folder in the download.

Cheers,

Jez



On Jul 2, 8:03 pm, Jörn Zaefferer [EMAIL PROTECTED]
wrote:
 Hi Jez,

 the delegate plugin is bundled within jquery.validate.js since the
 1.2.1 release (early Februar this year). You don't have to manually
 include it.

 It sounds like you got an outdated release, where did you find that?
 The current plugin page doesn't mention the dependency anywhere
 (http://plugins.jquery.com/project/validate)

 Jörn

 On Wed, Jul 2, 2008 at 5:22 PM, jez_p [EMAIL PROTECTED] wrote:

  Thank you for your reply John.

  I thought the author might appreciate the heads up that is not
  included within the package when it is linked to within the included
  demo/index.html, implying that it should have been included.

  OK, so now I have it, do I simply put in the same folder as my
  jquery.js, or do i have to do anything else with it?

  Thanks,

  Jez

  On Jul 2, 3:57 pm, John Resig [EMAIL PROTECTED] wrote:
  Popping jquery.delegate.js into Google provides 
  this:http://dev.jquery.com/export/5759/trunk/plugins/delegate/jquery.deleg...

  --John

  On Wed, Jul 2, 2008 at 9:17 AM, jez_p [EMAIL PROTECTED] wrote:

   I should just explain that I'm very new to jQuery. That out of the
   way, I have downloaded the validation plug-in which states that
   jquery.delegate.js is required. It is not included within the package,
   so where can I obtain it from, and once I have it how should I include
   it within my project?

   Thanks,

   Jez


[jQuery] Re: [validate] jquery.delegate.js is missing?

2008-07-02 Thread Jörn Zaefferer

Ah, thanks for the pointer. I'll update that.

Jörn

On Wed, Jul 2, 2008 at 10:09 PM, jez_p [EMAIL PROTECTED] wrote:

 Thanks for replying Jörn.

 I was confused by the line:

 jquery.delegate.js - special event delegation, required

 which is under the heading of Javascript files used at the bottom of
 the demo page:

 http://jquery.bassistance.de/validate/demo/ ,  which is also in the
 demo folder in the download.

 Cheers,

 Jez



 On Jul 2, 8:03 pm, Jörn Zaefferer [EMAIL PROTECTED]
 wrote:
 Hi Jez,

 the delegate plugin is bundled within jquery.validate.js since the
 1.2.1 release (early Februar this year). You don't have to manually
 include it.

 It sounds like you got an outdated release, where did you find that?
 The current plugin page doesn't mention the dependency anywhere
 (http://plugins.jquery.com/project/validate)

 Jörn

 On Wed, Jul 2, 2008 at 5:22 PM, jez_p [EMAIL PROTECTED] wrote:

  Thank you for your reply John.

  I thought the author might appreciate the heads up that is not
  included within the package when it is linked to within the included
  demo/index.html, implying that it should have been included.

  OK, so now I have it, do I simply put in the same folder as my
  jquery.js, or do i have to do anything else with it?

  Thanks,

  Jez

  On Jul 2, 3:57 pm, John Resig [EMAIL PROTECTED] wrote:
  Popping jquery.delegate.js into Google provides 
  this:http://dev.jquery.com/export/5759/trunk/plugins/delegate/jquery.deleg...

  --John

  On Wed, Jul 2, 2008 at 9:17 AM, jez_p [EMAIL PROTECTED] wrote:

   I should just explain that I'm very new to jQuery. That out of the
   way, I have downloaded the validation plug-in which states that
   jquery.delegate.js is required. It is not included within the package,
   so where can I obtain it from, and once I have it how should I include
   it within my project?

   Thanks,

   Jez



[jQuery] Re: Position cursor at end of textbox?

2008-07-02 Thread Brian J. Fink

There may be a jQuery way to do this, but I don't know what it is.

However, I do know 2 ways to accomplish this: one DOM way, one IE way.
Both methods must be employed.

$(function() {
 $('input[type=text]').bind('focus',function() {
  window.o=this;
  if (o.setSelectionRange) /* DOM */
   setTimeout('o.setSelectionRange(o.value.length,o.value.length)',2);
  else if (o.createTextRange) /* IE */
  {
   var r=o.createTextRange();
   r.moveStart('character',o.value.length);
   r.select();
  }
 });
});


On Jul 2, 2:55 pm, Paul Malan [EMAIL PROTECTED] wrote:
 By default it seems browsers select all the text in a textbox when it
 gains focus by way of a tab-press.  I would like the cursor to be
 positioned at the end of any existing text in the input, instead.  The
 examples I'm turning up on Google don't work and seem needlessly
 complex, and since jQuery simplifies everything else I used to hate
 about Javascript, I thought I'd see if there's a simple way to
 position the cursor in a text input box on focus.  Is it doable?

 Thanks...


[jQuery] Passing a variable into the $('selector') function

2008-07-02 Thread Stompfrog

Hi all,

I have a problem that I can't crack.

I have a function similar to this..

 $.ajax({
   type: POST,
   url: some.php,
   data: name=Johnlocation=Boston,
   success: function(msg){
 alert( Data Saved:  + msg );
   }
 });

The data that gets passed back to the function from some.php is a
string which is the id of the div that I want to manipulate in the
callback function e.g. #myDiv.

My question is how can I get that div from the callback function using
the msg variable because $(msg); doesn't work and neither does $
('+msg+');

Thanks in advance,

Stompfrog







[jQuery] Jquery validation

2008-07-02 Thread konda

HI,
  We are trying to use Jquery validation plugin for client side
validation. It is working okay. The error message displays if the form
validation fails. But we need the error display  to highlight the
entire row including the label and the input element. Is there a way
to do this in JQuery Validation plugin?


div
label for=firstnameFirstname/label
input id=firstname name=firstnamet /
   /div


Basically we need to color the entire div element red.


[jQuery] Re: Targeting an element with multiple classes

2008-07-02 Thread Carl Von Stetten

jez_p

Try $('.green')

This will select only elements that have the green class assigned, 
even if other classes are also assigned to the same elements.

Carl

jez_p wrote:
 How do I target a specific class when elements may belong to multiple
 classes?

 For example:

 p class=big redblah blah blah/p
 p class=big greenblah blah blah/p
 p class=small greenblah blah blah/p

 How would I select the elements with the class of green?

 I know that

 'p[class=big green]'  
 'p[class=small green]'

 would work, but I cannot work out how I can just specify wherever
 there is a class of green, and not have to include the other classes
 also.

 Thanks in advance.


   


[jQuery] Re: Passing a variable into the $('selector') function

2008-07-02 Thread Erik Beeson
If msg is '#myDiv' and you have element with id=myDiv, then $(msg) will
select it.

If you think that's what you're doing and it isn't working for you, either
your id is wrong or msg doesn't hold what you think (maybe it has a trailing
\n?).

--Erik


On 7/2/08, Stompfrog [EMAIL PROTECTED] wrote:


 Hi all,

 I have a problem that I can't crack.

 I have a function similar to this..

   $.ajax({
type: POST,
url: some.php,
data: name=Johnlocation=Boston,
success: function(msg){
  alert( Data Saved:  + msg );
}
   });

 The data that gets passed back to the function from some.php is a
 string which is the id of the div that I want to manipulate in the
 callback function e.g. #myDiv.

 My question is how can I get that div from the callback function using
 the msg variable because $(msg); doesn't work and neither does $
 ('+msg+');

 Thanks in advance,


 Stompfrog








[jQuery] Re: jqModal - How to access the iframe from the parent

2008-07-02 Thread Alexandre Plennevaux

On Wed, Jul 2, 2008 at 11:42 PM, Hypolite [EMAIL PROTECTED] wrote:


 I'm still stuck with my jqModal iframe closing problem.

 But this time it's the other way I can't figure out.

 Here is my HTML/JS code for the parent windows :

 div id=div_modal class=jqmWindowiframe id=iframe
 src=form.html/iframe/div

 $().ready(function() {
  $('#div_modal').jqm(); //Initialization of the modal box

  $('#iframe').contents().find('input').click(function() {
$('#div_modal').jqmHide(); //The button inside the iframe must close the
 modal box in the parent
  })
 });

 The documentation says that contents() return the HTML document when
 called on an iframe, but it returns always null.

 Someone's got an idea ?

 Hypolite
 --
 View this message in context: 
 http://www.nabble.com/jqModal---How-to-access-the-parent-window-from-an-iframe--solved--tp18183904s27240p18247490.html
 Sent from the jQuery General Discussion mailing list archive at Nabble.com.




well, AFAIK the only safe solution is to have the close button in the
same window as the jqModal container. you simply cannot access objects
in the main from the iframe for security reasons i think
.
also, i just wrote a how-to using jqModal with iframes. no help for
your specific issue, but maybe it helps for other things.

You can find it here :
http://www.pixeline.be/blog/2008/javascript-loading-external-urls-in-jqmodal-jquery-plugin/

The final example is here: http://www.pixeline.be/experiments/ThickboxToJqModal/

HTH
-- 
Alexandre Plennevaux
LAb[au]

http://www.lab-au.com


[jQuery] Re: possible bug in each()? moving from 1.2.3 to 1.2.6

2008-07-02 Thread Brian J. Fink

Is that the correct way to spell it? Maybe all lowercase would work.
(I don't know. I use $ myself.)

On Jul 2, 6:48 pm, darren [EMAIL PROTECTED] wrote:
 Hi

 Im trying to use 1.2.6, moving from 1.2.3.  I have a working function
 in 1.2.3 but it is not working with the updated jquery library, and
 I'm wondering if i have found a bug.

 The trouble call is this:

 jQuery('#apparatus .annotation').each( function(i){
 ...

 When stepping over this call, firebug returns an error of object not
 defined.

 As I mentioned, this code is working correctly with jQuery 1.2.3.
 Note also I'm using jQuery, not $ for all of my calls.  Also, im using
 jQuery.noConflict(). I have tried to used the uncompressed and packed
 versions, witht he same result.

 Any suggestions?


[jQuery] Re: cant upgrade from 1.2.3 to 1.2.6

2008-07-02 Thread darren

right.

ok well this doesn't look like just an each() error, its happening
with click() now too.

here is the page with the errors:
http://isebeta.uvic.ca/Library/Texts/AYL/M/Scene/1.1

generate the errors by clicking on show or [+] in the Commentary
menu to the lower left of the page.
The former generates a object not defined error
the latter generates a this.style not defined

Again, this code works correctly with 1.2.3.

A suggestion on the irc channel was to first check if the thing being
passed into .each() is not undefined, but I don't really understand
this suggestion.

thanks for any help.

On Jul 2, 3:55 pm, Jeffrey Kretz [EMAIL PROTECTED] wrote:
 That part of the code is the $.each iteration.  What is the call stack when
 the error is thrown?

 Without a better context, it's going to be really hard to see what's going
 on.

 Do you have a demo page with this error?  Even if you can't post the full
 page for security reasons, if you can reproduce the error with a simpler
 demo page that would help track it down.

 JK

 -Original Message-
 From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On

 Behalf Of darren
 Sent: Wednesday, July 02, 2008 3:00 PM
 To: jQuery (English)
 Subject: [jQuery] cant upgrade from 1.2.3 to 1.2.6

 Hi

 I'm trying to upgrade a project from jquery 1.2.3 to 1.2.6, but doing
 so is causing a error in my script  Firebug gives the error:

 object is undefined
 var name, i = 0, length = 
 object.length;http://../script/jquery-1.2.6.js
 Line 725

 I'm going to try to step through my code and narrow down the problem,
 but i'd appreciate any other suggestions.  thanks


[jQuery] Re: Position cursor at end of textbox?

2008-07-02 Thread Erik Beeson
Ick! Global variables and eval'd code! How about (untested, logic should be
unchanged):

$(function() {
$(':text').bind('focus', function() {
var o = this;
if(o.setSelectionRange) { /* DOM */
setTimeout(function()
{o.setSelectionRange(o.value.length,o.value.length);}, 2);
} else if(o.createTextRange) {/* IE */
var r = o.createTextRange();
r.moveStart('character', o.value.length);
r.select();
}
});
});

Adds an anonymous function, which adds a function call, but saves an eval
and doesn't require a global variable, which is potentially problematic.

--Erik



On 7/2/08, Brian J. Fink [EMAIL PROTECTED] wrote:


 And I checked my code again. It DOES work on FF3, FF2, and IE7.


 On Jul 2, 5:37 pm, Paul Malan [EMAIL PROTECTED] wrote:
  Thanks for the code.  It doesn't work for me--still when I tab into a
  textbox in either IE7 or FF3 the content is selected and the cursor
  isn't positioned at the end of the text, even when I pull out
  everything but this function and two textboxes to test.
 
  I think I may just give up--it was a minor detail and not requested by
  the users.  Bugs me, though.  Seems like it shouldn't be so tricksy...
 
  On Jul 2, 3:12 pm, Brian J. Fink [EMAIL PROTECTED] wrote:
 
   There may be a jQuery way to do this, but I don't know what it is.
 
   However, I do know 2 ways to accomplish this: one DOM way, one IE way.
   Both methods must be employed.
 
   $(function() {
$('input[type=text]').bind('focus',function() {
 window.o=this;
 if (o.setSelectionRange) /* DOM */
  setTimeout('o.setSelectionRange(o.value.length,o.value.length)',2);
 else if (o.createTextRange) /* IE */
 {
  var r=o.createTextRange();
  r.moveStart('character',o.value.length);
  r.select();
 }
});
 
   });
 
   On Jul 2, 2:55 pm, Paul Malan [EMAIL PROTECTED] wrote:
 
By default it seems browsers select all the text in a textbox when it
gains focus by way of a tab-press.  I would like the cursor to be
positioned at the end of any existing text in the input,
 instead.  The
examples I'm turning up on Google don't work and seem needlessly
complex, and since jQuery simplifies everything else I used to hate
about Javascript, I thought I'd see if there's a simple way to
position the cursor in a text input box on focus.  Is it doable?
 
Thanks...



[jQuery] Re: Position cursor at end of textbox?

2008-07-02 Thread Brian J. Fink

I believe setTimeouts work outside the scope of the function they are
called from. Test your way but I don't think it'll work.

On Jul 2, 8:12 pm, Erik Beeson [EMAIL PROTECTED] wrote:
 Ick! Global variables and eval'd code! How about (untested, logic should be
 unchanged):

 $(function() {
 $(':text').bind('focus', function() {
 var o = this;
 if(o.setSelectionRange) { /* DOM */
 setTimeout(function()
 {o.setSelectionRange(o.value.length,o.value.length);}, 2);
 } else if(o.createTextRange) {/* IE */
 var r = o.createTextRange();
 r.moveStart('character', o.value.length);
 r.select();
 }
 });

 });

 Adds an anonymous function, which adds a function call, but saves an eval
 and doesn't require a global variable, which is potentially problematic.

 --Erik

 On 7/2/08, Brian J. Fink [EMAIL PROTECTED] wrote:



  And I checked my code again. It DOES work on FF3, FF2, and IE7.

  On Jul 2, 5:37 pm, Paul Malan [EMAIL PROTECTED] wrote:
   Thanks for the code.  It doesn't work for me--still when I tab into a
   textbox in either IE7 or FF3 the content is selected and the cursor
   isn't positioned at the end of the text, even when I pull out
   everything but this function and two textboxes to test.

   I think I may just give up--it was a minor detail and not requested by
   the users.  Bugs me, though.  Seems like it shouldn't be so tricksy...

   On Jul 2, 3:12 pm, Brian J. Fink [EMAIL PROTECTED] wrote:

There may be a jQuery way to do this, but I don't know what it is.

However, I do know 2 ways to accomplish this: one DOM way, one IE way.
Both methods must be employed.

$(function() {
 $('input[type=text]').bind('focus',function() {
  window.o=this;
  if (o.setSelectionRange) /* DOM */
   setTimeout('o.setSelectionRange(o.value.length,o.value.length)',2);
  else if (o.createTextRange) /* IE */
  {
   var r=o.createTextRange();
   r.moveStart('character',o.value.length);
   r.select();
  }
 });

});

On Jul 2, 2:55 pm, Paul Malan [EMAIL PROTECTED] wrote:

 By default it seems browsers select all the text in a textbox when it
 gains focus by way of a tab-press.  I would like the cursor to be
 positioned at the end of any existing text in the input,
  instead.  The
 examples I'm turning up on Google don't work and seem needlessly
 complex, and since jQuery simplifies everything else I used to hate
 about Javascript, I thought I'd see if there's a simple way to
 position the cursor in a text input box on focus.  Is it doable?

 Thanks...


[jQuery] Re: Position cursor at end of textbox?

2008-07-02 Thread Brian J. Fink

My apologies, Erik. Yours is the superior method. I must have been
remembering the behavior of IE5.

On Jul 2, 8:12 pm, Erik Beeson [EMAIL PROTECTED] wrote:
 Ick! Global variables and eval'd code! How about (untested, logic should be
 unchanged):

 $(function() {
 $(':text').bind('focus', function() {
 var o = this;
 if(o.setSelectionRange) { /* DOM */
 setTimeout(function()
 {o.setSelectionRange(o.value.length,o.value.length);}, 2);
 } else if(o.createTextRange) {/* IE */
 var r = o.createTextRange();
 r.moveStart('character', o.value.length);
 r.select();
 }
 });

 });

 Adds an anonymous function, which adds a function call, but saves an eval
 and doesn't require a global variable, which is potentially problematic.

 --Erik

 On 7/2/08, Brian J. Fink [EMAIL PROTECTED] wrote:



  And I checked my code again. It DOES work on FF3, FF2, and IE7.

  On Jul 2, 5:37 pm, Paul Malan [EMAIL PROTECTED] wrote:
   Thanks for the code.  It doesn't work for me--still when I tab into a
   textbox in either IE7 or FF3 the content is selected and the cursor
   isn't positioned at the end of the text, even when I pull out
   everything but this function and two textboxes to test.

   I think I may just give up--it was a minor detail and not requested by
   the users.  Bugs me, though.  Seems like it shouldn't be so tricksy...

   On Jul 2, 3:12 pm, Brian J. Fink [EMAIL PROTECTED] wrote:

There may be a jQuery way to do this, but I don't know what it is.

However, I do know 2 ways to accomplish this: one DOM way, one IE way.
Both methods must be employed.

$(function() {
 $('input[type=text]').bind('focus',function() {
  window.o=this;
  if (o.setSelectionRange) /* DOM */
   setTimeout('o.setSelectionRange(o.value.length,o.value.length)',2);
  else if (o.createTextRange) /* IE */
  {
   var r=o.createTextRange();
   r.moveStart('character',o.value.length);
   r.select();
  }
 });

});

On Jul 2, 2:55 pm, Paul Malan [EMAIL PROTECTED] wrote:

 By default it seems browsers select all the text in a textbox when it
 gains focus by way of a tab-press.  I would like the cursor to be
 positioned at the end of any existing text in the input,
  instead.  The
 examples I'm turning up on Google don't work and seem needlessly
 complex, and since jQuery simplifies everything else I used to hate
 about Javascript, I thought I'd see if there's a simple way to
 position the cursor in a text input box on focus.  Is it doable?

 Thanks...


[jQuery] Re: Position cursor at end of textbox?

2008-07-02 Thread Erik Beeson
No worries. Thanks for taking the time to test it :) Scoping is probably one
of the most unobvious aspects of JavaScript.

--Erik


On 7/2/08, Brian J. Fink [EMAIL PROTECTED] wrote:


 My apologies, Erik. Yours is the superior method. I must have been
 remembering the behavior of IE5.


 On Jul 2, 8:12 pm, Erik Beeson [EMAIL PROTECTED] wrote:

  Ick! Global variables and eval'd code! How about (untested, logic should
 be
  unchanged):
 
  $(function() {
  $(':text').bind('focus', function() {
  var o = this;
  if(o.setSelectionRange) { /* DOM */
  setTimeout(function()
  {o.setSelectionRange(o.value.length,o.value.length);}, 2);
  } else if(o.createTextRange) {/* IE */
  var r = o.createTextRange();
  r.moveStart('character', o.value.length);
  r.select();
  }
  });
 
  });
 
  Adds an anonymous function, which adds a function call, but saves an eval
  and doesn't require a global variable, which is potentially problematic.
 
  --Erik
 

  On 7/2/08, Brian J. Fink [EMAIL PROTECTED] wrote:
 
 
 
   And I checked my code again. It DOES work on FF3, FF2, and IE7.
 
   On Jul 2, 5:37 pm, Paul Malan [EMAIL PROTECTED] wrote:
Thanks for the code.  It doesn't work for me--still when I tab into a
textbox in either IE7 or FF3 the content is selected and the cursor
isn't positioned at the end of the text, even when I pull out
everything but this function and two textboxes to test.
 
I think I may just give up--it was a minor detail and not requested
 by
the users.  Bugs me, though.  Seems like it shouldn't be so
 tricksy...
 
On Jul 2, 3:12 pm, Brian J. Fink [EMAIL PROTECTED] wrote:
 
 There may be a jQuery way to do this, but I don't know what it is.
 
 However, I do know 2 ways to accomplish this: one DOM way, one IE
 way.
 Both methods must be employed.
 
 $(function() {
  $('input[type=text]').bind('focus',function() {
   window.o=this;
   if (o.setSelectionRange) /* DOM */
   
 setTimeout('o.setSelectionRange(o.value.length,o.value.length)',2);
   else if (o.createTextRange) /* IE */
   {
var r=o.createTextRange();
r.moveStart('character',o.value.length);
r.select();
   }
  });
 
 });
 
 On Jul 2, 2:55 pm, Paul Malan [EMAIL PROTECTED] wrote:
 
  By default it seems browsers select all the text in a textbox
 when it
  gains focus by way of a tab-press.  I would like the cursor to be
  positioned at the end of any existing text in the input,
   instead.  The
  examples I'm turning up on Google don't work and seem needlessly
  complex, and since jQuery simplifies everything else I used to
 hate
  about Javascript, I thought I'd see if there's a simple way to
  position the cursor in a text input box on focus.  Is it doable?
 
  Thanks...



[jQuery] Re: cant upgrade from 1.2.3 to 1.2.6

2008-07-02 Thread Jeffrey Kretz

As a note, your apparatusTooltips.js script has a badly-formed array on
lines 30-37.  This doesn't affect FF but will kill IE.

But onto the underlying problem.

The actual issue seems to be with the grep method:

// Go through the array, only saving the items
1197 // that pass the validator function
1198 for ( var i = 0, length = elems.length; i  length; i++ )
1199if ( !inv != !callback( elems[ i ], i ) )
1200   ret.push( elems[ i ] );

When show is called, it first filters by ':hidden'.

There is only 1 element in the elems array.

The loop starts off correctly, going through 1198, 1199, 1200 for the first
iteration.

The second iteration it exist the for loop as (ilength) returns false.

But when exiting the loop, it still executes line 1200, adding a null value
to the return array.

This is likely a bug in FireFox, but it would probably go away if code
blocks { } were expressly defined around the for loop and the if statement.

JK

-Original Message-
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of darren
Sent: Wednesday, July 02, 2008 4:42 PM
To: jQuery (English)
Subject: [jQuery] Re: cant upgrade from 1.2.3 to 1.2.6


right.

ok well this doesn't look like just an each() error, its happening
with click() now too.

here is the page with the errors:
http://isebeta.uvic.ca/Library/Texts/AYL/M/Scene/1.1

generate the errors by clicking on show or [+] in the Commentary
menu to the lower left of the page.
The former generates a object not defined error
the latter generates a this.style not defined

Again, this code works correctly with 1.2.3.

A suggestion on the irc channel was to first check if the thing being
passed into .each() is not undefined, but I don't really understand
this suggestion.

thanks for any help.

On Jul 2, 3:55 pm, Jeffrey Kretz [EMAIL PROTECTED] wrote:
 That part of the code is the $.each iteration.  What is the call stack
when
 the error is thrown?

 Without a better context, it's going to be really hard to see what's going
 on.

 Do you have a demo page with this error?  Even if you can't post the full
 page for security reasons, if you can reproduce the error with a simpler
 demo page that would help track it down.

 JK

 -Original Message-
 From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On

 Behalf Of darren
 Sent: Wednesday, July 02, 2008 3:00 PM
 To: jQuery (English)
 Subject: [jQuery] cant upgrade from 1.2.3 to 1.2.6

 Hi

 I'm trying to upgrade a project from jquery 1.2.3 to 1.2.6, but doing
 so is causing a error in my script  Firebug gives the error:

 object is undefined
 var name, i = 0, length =
object.length;http://../script/jquery-1.2.6.js
 Line 725

 I'm going to try to step through my code and narrow down the problem,
 but i'd appreciate any other suggestions.  thanks



[jQuery] Re: Position cursor at end of textbox?

2008-07-02 Thread spicyj

This might be helpful:

http://pastie.org/226790 // shamelessly stolen from the Masked Input
plugin

$(:text).bind(focus, function() {
  $(this).caret(this.value.length);
});

Not tested, so I don't know if it works, but it might.


[jQuery] jQuery Tooltip with image map

2008-07-02 Thread C.Everson

Is it possible to trigger the jQuery tooltip (and also jQmodal) from an
area on an image map?

Any examples around?

Thanks!

Chuck



[jQuery] Re: I am making a Drag/Drop applications BUILDER (feedback appreciated)

2008-07-02 Thread lorlarz

It now is working completely at some level and the whole kit is
downloadable.

On Jul 1, 1:22 pm, lorlarz [EMAIL PROTECTED] wrote:
 I am making a Drag/Drop applications BUILDER (feedback appreciated):

 http://mynichecomputing.com/GuideInfoandPlanner/UniversalDD.htm

 The user interface is done, but it does no building.  Whole thing may
 be done in
 a couple of days.  BUT,  I would like any input/feedback/ideas or
 suggestions.


  1   2   >