[jQuery] Re: Jquery 1.2.3 does not return a type for radio controls?

2009-01-14 Thread Scott Sharkey


Karl Swedberg wrote:
hmm. that doesn't sound right to me. I just put up a test page using 
jQuery 1.2.3, and it identified radio controls just fine:


http://test.learningjquery.com/123.html

Can we see the HTML? Maybe something else is going on.




Text


This is checkbox 1

This is checkbox 2

Second Text



  

  NY
  OH
  PA

  





Same problem with the textarea, by the way.

Here's the javascript...  (note, this is from a genshi template - 
${job.description} is a url string that encodes the names of the 
controls and their values, like so:


jt_textfield=this%20is%20text&jt_checkbox1=on&jt_dist_r_lo=OH&jt_textarea=this%20is%20a%20textarea 




var jt_values = "${job.description}";
var els = jt_values.split('&');
$.each(els, function() {
var items = this.split("=");
var item = "#" + items[0];
var item_val = decodeURIComponent(items[1]);

switch ( $(item).attr('type') ) {
case 'radio': alert(item + " is radio");
break;
case 'checkbox': $(item).attr("checked","checked");
break;
case 'text': $(item).val(item_val);
break;
case 'textarea': $(item).val(item_val);
alert(item + " is textarea = " + item_val);
break;
default:
alert(item+'unknown type:'+$(item).attr('type'));
}

I'm getting undefined in the alert for unknown type on both jt_dist_r_lo
and jt_textarea


[jQuery] Jquery 1.2.3 does not return a type for radio controls?

2009-01-13 Thread Scott Sharkey


Hi All,

I'm stuck with Jquery 1.2.3 in a trac-based application.  I'm trying to 
get the type of a form control, to determine what mechanism I should use 
to set it's value (ie, text controls use .val(), checkboxes get 
.attr("checked", "checked") etc.).  When I fetch my list of controls, 
and loop through them with each, printing the value of .attr('type') on 
each... the text, checkbox, and textarea types work fine, but radio 
controls come up undefined. Is this a jquery bug?  Does anyone know 
if/when it was fixed?  Maybe I can port that patch back to 1.2.3 to 
solve my problem.


Any other suggestions appreciated.

-Scott


[jQuery] OpenLaszlo/Flex vs jQuery?

2007-09-28 Thread Scott Sharkey


Hi All,

I'm starting to hear a lot of buzz about OpenLaszlo and Flex, and after 
looking at it, I'm wondering what they do that can't be done in jQuery? 
 Seems to me that most of it is just "widgits for idiots", if you know
what I mean.  I don't tend to like my sites being dependent on 
proprietary bits (FLASH), so I would favor OpenLaszlo, but still,

are there advantages that aren't obvious?

Just wondering what you guys thought, and whether we ought to be 
positioning jQuery (and plugins) as an alternative?


-Scott


[jQuery] Scrolling Text (Headlines) and/or Marquee in Jquery?

2007-06-26 Thread Scott Sharkey


Hi All,

I'm looking for a decent scrolling (vertical, multiline) headline 
plugin, and a horizontal marquee scroller, both as jquery plugins.


I've been playing with jCarousel, but it seems to be graphics only, and 
just plain does not work for me, plus the doc's seem wrong.


Any suggestions welcomed!

-Scott