[Proto-Scripty] joomla, IE and prototype/scriptacious fading divs

2008-12-07 Thread fps

For some reason there seems to be a conflict with joomla and the
fading divs functioning. It works when i run the code on a standalone
page, but when inside a joomla page in IE it doesnt fade between divs.
Works in FF though

http://www.trackads.co.uk/10g

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Prototype  script.aculo.us group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~--~~~~--~~--~--~---



[Proto-Scripty] Re: joomla, IE and prototype/scriptacious fading divs

2008-12-07 Thread T.J. Crowder

Hi,

There are errors on the page in IE, have you looked into them?  From
the one I looked at, the most likely culprit is this one from the
unofficial FAQ:
http://proto-scripty.wikidot.com/faq#propnotsupported

HTH,
--
T.J. Crowder
tj / crowder software / com

On Dec 7, 10:21 am, fps [EMAIL PROTECTED] wrote:
 For some reason there seems to be a conflict with joomla and the
 fading divs functioning. It works when i run the code on a standalone
 page, but when inside a joomla page in IE it doesnt fade between divs.
 Works in FF though

 http://www.trackads.co.uk/10g
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Prototype  script.aculo.us group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~--~~~~--~~--~--~---



[Proto-Scripty] Re: slide effect problem

2008-12-07 Thread Walter Lee Davis

If you're going to use Prototype, you owe it to yourself to read the  
documentation. It's well written, nicely organized, and will pay off  
the hour or so it takes to read through from beginning to end with a  
long career of working smarter.

http://prototypejs.org/api

$$ is a critical part of Prototype. You give it a CSS selector, it  
returns an array of extended elements that are ready to use with all  
the other tricks in the Prototype arsenal. Including invoke()

Read up. It's good for you!

Walter

On Dec 7, 2008, at 5:43 AM, shafir wrote:


 isnt there any other way to do that??
 all the time i get errors
 these $$ what they are for?
 what is .invoke atands for?

 maby i can do something inside the code of the slide function to
 make it more google frindly?

 any ideas???
 help please


 On 4 דצמבר, 14:35, Walter Lee Davis [EMAIL PROTECTED] wrote:
 Then there is something else going on in your page that you aren't
 accounting for. The basic premise works, and very well.

 http://jsbin.com/ivipa

 Walter

 On Dec 4, 2008, at 6:34 AM, shafir wrote:





 yes i saw it
 but as i said...doesnt work :(-הסתר טקסט מצוטט-

 -הראה טקסט מצוטט-
 


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Prototype  script.aculo.us group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~--~~~~--~~--~--~---



[Proto-Scripty] why default position of slider not working?

2008-12-07 Thread geoffcox

Hello,

http://www.micro-active.com/aspabar/index-diagram.htm

The slider handle should be in the middle and is with the latest
versions of IE and Firefox.

With the latest version of Opera (9.62) it is on the left hand end.

Any ideas why?!

Cheers,

Geoff
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Prototype  script.aculo.us group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~--~~~~--~~--~--~---



[Proto-Scripty] Re: Extracting the name from a JSON object

2008-12-07 Thread George

Hi T.J.

I'm very grateful for this straight forward and easy to follow
explanation - it's certainly broadened my whole understanding of
JavaScript arrays and object literals - and helped me write a concise
solution to the JavaScript problem I was facing.

All the best

George


On Dec 5, 1:37 pm, T.J. Crowder [EMAIL PROTECTED] wrote:
 Hi George,

 (It's a JavaScript rather than Prototype/script.aculo.us question,
 yes.)

 This object literal / JSON data:

 [{bookingref:'A6D98FGR', canceled:0}]

 ...defines an array with a single element, which is an object instance
 with two properties:  bookingref (value 'A6D98FGR') and canceled
 (value 0).

 You can get the values just by referring to the properties of the
 object, so:

 var x = RS[0].bookingref;
 alert(x); // Alerts 'A6D98FGR'

 JavaScript allows you to use property names both literally with dot
 notation (as above), and _also_ via string names using bracket
 notation; we could write the above like this instead:

 var x = RS[0]['bookingref'];
 alert(x); // Alerts 'A6D98FGR'

 Note the quotes, the square brackets, and the absense of the dot.

 If you don't know the names of the properties in advance, you can use
 the for..in loop to iterate over the names of the object's properties:

 var name;
 for (name in RS[0]) {
     alert(name + '=' + RS[0][name]);

 }

 In the loop, the variable 'name' is set on each iteration to the name
 of a property on the object, as a string.  This is powerful when
 combined with bracket notation.  On the object defined in your JSON
 above, that will show bookingref=A6D98FGR and canceled=0; the
 order is not defined and almost certainly will vary from
 implementation to implementation.

 Note that for..in is for iterating over the properties of an object,
 *not* the elements of an array.  Many JavaScript programmers think
 it's for the latter, and they get into trouble as a result because
 Prototype adds some properties to arrays that they're not expecting to
 see.  
 Details:http://proto-scripty.wikidot.com/prototype:tip-looping-through-arrays

 But again, it's totally fine for looping through the properties on an
 object, like your RS[0].

 HTH,
 --
 T.J. Crowder
 tj / crowder software / com

 On Dec 5, 12:18 pm, George [EMAIL PROTECTED] wrote:

  Hi Folks,

  This may be more of a pure JavaScript question than Prototype, but
  here goes:

  If I have a JSON array called RS for example containing this:
    [{bookingref:'A6D98FGR', canceled:0}]
  is there a way for me to programatically get the names and values?

  I'd like to be able to do something like
   RS[0].[0].name ((would be 'bookingref'))
   RS[0].[0].value ((would be 'A6D98FGR'))

  I hope that makes sense.

  Many thanks

  George
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Prototype  script.aculo.us group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~--~~~~--~~--~--~---



[Proto-Scripty] Re: Extracting the name from a JSON object

2008-12-07 Thread George

Hi Gabriel - many thanks for this tip!

All the best

George

On Dec 5, 10:04 pm, Gabriel Gilini [EMAIL PROTECTED] wrote:
 I forgot to say that apparently Safari = 2.0 and IE5.2 on mac doesn't
 implement the hasOwnProperty method.

 Gabriel Gilini

 www.usosim.com.br
 [EMAIL PROTECTED]
 [EMAIL PROTECTED]

 On Fri, Dec 5, 2008 at 8:01 PM, Gabriel Gilini [EMAIL PROTECTED]wrote:

  If you want to iterate through an array with the constructor object's
  prototype extended use Object.prototype.hasOwnProperty().

  var arr = [0,1,2,'foo','bar'];

  for(var i in arr){
     if(arr.hasOwnProperty){
        if(arr.hasOwnProperty(i))
           alert(arr[i]);
     }
  }

  Gabriel Gilini

 www.usosim.com.br
  [EMAIL PROTECTED]
  [EMAIL PROTECTED]

  On Fri, Dec 5, 2008 at 11:37 AM, T.J. Crowder [EMAIL PROTECTED]wrote:

  Hi George,

  (It's a JavaScript rather than Prototype/script.aculo.us question,
  yes.)

  This object literal / JSON data:

  [{bookingref:'A6D98FGR', canceled:0}]

  ...defines an array with a single element, which is an object instance
  with two properties:  bookingref (value 'A6D98FGR') and canceled
  (value 0).

  You can get the values just by referring to the properties of the
  object, so:

  var x = RS[0].bookingref;
  alert(x); // Alerts 'A6D98FGR'

  JavaScript allows you to use property names both literally with dot
  notation (as above), and _also_ via string names using bracket
  notation; we could write the above like this instead:

  var x = RS[0]['bookingref'];
  alert(x); // Alerts 'A6D98FGR'

  Note the quotes, the square brackets, and the absense of the dot.

  If you don't know the names of the properties in advance, you can use
  the for..in loop to iterate over the names of the object's properties:

  var name;
  for (name in RS[0]) {
     alert(name + '=' + RS[0][name]);
  }

  In the loop, the variable 'name' is set on each iteration to the name
  of a property on the object, as a string.  This is powerful when
  combined with bracket notation.  On the object defined in your JSON
  above, that will show bookingref=A6D98FGR and canceled=0; the
  order is not defined and almost certainly will vary from
  implementation to implementation.

  Note that for..in is for iterating over the properties of an object,
  *not* the elements of an array.  Many JavaScript programmers think
  it's for the latter, and they get into trouble as a result because
  Prototype adds some properties to arrays that they're not expecting to
  see.  Details:
 http://proto-scripty.wikidot.com/prototype:tip-looping-through-arrays

  But again, it's totally fine for looping through the properties on an
  object, like your RS[0].

  HTH,
  --
  T.J. Crowder
  tj / crowder software / com

  On Dec 5, 12:18 pm, George [EMAIL PROTECTED] wrote:
   Hi Folks,

   This may be more of a pure JavaScript question than Prototype, but
   here goes:

   If I have a JSON array called RS for example containing this:
     [{bookingref:'A6D98FGR', canceled:0}]
   is there a way for me to programatically get the names and values?

   I'd like to be able to do something like
    RS[0].[0].name ((would be 'bookingref'))
    RS[0].[0].value ((would be 'A6D98FGR'))

   I hope that makes sense.

   Many thanks

   George
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Prototype  script.aculo.us group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~--~~~~--~~--~--~---



[Proto-Scripty] autocomplete variant

2008-12-07 Thread macsig

Hello guys,
I'm trying to implement a variant of the classic autocomplete but I
can't make it works.
Basically what I want is to show for each element that matches with
the written text the element name and a checkbox (having the element
id as a value).
For instance, if my table contains:

ID  | NAME
1   | Tom
2   | Timmy
3   | John
4   | Nick
5   | Theodora

When I digit 'T' on my textfield the div called friends should be
populated with

[] Tom
[] Timmy
[] Theodora



Can someone help me out with this? Any help is welcome.

thanks and have a nice day!


Sig



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Prototype  script.aculo.us group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~--~~~~--~~--~--~---