[jQuery] Re: Uploader 0.9 beta

2008-02-11 Thread Gilles (Webunity)

http://docs.jquery.com/UI/Uploader

On 11 feb, 14:35, Cloudream [EMAIL PROTECTED] wrote:
 Nice work.

 Is there any documents? I think i can write an asp (server) demo for
 other developers.

 On Feb 11, 3:37 pm, Gilles (Webunity) [EMAIL PROTECTED] wrote:

  Well it is almost finished, my Flash-based file uploader for jQuery.
  The docs are finished, and the widget itself also. Originally intended
  to be a part of UI, but since it has no real connection to UI
  (dependencies and so on) i have decided to release it as a standalone
  plugin.

  Most of you have seen the demo allready but here it is 
  again.http://uploader.webunity.nl/

  Originally based upon swfupload, but based on a really old version of
  swfupload. The version i based the uploader on had:
  - no callbacks for dialog open/dialog hide
  - no multiple file selection masks
  - no filesize limit pre-upload

  I've build all these things into my version, and now they released a
  new version which also has that... (hmmm)
  Anyway, since i based my version on theirs it is only fair that they
  also gather ideas from other sources.

  Let me know if you run into any bugs and i'll try to add the code to
  SVN later this week.


[jQuery] Re: [validate] Adding custom behaviours following validation

2008-02-11 Thread Jörn Zaefferer


kapowaz schrieb:

I'm looking to modify the markup surrounding my form elements once
validation has taken place so as to indicate success/failure with a
particular input element's contents, and I'm wondering if the Validate
plugin can do this without any modification? To give an example,
imagine I have the following markup:

dl
dtlabel for=usernameUsername/label/dt
ddinput name=username //dd
dtlabel for=passwordPassword/label/dt
ddinput type=password name=password //dd
dtlabel for=confirmpasswordConfirm password/label/dt
ddinput type=password name=confirmpassword //dd
/dl

Adding validation rules to this using the plugin is very easy, and
since by default it will add a class of error to any elements with
invalid values, I can add a highlight rule for inputs easily enough.
However, what I'd like to do is set a class of 'pass' or 'fail' to the
containing DD element, so that I can indicate which fields have been
successfully filled in.

If I was doing this in a nice jQuery-esque fashion, I'd hook in some
functionality to addClass/removeClass using a custom event, but as far
as I can see this plugin doesn't provide any custom events to handle
this (unless I'm missing something blindingly obvious?). Can anybody
suggest a route to achieving what I've got in mind that doesn't
involve hacking the plugin itself?
  
The highlight and unhighlight options should do the trick. Something 
like this:


$(...).validate({
 highlight: function(element, errorClass) {
   $(element).parent().andSelf().addClass(errorClass);
 }, ...
});

Jörn



[jQuery] Re: Appending content in order

2008-02-11 Thread Karl Swedberg


Hi Feijó,

you could try this ...

$('div.main  div.sub:eq(2)').after('div class=sub/div');

That should insert your new div after the 3rd one.

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



On Feb 11, 2008, at 2:25 PM, Feijó wrote:


consider that html:

div class=main
div class=sub/div
div class=sub/div
div class=sub/div
div class=sub/div
div class=sub/div
/div


I need to append a new div class=sub/div as the 2nd, 3rd,  
middle, etc.

Append() add after the last one.

How can I do that? Its possible?



Thanks
Feijó





[jQuery] Re: jQuery won't recognise attribute names containing [square brackets]

2008-02-11 Thread Aaron Heimlich
On Feb 11, 2008 10:07 AM, Dave Stewart [EMAIL PROTECTED]
wrote:


 Hi Aaron,
 Good styles there with the name attribute stuff. Not so good if you
 want to grab other entities such as selects


This should select any form element (input,select,textarea,button) whose
name attribute is foo[bar][baz]:

$(:input[name='foo[bar][baz]'])

You're gonna wanna restrict it, though, so it doesn't search the *entire*
page. Something like:

$(#myFormsId :input[name='foo[bar][baz]'])

or

$(:input[name='foo[bar][baz]'], domElementForMyForm)

You can read more about jQuery selectors at http://docs.jquery.com/Selectors

-- 
Aaron Heimlich
Web Developer
[EMAIL PROTECTED]
http://aheimlich.freepgs.com


[jQuery] Re: Appending content in order

2008-02-11 Thread Feijó





Indeed, a good example would be the best way to explain.


  fieldset id="thefilter" class=" collapsible"legendCriteria/legend

div id=qz-criteria

	div class=qz-tablefielddiv class="form-item"
	 div id=h_tableTable/div div id=h_fieldField/div div id=h_valueValue/div
  
  	/div
/div
div class="qz-tablefield"
	div class="form-item"
	 select name="table[]" class="form-select edit-table" id="edit-table[]" option value="0"Select a table/optionoption value="1"incidents/optionoption value="3"qualify/optionoption value="2"technical/optionoption value="9"criticalities/optionoption value="5"groups/optionoption value="7"origins/optionoption value="6"positions/optionoption value="8"priorities/optionoption value="4"reasons/optionoption value="10"status/option/select
	/div
	
	div class="form-item"
	 select name="field[]" class="form-select edit-field" id="edit-field[]" option value="0"Select a table/option/select
	/div

	div class="form-item"
	 select name="value[]" class="form-select edit-value" id="edit-value[]" option value="0"Select a field/option/select
	/div

	div class=form-itemimg src="/drupal/themes/test/pic/ico_proximo.png" id="new-criteria" border="0" align="absmiddle"New criteria
	/div
/div

/fieldset
  
  

the brighter blue, is the cloned in question.  How to control the order it will be inserted/appended?


the relevant jQuery is:


 $("#thefilter img#new-criteria").click(function(){
  $last = $('#thefilter .qz-tablefield:eq(1)') // clone the first
qz-tablefield that contain what we want, the eq(0) is the header
   .clone(true);
  
  $last
   .appendTo($('#thefilter')) // append to parent, #thefilter,
but need to insert after the one we click, not the bottom
   .hide() 
   .fadeIn('medium') // just some flowers
   .find('.clean-criteria')
   .trigger('click'); // clear all inputs to be filled by user
 });
  

I think thats enough. I dont want to avalanche with irrelevant code.

TIA!!


Feij



Karl Swedberg escreveu:
Hi again. :)
  
  
  This should help you understand what :eq() does:
  
  
  
  http://docs.jquery.com/Selectors/eq#index
  
  
  "Matches
a single element by its [zero-based] index."
  
  
  I'm sure we can achieve what you're trying to do, but it's hard
for me to help without being able to at least see the HTML. As it is, I
don't know what.qz-tablefield is, for example. Can you point me to a
web page or even just provide an HTML snippet?
  
  
  Thanks,
  
  
  --Karl
  _
  Karl Swedberg
  www.englishrules.com
  www.learningjquery.com
  
  
  
   
  
  
  On Feb 11, 2008, at 3:07 PM, Feij wrote:
  
  
 Hi Karl,


Its a bit more confunsing, I simplified too much

In my div, I change a value from a select

that triggers a code that clone the select parent (the div)

If I do that a few times, every new div goes to the bottom

I do not know what eq() is!! there is a function that return that?

Here is a sample of current code:


 $("#thefilter img#new-criteria").click(function(){
  $last = $('#thefilter .qz-tablefield:eq(1)')
   .clone(true);

  $last
   .appendTo($('#qz-criteria'))
   .hide()
   .fadeIn('medium')
   .find('.clean-criteria')
   .trigger('click');
 });

my select triggers that event. How to adjust with your
suggestion?
Feij



Karl Swedberg escreveu:

Hi Feij, 
  
you could try this ... 
  
$('div.main  div.sub:eq(2)').after('div
class="sub"/div'); 
  
That should insert your new div after the 3rd one. 
  
--Karl 
_ 
Karl Swedberg 
  www.englishrules.com 
  www.learningjquery.com 
  
  
  
On Feb 11, 2008, at 2:25 PM, Feij wrote: 
  
  consider that html: 

div class=main 
 div class=sub/div 
 div class=sub/div 
 div class=sub/div 
 div class=sub/div 
 div class=sub/div 
/div 


I need to append a new div class=sub/div as the 2nd,
3rd, middle, etc. 
Append() add after the last one. 

How can I do that? Its possible? 



Thanks 
Feij 

  


  
  
  





[jQuery] Copying menu item from one menu to another

2008-02-11 Thread [EMAIL PROTECTED]

Hi,

Let's say I have a SELECT menu with id = fromMenu and if a user
clicks the Add button, I want the selected menu item from the
fromMenu to be appended as the last item in antoher menu with id =
toMenu.

I'm sure this is simple.  How can it be done?

Thanks, - Dave


[jQuery] Re: Disappearing events?

2008-02-11 Thread Nate

Thanks!
I thought events would stay unless the actual element the event is
attached to is changed, not the necessarily the contents of the
element.

I guess I'll be rewriting that portion...

Thanks again...
-Nate

On Feb 11, 3:11 pm, Kyle Browning [EMAIL PROTECTED] wrote:
 Use either the live query plugin OR, reapply the events.

 The issue is, the events are added once the dom is ready. after that, the
 functions never get called again. So if you change out elements, your events
 are gone. Live Query solves this.

 Kyle

 On Feb 11, 2008 11:13 AM, Nate [EMAIL PROTECTED] wrote:



  I created three table elements using jquery, and each td cell in the
  tables has hover and click events attached to it.

  The basic table generation is cached in an array and the only changes
  that happen to the initial content occur by updating individual td
  contents using $(this).text(val). All of the events fire correctly the
  first time a table is rendered, but when the table is updated, only
  using .text(..), the events disappear. I've tried tracing what is
  happening, but eventually get lost, and was hoping someone would be
  able to explain why the events are disappearing.

  Here are the affected parts of the code for reference:

  var drawInitial = function(wks) {
 var cal = [];
 for(var i = 4; i = 6; i++) {
 cal[i] = $('table cellpadding=0 cellspacing=0
  border=0/table');
 for(var j = 0; j  i; j++) {
 drawWeek().appendTo(cal[i]);
 }
 }

 drawInitial = function(wks) {
 return cal[wks];
 }
 return drawInitial(wks);
  }

  function drawWeek() {
 var wk = $(tr/tr);
 for(var j = 0; j  7; j++) {
 drawDay(j).appendTo(wk);
 }
 return wk;
  }

  function drawDay(dayOfWeek) {
 var css = ;

 (dayOfWeek == 0 || dayOfWeek == 6) ? css = calendarWeekend : css
  = calendarWeekday;
 var day = $('td class=calendarBox '+css+'/td');
 day.hover(
 function() { if($(this).text()) {$
  (this).addClass(calendarHover);} },
 function() { if($(this).text()) {$
  (this).removeClass(calendarHover);} }
 );
 day.click( function() {
 if($(this).text()) {
 setSelected($(this).text());
 } else {
 delayHide();
 }
 });
 return day;
  }

  function drawMonth() {
 var year = widgetDate.getFullYear();
 var month = widgetDate.getMonth();

 var firstDay = new Date(year, month, 1).getDay();
 var daysInMonth = Date.getDaysInMonth(year, month);
 var weeksInMonth = Math.ceil((firstDay + daysInMonth) / 7);
 var cal = drawInitial(weeksInMonth);
 var i = 0, //week
 j = 1; //day of month

 cal.find(tr:not(.calendarWeek)).each( function() {
 $(this).children(td).each( function() {
 if(j  firstDay  j = firstDay + daysInMonth) {
 $(this).text(j - firstDay);
 } else {
 $(this).text();
 }
 j++;
 });
 i++;
 });

 $(#+widgetId).html(cal);
  }


[jQuery] Re: Dynamic Variables

2008-02-11 Thread Shawn


This is untried, but something similar should work out for you:

function doIt(target) {
  var myid = $(target).attr(id).toString().split(_)[1];
  var myelement = table# + myid;
  if ( $(target).attr(checked) ) {
$(myelement).show();
  }
  else {
$(myelement).hide();
  }
}

This makes the assumption that the table ID you want is the same block 
of text after the underscore in the checkbox ID.


HTH

Shawn

rsmolkin wrote:

Hi,

I hope someone can help me out a bit.

I am finding myself doing a lot of code (as I'll paste below).  It's
basically the same block of code with different variables.

What I am trying to do is consolidate all that code into a funciton
where I can declare all the checkboxes I need to create an Click
function for, and then loop through them and generate the click
handler as well as other functions for all of them.

Here is the code snippet:

$('#ckbx_wgmpo').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_wgmpo').show('medium');
}
else{

$('table#tbl_wgmpo').hide('medium');
}
}
);
$('#ckbx_wgmse').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_wgmse').show('medium');
}
else{

$('table#tbl_wgmse').hide('medium');
}
}
);
$('#ckbx_wgmoe').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_wgmoe').show('medium');
}
else{

$('table#tbl_wgmoe').hide('medium');
}
}
);
$('#ckbx_tyd').click(
function() {
if ($(this).attr(checked) == true){

$('div#tyd_info').show('medium');
}
else{

$('div#tyd_info').hide('medium');
}

}
);
$('#ckbx_tydpo').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_tydpo').show('medium');
}
else{

$('table#tbl_tydpo').hide('medium');
}
}
);
$('#ckbx_tydgc').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_tydgc').show('medium');
}
else{

$('table#tbl_tydgc').hide('medium');
}
}
);
$('#ckbx_tydoe').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_tydoe').show('medium');
}
else{

$('table#tbl_tydoe').hide('medium');
}
}
);


[jQuery] Re: Disappearing events?

2008-02-11 Thread Kyle Browning
Use either the live query plugin OR, reapply the events.

The issue is, the events are added once the dom is ready. after that, the
functions never get called again. So if you change out elements, your events
are gone. Live Query solves this.

Kyle

On Feb 11, 2008 11:13 AM, Nate [EMAIL PROTECTED] wrote:


 I created three table elements using jquery, and each td cell in the
 tables has hover and click events attached to it.

 The basic table generation is cached in an array and the only changes
 that happen to the initial content occur by updating individual td
 contents using $(this).text(val). All of the events fire correctly the
 first time a table is rendered, but when the table is updated, only
 using .text(..), the events disappear. I've tried tracing what is
 happening, but eventually get lost, and was hoping someone would be
 able to explain why the events are disappearing.

 Here are the affected parts of the code for reference:

 var drawInitial = function(wks) {
var cal = [];
for(var i = 4; i = 6; i++) {
cal[i] = $('table cellpadding=0 cellspacing=0
 border=0/table');
for(var j = 0; j  i; j++) {
drawWeek().appendTo(cal[i]);
}
}

drawInitial = function(wks) {
return cal[wks];
}
return drawInitial(wks);
 }

 function drawWeek() {
var wk = $(tr/tr);
for(var j = 0; j  7; j++) {
drawDay(j).appendTo(wk);
}
return wk;
 }

 function drawDay(dayOfWeek) {
var css = ;

(dayOfWeek == 0 || dayOfWeek == 6) ? css = calendarWeekend : css
 = calendarWeekday;
var day = $('td class=calendarBox '+css+'/td');
day.hover(
function() { if($(this).text()) {$
 (this).addClass(calendarHover);} },
function() { if($(this).text()) {$
 (this).removeClass(calendarHover);} }
);
day.click( function() {
if($(this).text()) {
setSelected($(this).text());
} else {
delayHide();
}
});
return day;
 }

 function drawMonth() {
var year = widgetDate.getFullYear();
var month = widgetDate.getMonth();

var firstDay = new Date(year, month, 1).getDay();
var daysInMonth = Date.getDaysInMonth(year, month);
var weeksInMonth = Math.ceil((firstDay + daysInMonth) / 7);
var cal = drawInitial(weeksInMonth);
var i = 0, //week
j = 1; //day of month

cal.find(tr:not(.calendarWeek)).each( function() {
$(this).children(td).each( function() {
if(j  firstDay  j = firstDay + daysInMonth) {
$(this).text(j - firstDay);
} else {
$(this).text();
}
j++;
});
i++;
});

$(#+widgetId).html(cal);
 }



[jQuery] Dynamic Variables

2008-02-11 Thread rsmolkin

Hi,

I hope someone can help me out a bit.

I am finding myself doing a lot of code (as I'll paste below).  It's
basically the same block of code with different variables.

What I am trying to do is consolidate all that code into a funciton
where I can declare all the checkboxes I need to create an Click
function for, and then loop through them and generate the click
handler as well as other functions for all of them.

Here is the code snippet:

$('#ckbx_wgmpo').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_wgmpo').show('medium');
}
else{

$('table#tbl_wgmpo').hide('medium');
}
}
);
$('#ckbx_wgmse').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_wgmse').show('medium');
}
else{

$('table#tbl_wgmse').hide('medium');
}
}
);
$('#ckbx_wgmoe').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_wgmoe').show('medium');
}
else{

$('table#tbl_wgmoe').hide('medium');
}
}
);
$('#ckbx_tyd').click(
function() {
if ($(this).attr(checked) == true){

$('div#tyd_info').show('medium');
}
else{

$('div#tyd_info').hide('medium');
}

}
);
$('#ckbx_tydpo').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_tydpo').show('medium');
}
else{

$('table#tbl_tydpo').hide('medium');
}
}
);
$('#ckbx_tydgc').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_tydgc').show('medium');
}
else{

$('table#tbl_tydgc').hide('medium');
}
}
);
$('#ckbx_tydoe').click(
function() {
if ($(this).attr(checked) == true){

$('table#tbl_tydoe').show('medium');
}
else{

$('table#tbl_tydoe').hide('medium');
}
}
);


[jQuery] mouseover and IE 6

2008-02-11 Thread Eridius


my mouseover event is not taken effect in IE 6
-- 
View this message in context: 
http://www.nabble.com/mouseover-and-IE-6-tp15421402s27240p15421402.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Re: jquploader 2 alpha 1 - rich file upload dialog plugin - please test and help

2008-02-11 Thread [EMAIL PROTECTED]

Hi all, this is an awesome jquery extension that I am currently using
as part of a much larger project (with a lot of rewriting the
functions after the upload is successful - e.g. image resizing,
thumbnail creation etc). The author is to commended on the layout of
his code - very simple to follow. The only gripe I have is with the
iflash plugin required to make it work - since it breaks activeX on a
mac, which means that the flash upload componentry wont always load on
a mac system. I would be very keen to see the final version of
jqUploader2 or at least a version that uses object and embed instead
of the iflash plugin.
Once again - congrats to the author - good job mate.

On Feb 1, 3:46 am, Alexandre Plennevaux [EMAIL PROTECTED]
wrote:
 For your Information: flash does not allow upload bigger than 100 Megs so 
 this might explain that. I still have to implement filesize checking to make 
 sure the user knows beforehand...

 -- Original Message --
 To: jQuery (English) (jquery-en@googlegroups.com)
 From: tlob ([EMAIL PROTECTED])
 Subject: [jQuery] Re:jquploader2 alpha 1 - rich file upload dialog plugin - 
 please  test and help
 Date: 31/1/2008 14:45:11

 looks good on os x 10.5.1
 safari 3
 FF 2

 it behaves i little quirki with very big files. 600MB
 looks like the browser crashed

 would be nice to have a twirling cursor on the page to see, if its
 uploading. the progressbar is nice, but with big files it would not
 update for a long time.

 would be nice to have the features 
 likehttp://www.fyneworks.com/jquery/multiple-file-upload/

 thx tl

 On Jan 31, 12:36 pm, Alexandre Plennevaux [EMAIL PROTECTED]
 wrote:
  Hello friends,

  I am working on the new version ofjqUploader, a plugin that allows to
  replace the file inputs in a form  for a more user-friendly file upload
  dialog via the use of an invisible flash object.
  The new version allows for full customization via CSS and html, instead of
  having to tweak the flash file.

  I've pretty much finished a working prototype (still need to implement all
  the customizable options). It works well on WinXP FF2.

  WARNING: THIS IS ALPHA STUFF NOT TO BE USED IN PRODUCTION YET 

  demo is here:http://www.pixeline.be/experiments/jqUploader/v2/

  I have 2 requests:
  query.jquploader2.jshttp://www.pixeline.be/experiments/jqUploader/v2/jquery.jquploader2.js

  1/ can you test on your side and (especially mac users) let me know if the
  test works or not for you.
  2/ for plugin experts: if you look at the code i use functions that i would
  like that the user be able to modify, but i don't know exactly how to do
  that. For the moment, the js functions called by flash are sitting outside
  of the plugin loop.
  What would be the good way to allow users to modify what these function do?
  Basically their task is to update the html according to the flash events.
  The code is here:

  Thank you for your time,

  Alexandre

  --
  Alexandre Plennevaux
  LAb[au]

 http://www.lab-au.com

 Alexandre Plennevaux - LAb[au] asbl.vzw / MediaRuimte
   Lakensestraat/Rue de Laeken 104
   B-1000 Brussel-Bruxelles-Brussels
   Belgie-Belgique-Belgium
 Tel:+32(0)2.219.65.55
   Fax:+32(0)2.426.69.86
   Mobile:+32(0)476.23.21.42
  http://www.lab-au.com
  http://www.mediaruimte.be
 __
 The information in this e-mail is intended only for the addressee named above.
   If you are not that addressee, please note that any disclosure, 
 distribution or copying of this e-mail is prohibited.
   Because e-mail can be electronically altered, the integrity of this 
 communication cannot be guaranteed.
 __


[jQuery] how to set the value of an input after selecting an option in a list

2008-02-11 Thread [EMAIL PROTECTED]

Hello,
after selecting a value in my select field and clicking on a button, I
call a function (please see the code below)
But $('#newDoc_name') is an input, I would like to set his value with
the result of 'index.php/get/s_document_loadName/
Can you help me?
Thank you


$('#newDoc_selectok').click(function(){
if($('#newDoc_select').val() == 0)
alert(Please select a document in the
list);
else
{
$('#newDoc_docinfo').fadeIn('Slow');
$('#newDoc_name').load('index.php/get/
s_document_loadName/'+$('#newDoc_select').val(),{}, function(){})

}
})


[jQuery] Re: Problem with AJAXQueue: dequeue not a function

2008-02-11 Thread sozzi

I guess I must be using the plugin wrong. I am trying to make sure
that the second AJAX request does not start until the Session.ID
variable (from the first call) was set.
The second call never gets properly executed (below) because
Session.ID is still undefined
So I guess I'm doing something wrong still, but what exactly?


script type=text/javascript
$(document).ready(function(){
var Session={};

function setSessionID(data){
Session.ID=data.Login.Session.id;
$(#msg).append(liSuccessful 
Request!/li+Session.ID);
};

function showImages(data){
var html = ;
$.each(data.Images, 
function(entryIndex, entry){
html += 'lia 
href='+entry.LargeURL+' title='+entry.Caption
+'img src='+entry.ThumbURL+'//li/a ';  //entry['ThumbURL']
seems to work too
});
html = 'ul 
class=imgURL'+html+'\/ul';
$('#msg').append(html);
}

$.ajax({
mode:   queue,
url: 
http://api.smugmug.com/services/api/json/1.2.1/?
method=smugmug.login.anonymouslyAPIKey=SmrIci1yMsueIhYvSoQPu0DzQ2isLxmeJSONCallback=?,
dataType:   jsonp,
success: function(data){
setSessionID(data);
}
});

$(#msg).append(liWait for Queue to finish: 
/
li+Session.ID);

$.ajax({
mode:   queue,
url: 
http://api.smugmug.com/services/api/json/1.2.1/?
method=smugmug.images.getHeavy=1APIKey=SmrIci1yMsueIhYvSoQPu0DzQ2isLxmeSessionID=+Session.ID
+AlbumID=3133697JSONCallback=?,
dataType:   jsonp,
success: function(data){
showImages(data);
}
});

$(#msg).append(liStill waiting for Queue 
to finish: /
li+Session.ID);

});
/script


[jQuery] Re: Problem with AJAXQueue: dequeue not a function

2008-02-11 Thread sozzi

Interesting.

Seems to be just about the same code But the documentation is
really out of date (more like wrong..).
From what I can tell the plugin now extends the $.ajax call with the
additional setting of mode, i.e. mode: queue .

The documentations (in the js) seems to show a queued ajax call with
$.ajaxQueue, same as in the initial code.

I'll see if I understood this right and can get it to work.


On Feb 11, 10:09 am, Jörn Zaefferer [EMAIL PROTECTED] wrote:
 sozzi schrieb:

  Hi there,

  I'm trying to write a plugin for the SmugMug JSONP API. One quirk is
  that they require a SessionID. So prior to asking for any data the
  initial JSONP call for the SessionID has to be returned.

  I think the AJAXQueue plugin (http://dev.jquery.com/~john/plugins/
  ajaxqueue/) would be a perfect fit. Unfortunately the plugin throws
  and error:
  FireBug Console output:
  jQuery.dequeue is not a function
 complete()ajaxqueue (line 12)
 complete()jquery.js (line 2790)
 onreadystatechange(5)jquery.js (line 2740)
  [Break on this error] jQuery.dequeue( jQuery.ajaxQueue, ajax );

  I'm not quite certain what would cause this and if it is a problem for
  my case at all.

  Any help is appreciated.

 Give this one a 
 try:http://dev.jquery.com/view/trunk/plugins/ajaxQueue/jquery.ajaxQueue.js

 Jörn


[jQuery] Re: How do I attach a toggle to a checkbox. I want a table row to fade out/in, when a checkbox is toggled

2008-02-11 Thread Polskaya

Hi, this works in my browser:

html
script type=text/javascript src=jquery.js/script
script
  $(document).ready(function(){
  $('.deleteRow').click(function() {

 if($(this).attr(checked)) {
 id=this.id;
 splitid=id.split('|');
 trid=splitid[1];
$(tr#+trid).animate({
opacity: 0.2,
  }, 500 );
 } else {
$(tr).animate({
opacity: 1,
  }, 500 );
 }
});
});

  /script

Html...

table
tr
thHeading/th
thSecond Heading/th
thThird Heading/th
/tr
tr id=1
tdtest row 1/td
tdinput name=input1 type=text //td
tdselect name=select1 option value =firstfirst/option/
select/td
td class=rightinput id=go|1 name=deleteRow type=checkbox
class=deleteRow value=deleteRow //td
/tr
tr id=2
tdtest row 2/td
tdinput name=input2 type=text //td
tdselect name=select2 option value =firstfirst/option/
select/td
td class=rightinput id=go|2 name=deleteRow type=checkbox
class=deleteRow value=deleteRow //td
/tr
tr  id=3
tdtest row 3/td
tdinput name=input3 type=text //td
tdselect name=select3 option value =firstfirst/option/
select/td
td class=rightinput id=go|3 name=deleteRow type=checkbox
class=deleteRow value=deleteRow //td
/tr
/table

Css...

style type=text/css

table{
width:500px;
border-collapse:collapse;

}

tr th{
font-weight:bold;
text-align:left;

}

tr td.right{
text-align:right;

}

tr{
border-bottom:1px solid #ccc;

}

/style
/html


Since you'r going to have more than one deleterow checkrow, you cannot
give it the same id for every checkbox. So give them a dynamic id,
with a separator fi: 'go|1'
Give the tablerow also a dynamic id, it must be the same number as
appears in your checkbox id.
Then in the script, get the id from the checkbox, split it, take the
number and use it as id for the tablerow to animate.

I hope this might help...

Polskaya





[jQuery] Newbie question about Radio Buttons

2008-02-11 Thread PKJ

Hi,

I am thinking about using JQuery in a site I develop, but I am
struggling to work out how to achieve what I want, so any advice would
be appreciated.

I have a matrix of radio buttons.  I can ensure that only one radio
per row is selected by giving the radio buttons on each row the same
name.

In addition to the one selection per row rule, I want to use JQuery
to ensure that only one radio in each column is selected as well i.e
if a radio button is selected, I want to unselect all the radios in
the same column (as well as all those in the same row).

The complexity is that there will be several of these matrices on each
page.

Any ideas?

Thanks in advance

PKJ






[jQuery] Re: Using jQuery inside an ordinary function notes!

2008-02-11 Thread saidbakr

Hi,

I think that my problem is complicated. I already done what you have
told me due to the following requirement:

I have another function used for doing form validation which I named
it as formVal(). Inside formVal() I called avaChk() in a conditional
if statement i.e.
if (avaChk()){ 

I modified avaChk() by adding after alert('222) and alert('333')
return false and return true respectively. Calling avaChk() leads only
alert('111') and alert('444'). In other word avaChk() did not return
true or false it just return the code outside $.ajax.

You may notice that the code $.ajax is placed inside success handler.
This is making me mad!!!

Best regards,
Said Bakr

On Feb 11, 5:44 am, Karl Rudd [EMAIL PROTECTED] wrote:
 It's a easy misunderstanding to have when you first begin to use AJAX.

 Remember that the first 'A' in AJAX stands for Asynchronous. You ask
 the browser (via jQuery's ajax function) to retrieve a URL and you
 give it a function that it will call with the result when it has
 retrieved it.

 The browser may take 50 milliseconds or 50 seconds to retrieve the
 URL, you can't be sure how long.

 In the mean time the browser (and your JavaScript function) continues
 on its way.

 So you must put all the code for handling the results in the success
 (or error) handler function.

 Does that help?

 Karl Rudd

 On Feb 11, 2008 1:59 PM,saidbakr[EMAIL PROTECTED] wrote:





  Hi,

  I have very little knowledge about javascript. I used it with ordinary
  functions and the code of jquery may make me confused.
  I used it in a javascript function some thing like that:

  script
  function avaChk(lnk,id){
  alert('111')
  ob = document.getElementById('id');
  $.ajax({url: 'chk_user.php',type:'GET', data: id+'='+ el, cache:
  false, dataType: script, success: function(data, textStatus){
  if (data == 0){

                  alert('222');
  }
  else{
  alert('333');
  }
  },
          error: function(x,txt,err){
          $(#waitImg+lnk).remove();
          alert('Could not check...'+\n+'The server may down or busy. Retry
  again after a while.');
          }
  });
  alert('444');
  }

  What I noticed is, when I call the function avaChk(), for me, very
  strange thing is happened. ;) I think the jQuery proffesional will
  know it:

  The alert sequence as I respect is 111, 222 or 333 then 444
  what happened is not like above, it was 111,444, 222 or 333 !!!

  I respected that the jQuery code should be executed before the
  alert(444). In real world this prevent me from using the value of data
  or return it through another function.

  What's wrong in my understanding and how can I overcome this problem?- Hide 
  quoted text -

 - Show quoted text -


[jQuery] Re: Problem with AJAXQueue: dequeue not a function

2008-02-11 Thread Jörn Zaefferer


sozzi schrieb:

Hi there,

I'm trying to write a plugin for the SmugMug JSONP API. One quirk is
that they require a SessionID. So prior to asking for any data the
initial JSONP call for the SessionID has to be returned.

I think the AJAXQueue plugin (http://dev.jquery.com/~john/plugins/
ajaxqueue/) would be a perfect fit. Unfortunately the plugin throws
and error:
FireBug Console output:
jQuery.dequeue is not a function
   complete()ajaxqueue (line 12)
   complete()jquery.js (line 2790)
   onreadystatechange(5)jquery.js (line 2740)
[Break on this error] jQuery.dequeue( jQuery.ajaxQueue, ajax );

I'm not quite certain what would cause this and if it is a problem for
my case at all.

Any help is appreciated.
  
Give this one a try: 
http://dev.jquery.com/view/trunk/plugins/ajaxQueue/jquery.ajaxQueue.js


Jörn



[jQuery] Re: [validate] submit problem [validation]

2008-02-11 Thread Jörn Zaefferer


Josoroma schrieb:

I have a form without a submit button, i was making the submit with
the following code:

div class=buttons
a href=javascript:{} class=positive id=button_confirmAction
style=display: block; title=Register
onClick=confirmAction('confirmAction'); return false; img src=/
hoyque/img/icons/tick.png alt=/Register/a
div


How do i enable the call to validate before to realize the submit with
my href onclick button above?

Thanks in advance.
  

This may do the trick:

$(#button_confirmAction).click(function() {
 $(#UserRegisterForm).submit();
});

That submits the forms when the button is clicked, triggering validation 
like a normal submit button.


Jörn


[jQuery] Re: Treeview question

2008-02-11 Thread Jörn Zaefferer


[EMAIL PROTECTED] schrieb:

Jörn,

Greate plugin.  Very useful indeed.  I have a quick question.  Do you
(or anyone) for that matter know of any problems with IE 6 not
rendering the entire tree?  Let me explain.  I have a large tree 1024
items nested 4 deep.  This page loads in FF fine (takes a while, but
nonetheless fine) but in IE, the top two or three nodes will render
but the rest of the page just shows up as a normal nested bulleted
list.

Any help would be appreciated.  I don't really know if I can post a
code example of this or not.
  

A code example would help a lot.

Jörn


[jQuery] Re: ANNOUNCE: Truncate plugin v.2.3 -- now preserves HTML

2008-02-11 Thread Karl Swedberg


Excellent job, Brian!

Seems we have some overlap, which I'm sure is my fault because your  
plugin was around long before mine was (http://plugins.learningjquery.com/expander/ 
). If only I had known before I got to work on mine... Oh well. It'll  
be fun to poke around the truncate plugin's code to see how similar  
our approaches were.


Cheers,

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



On Feb 11, 2008, at 12:22 PM, Giant Jam Sandwich wrote:



This has been a long time coming, and is a major update for the
plugin. Previously, if you decided to truncate a string, it would
strip all the HTML from that string. Essentially, it worked by slicing
the string in two, and by hiding the second half. The new version uses
a series of regular expressions, and maintains two copies of the
string. I won't go into all the technical details, but I threw some
pretty nasty HTML at it, and it seemed to work well. Empty HTML tags
after the truncate will be removed, but any HTML closing tag after the
truncate associated with an HTML opening tag before the truncate will
remain. So if you truncated mid list item, formatting would still be
maintained for the list.

Give it a go, and let me know if you discover any bugs. Thanks!

http://www.reindel.com/truncate/

Brian Reindel




[jQuery] AutoScroll Plugin without using a mod_key

2008-02-11 Thread [EMAIL PROTECTED]

Him

I've been loooking at the jQuery autoscroll plugin (http://jdsharp.us/
jQuery/plugins/AutoScroll/demo.php) and it works pretty well. I'd like
to know if its possible to modify this plugin to not use the ctrl key
though and rather scroll as i move my mouse off the end of the window
while having the left button held down? is there a mod key for this?

Cheers,
Chris


[jQuery] ANNOUNCE: Truncate plugin v.2.3 -- now preserves HTML

2008-02-11 Thread Giant Jam Sandwich

This has been a long time coming, and is a major update for the
plugin. Previously, if you decided to truncate a string, it would
strip all the HTML from that string. Essentially, it worked by slicing
the string in two, and by hiding the second half. The new version uses
a series of regular expressions, and maintains two copies of the
string. I won't go into all the technical details, but I threw some
pretty nasty HTML at it, and it seemed to work well. Empty HTML tags
after the truncate will be removed, but any HTML closing tag after the
truncate associated with an HTML opening tag before the truncate will
remain. So if you truncated mid list item, formatting would still be
maintained for the list.

Give it a go, and let me know if you discover any bugs. Thanks!

http://www.reindel.com/truncate/

Brian Reindel


[jQuery] Re: ClearType rendering issue in IE

2008-02-11 Thread Bil Corry


Giant Jam Sandwich wrote on 2/11/2008 11:06 AM: 

Thanks Mike -- that fixed it. The brief flicker in IE7 between
ClearType and regular type I suppose is unavoidable. I could use a
slide transition instead, but it wouldn't look as good. Oh well.



This talks a bit about the problem and offers a second workaround:

http://mattberseth.com/blog/2007/12/ie7_cleartype_dximagetransform.html


- Bil



[jQuery] Re: ClearType rendering issue in IE

2008-02-11 Thread Giant Jam Sandwich

Thanks Mike -- that fixed it. The brief flicker in IE7 between
ClearType and regular type I suppose is unavoidable. I could use a
slide transition instead, but it wouldn't look as good. Oh well.


On Feb 11, 9:01 am, Mike Alsup [EMAIL PROTECTED] wrote:
 Brian,

 In IE6 you can usually solve the problem by setting an explicit background
 color on the element in question.  But for IE7 you need to remove the
 opacity filter after the animation completes:

 $('#myDiv').fadeIn(function() {
 if ($.browser.msie)
 this.style.removeAttribute('filter');

 });

 Mike

 On Feb 11, 2008 8:15 AM, Giant Jam Sandwich [EMAIL PROTECTED] wrote:



  I was inserting some text to a (display:none) DIV with .html(), and
  then showing it with .fadeIn(), and I noticed that IE loses
  ClearType rendering. The font I am using is Georgia. I haven't tested
  any other scenarios other than the one I just described, but has
  anyone else experienced this? I'm on Windows XP SP2 Home Edition.

  Thanks.

  Brian


[jQuery] Re: jQuery caching DOM refferences? Performance issues

2008-02-11 Thread Jeffrey Kretz

Personally, I do something like this, say for an event that is called
frequently:

function flyout(e)
{
if (!this.$self) this.$self = $(this);
this.$self.show();
}

JK

-Original Message-
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Michal Popielnicki
Sent: Monday, February 11, 2008 5:41 AM
To: jQuery (English)
Subject: [jQuery] Re: jQuery caching DOM refferences? Performance issues


Hi there, and thanks for the reply.

Actually there is no visible bottleneck yet and I can't really point
it out since the javascript behind the app is massive and it results
in poor performance under Opera (which is very strange, since its the
fastest browser supporting JS) .

However I was wondering about ways that the performance can be
improved ad that was generally where I suggested the solution and
basing on Your opinion it should work.

If there are any other opinions/suggestions I'd be glad to hear them.

Thanks in advance

Best regards!

On 11 Lut, 01:55, J Moore [EMAIL PROTECTED] wrote:
 You can profile javascript with firebug and see total calls for
 different approaches and how long they take.

 That said, $('#id') is fast, since it is basically getElementById() a
 native javascript method. However, if you call $('#id') 100x, you'll
 see that it's faster to cache it in a variable. e.g

 var id = $('#id');
 for (i=0;i100;i++) {
  id.append(pnumber +i+/p);

 }

 what is the bottleneck in your code?

 -j

 On Feb 10, 6:12 pm, Michal Popielnicki [EMAIL PROTECTED]
 wrote:

  Hi there!

  I've been dealing with some performance clean-up of a code of a web-
  app that I wrote and I was wondering if jQuery does caching of the DOM
  references. Lets say I have a function:

  function myFunction(){
  $('#foo').attr(bar);

  }

  I frequently refer to the function, so is it the case that each time I
  launch it, the DOM is scanned for element with foo id? Or maybe this
  reference is somehow cached?

  If its not, then maybe doing something like this would speed up the
  code execution:

  function DomLinker(){
  this.foo = $('#foo').attr(bar);

  function myFunction(){
  domMember.foo.attr(bar);}

  $(document).ready(
  domMember = new DomLinker();

  }

  Please keep in mind that we talk about case of many executions of
  myFunction

  Please share your thoughts on this one.

  Best regards



[jQuery] Re: getting the (computed) background-color

2008-02-11 Thread Jake McGraw

Ah, this issue bit me in the ass, using jQuery 1.2.3... is this a
browser/css quirk or is there a planned fix?

- jake

On Jun 17, 2007 7:31 AM, Fil [EMAIL PROTECTED] wrote:

  I'am not sure, but this one may be faster:
 
  // get the background color
  var current_p = $(this);
  var bg = transparent;
  while(bg == transparent) {
  bg = current_p.parent().css('background-color');
  current_p = current_p.parent();
  }

 you have a parent() too many ;-)

 anyway this will fail if everything is transparent: you'll hit the
 document as $('html').parent() and get a js error when doing .css() on
 it.

 -- Fil



[jQuery] Re: advanced callbacks?

2008-02-11 Thread Cloudream

try $(xxx).slideUp().ajax({xxx});

On Feb 11, 8:40 pm, lgr888999 [EMAIL PROTECTED] wrote:
 how would i go for doing a slideUp and an ajax request simultanously
 but only handle the ajax response once the slideUp is finished?


[jQuery] Re: jQuery won't recognise attribute names containing [square brackets]

2008-02-11 Thread Dave Stewart

Hey Marty,
I couldn't live without PHP's square brackets. I just about always
want to split up a form into component parts.
I could easily write something using RegExp to do this for me, but
having it all built in is just lovely.

Great that Rails has it too.

Cheers,
Dave


[jQuery] Re: Assigning an animation toggle to a checkbox to fade a table row in/out

2008-02-11 Thread andrea varnier

On 11 Feb, 15:22, quirksmode [EMAIL PROTECTED] wrote:
 I have created a table, at the end of each table row is a checkbox.
 When the user selects the checkbox, that row will fade out to give the
 illusion its now disabled. When the checkbox is unchecked I want the
 row to fade back.

hi
for the checkbox you can use a code like this:

$('.deleteRow').click(function(){
   if ($(this).is(':checked')) $
(this).blur().parent().parent().animate({opacity: 0.2});
else $
(this).blur().parent().parent().animate({opacity: 1});
});

I added a blur() so the faded checkbox gets deselected.

~

personally I'd rather do something like this:

$('.deleteRow').click(function(){
if ($(this).is(':checked')) $
(this).blur().parent().parent().children('td').not(':last').animate({opacity:
0.2});
else $
(this).blur().parent().parent().children('td').not('last').animate({opacity:
1});
});

this way the checkbox doesn't fade with the rest of the cells :)


[jQuery] Re: jQuery won't recognise attribute names containing [square brackets]

2008-02-11 Thread Dave Stewart

Hi Aaron,
Good styles there with the name attribute stuff. Not so good if you
want to grab other entities such as selects, but good to see that it
accepts non-standard characters.


[jQuery] Re: Assigning an animation toggle to a checkbox to fade a table row in/out

2008-02-11 Thread motob

Yes, fading table rows can be done, and you've almost got it. Right
now your javascript will fade out all table rows in the document when
any check box is clicked.

$(tr).animate({
opacity: 0.2,
  }, 1000 );

So you need to change $(tr).animate(...) to something like $
(this).parent(tr).animate(...);

$(this).parent(tr) will target only the single row that contains the
clicked check box, which is what you want.



On Feb 11, 9:22 am, quirksmode [EMAIL PROTECTED] wrote:
 I have created a table, at the end of each table row is a checkbox.
 When the user selects the checkbox, that row will fade out to give the
 illusion its now disabled. When the checkbox is unchecked I want the
 row to fade back.

 Can this be done? I have managed to do it rather crudely in the
 following example:

 Javascript...

 script
  $(document).ready(function(){
 $(.deleteRow).click(function(){
   $(tr).animate({
 opacity: 0.2,
   }, 1000 );
 });
   });
  /script

 Html...

 table
 tr
 thHeading/th
 thSecond Heading/th
 thThird Heading/th
 /tr
 tr
 tdtest row 1/td
 tdinput name=input1 type=text //td
 tdselect name=select1 option value =firstfirst/option/
 select/td
 td class=rightinput id=go name=deleteRow type=checkbox
 class=deleteRow value=deleteRow //td
 /tr
 /table

 Css...

 style type=text/css

 table{
 width:500px;
 border-collapse:collapse;

 }

 tr th{
 font-weight:bold;
 text-align:left;

 }

 tr td.right{
 text-align:right;

 }

 tr{
 border-bottom:1px solid #ccc;

 }

 /style


[jQuery] bug with animate and a duration of 0 milliseconds?

2008-02-11 Thread arthur.lawry


I noticed a bit of an oddity when playing around with the hover state of an
object and animations that I'd like to describe.

First, I'll give you some sample code.  In my body, I have the following two
links:


lt;a href=#
style=display:block;height:100px;width:100px;line-height:100px;background-color:red;text-align:center;
class=zerogt;zerolt;/agt;
lt;br /gt;
lt;a href=#
style=display:block;height:100px;width:100px;line-height:100px;background-color:red;text-align:center;
class=onegt;onelt;/agt;


the class names and text refer to the number of milliseconds on hover that
the opacity should change from its initial state (40%) to 100%.

In the header, along with a script tag linking in the latest version of
jquery, I have the following in a ready function:


$(.zero).animate({ opacity : 0.4 },0).hover( function(){
$(this).stop().animate({ opacity : 1 },0);
}, function(){
$(this).animate({ opacity : 0.4 },500);
});
$(.one).animate({ opacity : 0.4 },0).hover( function(){
$(this).stop().animate({ opacity : 1.0 },1);
}, function(){
$(this).animate({ opacity : 0.4 },1000);
});


Class zero gets initially set to 40% opacity over 0ms.  Upon hover over the
opacity should get set to 100% over 0ms (immediately), but instead the
animation takes the default duration to complete.

Class one is the same as class zero, but the haver animation takes one
millisecond to execute and works much like class zero was originally
intended.

The interesting thing I noticed was that outside the hover event, the
duration of 0ms seemed to be handled correctly, but inside the hover event,
0 was treated like a boolean false indicating no specified duration, thus
defaulting to the default animation duration (500ms?).

I'm looking for some validation before I report this as a bug, so if anyone
can take a few seconds to try out the above code and share your thoughts, It
would be greatly appreciated!
-- 
View this message in context: 
http://www.nabble.com/bug-with-animate-and-a-duration-of-0-milliseconds--tp15413274s27240p15413274.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Stefan Petre Interface Sortable Item

2008-02-11 Thread stan

This plugin works fine until the element that it is placed on is
allowed to scroll.  If allowed to scroll, the helperclass drop
location is further and further away from the drag element the more
the element scrolls.  Is there a fix for this problem?


[jQuery] double ajax calls don't work in IE

2008-02-11 Thread hcvitto

hi
got this problem:|

i load a page in a div with the load method using this function:

$(#myLink).click(function(){
$(#myDiv).load(myPage.php, function(){
myFunction();
});
return false;
});

myPage.php has a dropdown menu which makes another load in a div

var myFunction= function() {
(#myDropdown).change(function() {
gruppo = $(#myDropdown).val();
$(#myDiv2).load(myPage2.php.php?id=+id, function() {
 myFunction2();
 });
});
}

it works fine in firefox but not in ie which doesn't show anything
after i choose something from the edrop down.
i guess is something related to linking the function at the right
moment but i'm not really good in Javascript.

Any suggestion?

thanks vitto


[jQuery] IE/FF Memory Leak

2008-02-11 Thread optimalcapacity

I am a newbie to jQuery so this may be a simple answer...

My goal in this exercise is to return a specific html table block
(table.DetailTable) from a dynamically generated html page which is
the result of a servlet call into a div (xyz).  The issue I am having
is that whether I set the timer interval to 1 second (1000) or 30
seconds (3), this code is leaking horriblly.  I verified the leak
in both IE6 and FF 2.0.0.12.

Here's the abbreviate code snippet that I'm working with:

function loadMyData(){
var t;
$(#xyz).load(http://URL table.DetailTable,{Param1:Param1Value});
t = setTimeout(loadMyData(), 5000);
}

$(document).ready(
function(){
loadMyData();
}
);

Any help with this issue is very much appreciated!


[jQuery] Re: is there autoscrolling in jQuery?

2008-02-11 Thread Bhaarat Sharma

thanks morningZ.  yeah pretty cool functionality. later i found out
that its done in Flash.

I cant see the demonstration for the plugin you sent. it is apparently
blocked from my work...bummer. But I will def. check it out.

Karl: thanks, i did come across that plugin but apparently it only
works when holding down the ctrl key right. I didnt see much options
with that plugin.  But it does look very close to what is needed.
Since i am new...can you please tell me if it will be feasible for me
to modify the plugin in a way so that it works (1) just hovering (2)
and hovering on an external image (like 'Auto Scroll' image in the
original link i sent) if it is feasible then i can start playing
around with it.

Thanks a bunch.

On Feb 11, 12:08 am, Karl Swedberg [EMAIL PROTECTED] wrote:
 here's one that works by holding down the Ctrl key and hovering :

 http://jdsharp.us/jQuery/plugins/AutoScroll/

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

 On Feb 10, 2008, at 9:05 PM, MorningZ wrote:



  That is pretty cool functionality

  I don't think there is anything but in scroll wise in jQuery core, but
  there is an excellent plugin called ScrollTo, it's very flexible and
  usefull... might be worth checking out:

 http://plugins.jquery.com/project/ScrollTo

  Off the top of my head, you could have an image like that AutoScroll
  on the example you linked to, check the MouseOver for x position and
  kick off the ScrollTo animation with the x value of the mouse on the
  image as the speed...

  On Feb 10, 8:02 pm, Bhaarat Sharma [EMAIL PROTECTED] wrote:
  Hello

  Yesterday i came across an autoScroll feature on this linke

 http://www.etsy.com/time_machine2.php

  if you hoover on the Auto Scroll button then the div starts to
  scroll towards the left. the speed can be increased or decreased  
  based
  on how far you have hooverd on the Auto Scroll button.  I was  
  really
  impressed with this functionality.

  Wondering if anyone has seen something similar with jQuery? maybe a
  plugin or something already out there?

  thanks!


[jQuery] Re: Computing value for css key

2008-02-11 Thread Alexey Blinov
Hi.I think you should add px to the new value. Something like this:
$(div#lt).css(left, parseInt($(div#content).css(left))-24+px);

On Feb 5, 2008 2:05 PM, praxis [EMAIL PROTECTED] wrote:


 Hi!

 I'm trying to position a div, #lt, absolutely in relation to another
 div (#content), and subtract 24px so that div#lt.left =
 div#content.left - 24px:

 $(div#lt).css(left, eval(parseInt($
 (div#content).css(left))-24));

 The problem is, I can't get it to happen. I've tried a lot of
 different ways, including the above, but might have missed an obvious
 one?

 Thanks!



[jQuery] Re: jQuery caching DOM refferences? Performance issues

2008-02-11 Thread Michal Popielnicki

Hi there, and thanks for the reply.

Actually there is no visible bottleneck yet and I can't really point
it out since the javascript behind the app is massive and it results
in poor performance under Opera (which is very strange, since its the
fastest browser supporting JS) .

However I was wondering about ways that the performance can be
improved ad that was generally where I suggested the solution and
basing on Your opinion it should work.

If there are any other opinions/suggestions I'd be glad to hear them.

Thanks in advance

Best regards!

On 11 Lut, 01:55, J Moore [EMAIL PROTECTED] wrote:
 You can profile javascript with firebug and see total calls for
 different approaches and how long they take.

 That said, $('#id') is fast, since it is basically getElementById() a
 native javascript method. However, if you call $('#id') 100x, you'll
 see that it's faster to cache it in a variable. e.g

 var id = $('#id');
 for (i=0;i100;i++) {
  id.append(pnumber +i+/p);

 }

 what is the bottleneck in your code?

 -j

 On Feb 10, 6:12 pm, Michal Popielnicki [EMAIL PROTECTED]
 wrote:

  Hi there!

  I've been dealing with some performance clean-up of a code of a web-
  app that I wrote and I was wondering if jQuery does caching of the DOM
  references. Lets say I have a function:

  function myFunction(){
  $('#foo').attr(bar);

  }

  I frequently refer to the function, so is it the case that each time I
  launch it, the DOM is scanned for element with foo id? Or maybe this
  reference is somehow cached?

  If its not, then maybe doing something like this would speed up the
  code execution:

  function DomLinker(){
  this.foo = $('#foo').attr(bar);

  function myFunction(){
  domMember.foo.attr(bar);}

  $(document).ready(
  domMember = new DomLinker();

  }

  Please keep in mind that we talk about case of many executions of
  myFunction

  Please share your thoughts on this one.

  Best regards


[jQuery] Re: submit problem [validation]

2008-02-11 Thread José Pablo Orozco Marín

Yes, im using Jquery validation, but im still trying to translate
this old onClick button to call plugin validate? How can i do
that using the same button? I need to use the same button
cause this button is part of a toolbar.

http://bassistance.de/jquery-plugins/jquery-plugin-validation/


script type=text/javascript


$().ready(function() {

// add * to required field labels
$(div.required 
label).append(nbsp;strongfont color=\#FF\*/font/strongnbsp;);


jQuery.validator.addMethod(specialAlphaNumeric, function( value, element ) {
var result = 
this.optional(element) || value.length = 2  /^([A-Z0-9áéíóúüçìñ.,'_\- 
]+)$/i.test(value);
if (!result) {
//element.value = ;
var validator = this;
setTimeout(function() {

validator.blockFocusCleanup = true;
element.focus();

validator.blockFocusCleanup = false;
}, 1);
}
return result;
}, Puede contener espacios, tener al 
menos dos y cualquiera de los siguientes carácteres: 
[a-z][0-9][áéíóúüçìñ.,'_-]);


jQuery.validator.addMethod(alphaNumeric, function( value, element ) {
var result = 
this.optional(element) || value.length = 2  
/^[A-Z]([A-Z0-9]+)$/i.test(value);
if (!result) {
//element.value = ;
var validator = this;
setTimeout(function() {

validator.blockFocusCleanup = true;
element.focus();

validator.blockFocusCleanup = false;
}, 1);
}
return result;
}, Debe empezar con una letra, tener 
al menos dos y cualquiera de los siguientes carácteres: [a-z][0-9]);

$(#UserRegisterForm).validate({

// the errorPlacement has to 
take the table layout into account
errorPlacement: function(error, 
element) {
if ( 
element.is(:radio) )
error.appendTo( 
element.parent().next().next() );
else if ( 
element.is(:checkbox) )
error.appendTo 
( element.next() );
else
error.appendTo( 
element.parent().next() );
},
// specifying a submitHandler 
prevents the default submit, good for the demo
submitHandler: function() {
alert(submitted!);
},
// set this class to 
error-labels to indicate valid fields
success: function(label) {
// set nbsp; as text 
for IE

label.html(nbsp;).addClass(checked);
}

});

});

/script




[jQuery] in IE, cannot copy from draggable modal layer

2008-02-11 Thread Schmitt


Hi, we have a draggable form overlay where it is desirable that the user can
copy stuff from the modal layer. However in IE7 this is not possible. If I
comment out the $('id').Draggable part the text can then be copied.
Searching has brought no results, does anyone have a solution or suggestion?
-- 
View this message in context: 
http://www.nabble.com/in-IE%2C-cannot-copy-from-draggable-modal-layer-tp15412042s27240p15412042.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Treeview question

2008-02-11 Thread [EMAIL PROTECTED]

Jörn,

Greate plugin.  Very useful indeed.  I have a quick question.  Do you
(or anyone) for that matter know of any problems with IE 6 not
rendering the entire tree?  Let me explain.  I have a large tree 1024
items nested 4 deep.  This page loads in FF fine (takes a while, but
nonetheless fine) but in IE, the top two or three nodes will render
but the rest of the page just shows up as a normal nested bulleted
list.

Any help would be appreciated.  I don't really know if I can post a
code example of this or not.

Thanks,
Scott



[jQuery] Re: Uploader 0.9 beta

2008-02-11 Thread Cloudream

Nice work.

Is there any documents? I think i can write an asp (server) demo for
other developers.

On Feb 11, 3:37 pm, Gilles (Webunity) [EMAIL PROTECTED] wrote:
 Well it is almost finished, my Flash-based file uploader for jQuery.
 The docs are finished, and the widget itself also. Originally intended
 to be a part of UI, but since it has no real connection to UI
 (dependencies and so on) i have decided to release it as a standalone
 plugin.

 Most of you have seen the demo allready but here it is 
 again.http://uploader.webunity.nl/

 Originally based upon swfupload, but based on a really old version of
 swfupload. The version i based the uploader on had:
 - no callbacks for dialog open/dialog hide
 - no multiple file selection masks
 - no filesize limit pre-upload

 I've build all these things into my version, and now they released a
 new version which also has that... (hmmm)
 Anyway, since i based my version on theirs it is only fair that they
 also gather ideas from other sources.

 Let me know if you run into any bugs and i'll try to add the code to
 SVN later this week.


[jQuery] Translate old JS function to Jquery - Super newbie question

2008-02-11 Thread Josoroma

If i have the following button:
a href=javascript:{} class=positive id=button_confirmAction
style=display: block; title=Register onClick=valid(); return
false; 

The aobve button calls the next function:

function confirmAction( action ) {

document.getElementById('button_' + action).style.display = 'none';
document.getElementById('button_back').style.display = 'none';
document.confirm.submit();

return false;

}

My super newbie question is?
How do i can convert the function in Jquery?

Thanks in advance.



[jQuery] Re: mouseover and IE 6

2008-02-11 Thread Eridius


well mouseover does work but i think i did find the issue: look at this code:

//load auto complete after set number characters
if($(this).val().length = self.options.load_number)
{
$('#' + self.options.auto_complete_id).load(self.options.url,
{
search_filter: self.element.val()
},
function()
{
self.show_list();
self.options.list_count = 0;
$('#' + self.options.auto_complete_id + ' 
li').each(function(number)
{
alert('test');
self.options.list_count++;
$(this).bind('mouseenter', function()
{
self.focus(number);
});
});
$('#' + self.options.auto_complete_id + ' li').bind('click',
function(event)
{
self.update_value();
});
});

now with that alert('test') it works fine is ie 6 but without it it does
not, but the click even does work for IE6 with the alert.  it is like when
it try to apply the mouseenter, the element is not there and for the click
it is.  anyone seea nything wrong with this code?

Eridius wrote:
 
 my mouseover event is not taken effect in IE 6
 

-- 
View this message in context: 
http://www.nabble.com/mouseover-and-IE-6-tp15421402s27240p15421790.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Re: Problem with AJAXQueue: dequeue not a function

2008-02-11 Thread Jörn Zaefferer


sozzi schrieb:

I guess I must be using the plugin wrong. I am trying to make sure
that the second AJAX request does not start until the Session.ID
variable (from the first call) was set.
The second call never gets properly executed (below) because
Session.ID is still undefined
So I guess I'm doing something wrong still, but what exactly?
  
You should try to start the second request in the callback of the first. 
That gurantees the right synchronization.


Jörn



[jQuery] Re: Problem with AJAXQueue: dequeue not a function

2008-02-11 Thread sozzi

Thanks for looking at this Jörn,

but then the ajaxQueue plugin becomes rather moot, doesn't it?
Also I was trying to make a plugin of the code above. I just needed
a way to ensure the initial call had come back before continuing.
And for a few minutes there I thought the queue plugin was going to do
that for me transparently:
Queued Ajax requests.
 * A new Ajax request won't be started until the previous queued
request has finished.

I guess I'll just have to wrap my head around how to transport the
jquery selected elements into a nested ajax calls and do the $.each
loop inside the initial success function (I'm talking about the
plugin).



Vielen Dank fuer die Hilfe
CIAO

Angelo

On Feb 11, 2:01 pm, Jörn Zaefferer [EMAIL PROTECTED] wrote:
 sozzi schrieb: I guess I must be using the plugin wrong. I am trying to make 
 sure
  that the second AJAX request does not start until the Session.ID
  variable (from the first call) was set.
  The second call never gets properly executed (below) because
  Session.ID is still undefined
  So I guess I'm doing something wrong still, but what exactly?

 You should try to start the second request in the callback of the first.
 That gurantees the right synchronization.

 Jörn


[jQuery] [validate] changing the error default position

2008-02-11 Thread Sebastián Würtz



How i can change the default position of one element when i get one error?
I want the error dosnt appear appened to the checkbox.

[ ] I accept the rules

with error:

[ ] You must accept thisI accept the rules



[jQuery] Re: Dynamic Variables

2008-02-11 Thread Nate

If you had a consistent naming convention, I think something like the
following would work:

function setClick() {
var id = ;
for(var i = 0; i  arguments.length; i++) {
id = arguments[i];
$(#ckbx_+id).click( function() {
$(this).attr(checked) ? $(#opt_+id).show(medium) : $
(#opt_+id).hide(medium);
});
}
}

setClick(wgmpo, wgmse, tydgc, tydoe, ...);

On Feb 11, 3:11 pm, rsmolkin [EMAIL PROTECTED] wrote:
 Hi,

 I hope someone can help me out a bit.

 I am finding myself doing a lot of code (as I'll paste below).  It's
 basically the same block of code with different variables.

 What I am trying to do is consolidate all that code into a funciton
 where I can declare all the checkboxes I need to create an Click
 function for, and then loop through them and generate the click
 handler as well as other functions for all of them.

 Here is the code snippet:

 $('#ckbx_wgmpo').click(
 function() {
 if ($(this).attr(checked) == true){
 
 $('table#tbl_wgmpo').show('medium');
 }
 else{
 
 $('table#tbl_wgmpo').hide('medium');
 }
 }
 );
 $('#ckbx_wgmse').click(
 function() {
 if ($(this).attr(checked) == true){
 
 $('table#tbl_wgmse').show('medium');
 }
 else{
 
 $('table#tbl_wgmse').hide('medium');
 }
 }
 );
 $('#ckbx_wgmoe').click(
 function() {
 if ($(this).attr(checked) == true){
 
 $('table#tbl_wgmoe').show('medium');
 }
 else{
 
 $('table#tbl_wgmoe').hide('medium');
 }
 }
 );
 $('#ckbx_tyd').click(
 function() {
 if ($(this).attr(checked) == true){
 
 $('div#tyd_info').show('medium');
 }
 else{
 
 $('div#tyd_info').hide('medium');
 }

 }
 );
 $('#ckbx_tydpo').click(
 function() {
 if ($(this).attr(checked) == true){
 
 $('table#tbl_tydpo').show('medium');
 }
 else{
 
 $('table#tbl_tydpo').hide('medium');
 }
 }
 );
 $('#ckbx_tydgc').click(
 function() {
 if ($(this).attr(checked) == true){
 
 $('table#tbl_tydgc').show('medium');
 }
 else{
 
 $('table#tbl_tydgc').hide('medium');
 }
 }
 );
 $('#ckbx_tydoe').click(
 function() {
 if ($(this).attr(checked) == true){
 
 $('table#tbl_tydoe').show('medium');
 }
 else{
 
 $('table#tbl_tydoe').hide('medium');
 }
 }
 );


[jQuery] Reading in the contents of a file.

2008-02-11 Thread tstrokes

Is there a way to get the contents of a file without actually
uploading the it?

Example: I just need the contents not the actual file. I need to parse
the contents of
a file on the fly and display it to the user. Thanks for any help.
--tstrokes


[jQuery] [off topic] invite to game :)

2008-02-11 Thread Feijó


When you're not working, try this nice game to relax
http://delta.astroempires.com/?ref=D.60589

I'm loving, started play about 10 days :)

--

Feijó



[jQuery] Disappearing events?

2008-02-11 Thread Nate

I created three table elements using jquery, and each td cell in the
tables has hover and click events attached to it.

The basic table generation is cached in an array and the only changes
that happen to the initial content occur by updating individual td
contents using $(this).text(val). All of the events fire correctly the
first time a table is rendered, but when the table is updated, only
using .text(..), the events disappear. I've tried tracing what is
happening, but eventually get lost, and was hoping someone would be
able to explain why the events are disappearing.

Here are the affected parts of the code for reference:

var drawInitial = function(wks) {
var cal = [];
for(var i = 4; i = 6; i++) {
cal[i] = $('table cellpadding=0 cellspacing=0
border=0/table');
for(var j = 0; j  i; j++) {
drawWeek().appendTo(cal[i]);
}
}

drawInitial = function(wks) {
return cal[wks];
}
return drawInitial(wks);
}

function drawWeek() {
var wk = $(tr/tr);
for(var j = 0; j  7; j++) {
drawDay(j).appendTo(wk);
}
return wk;
}

function drawDay(dayOfWeek) {
var css = ;

(dayOfWeek == 0 || dayOfWeek == 6) ? css = calendarWeekend : css
= calendarWeekday;
var day = $('td class=calendarBox '+css+'/td');
day.hover(
function() { if($(this).text()) {$
(this).addClass(calendarHover);} },
function() { if($(this).text()) {$
(this).removeClass(calendarHover);} }
);
day.click( function() {
if($(this).text()) {
setSelected($(this).text());
} else {
delayHide();
}
});
return day;
}

function drawMonth() {
var year = widgetDate.getFullYear();
var month = widgetDate.getMonth();

var firstDay = new Date(year, month, 1).getDay();
var daysInMonth = Date.getDaysInMonth(year, month);
var weeksInMonth = Math.ceil((firstDay + daysInMonth) / 7);
var cal = drawInitial(weeksInMonth);
var i = 0, //week
j = 1; //day of month

cal.find(tr:not(.calendarWeek)).each( function() {
$(this).children(td).each( function() {
if(j  firstDay  j = firstDay + daysInMonth) {
$(this).text(j - firstDay);
} else {
$(this).text();
}
j++;
});
i++;
});

$(#+widgetId).html(cal);
}


[jQuery] Re: thickbox reloaded and IE6 not good

2008-02-11 Thread Eridius


Anyone look at my example because it does not work in IE 6 and it is getting
to the point where i really need something to work very soon.


Eridius wrote:
 
 You can see for yourself at: http://dev.kaizendigital.com/js_test/
 
 if you click on the statically created under thickbox reloaded, the first
 time it looks ok but the 2 select boxes are showing up in front, not
 faded.  if you then close and open it again, the select are gone like they
 should be the the bottom part of the page in white(not faded).
 
 
 Klaus Hartl-4 wrote:
 
 
 Yes it has. I'm using it on plazes.com and haven't faced any problems
 yet... What issues exactly? Mayb the CSS isn't up-to-date in the
 repository.
 
 --Klaus
 
 
 On Feb 6, 5:17 pm, Eridius [EMAIL PROTECTED] wrote:
 I just tested the index.hmtl from the jquery svn repository for thickbox
 realoaded in IE 6 and there are quite a few issues with it.  has
 thickbox
 reloaded been tested in IE 6 yet?
 --
 View this message in
 context:http://www.nabble.com/thickbox-reloaded-and-IE6-not-good-tp15306762s2...
 Sent from the jQuery General Discussion mailing list archive at
 Nabble.com.
 
 
 
 

-- 
View this message in context: 
http://www.nabble.com/thickbox-reloaded-and-IE6-not-good-tp15306762s27240p15418705.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Re: Appending content in order

2008-02-11 Thread Feijó





Hi Karl,


Its a bit more confunsing, I simplified too much

In my div, I change a value from a select

that triggers a code that clone the select parent (the div)

If I do that a few times, every new div goes to the bottom

I do not know what eq() is!! there is a function that return that?

Here is a sample of current code:


 $("#thefilter img#new-criteria").click(function(){
  $last = $('#thefilter .qz-tablefield:eq(1)')
   .clone(true);

  $last
   .appendTo($('#qz-criteria'))
   .hide()
   .fadeIn('medium')
   .find('.clean-criteria')
   .trigger('click');
 });

my select triggers that event. How to adjust with your
suggestion?


Feij



Karl Swedberg escreveu:

Hi Feij,
  
  
you could try this ...
  
  
$('div.main  div.sub:eq(2)').after('div
class="sub"/div');
  
  
That should insert your new div after the 3rd one.
  
  
--Karl
  
_
  
Karl Swedberg
  
www.englishrules.com
  
www.learningjquery.com
  
  
  
  
On Feb 11, 2008, at 2:25 PM, Feij wrote:
  
  
  consider that html:


div class=main

 div class=sub/div

 div class=sub/div

 div class=sub/div

 div class=sub/div

 div class=sub/div

/div



I need to append a new div class=sub/div as the 2nd,
3rd, middle, etc.

Append() add after the last one.


How can I do that? Its possible?




Thanks

Feij


  
  





[jQuery] Re: plugin to upload files

2008-02-11 Thread Benjamin Sterling
Dave,
Most of the plugins you are going to find will use flash to get the progress
bar and some other functionality that you just can't get with javascript.  I
am not sure how the jqUploader functions, but I believe that it would fail
nicely if flash is not installed giving you the basic html file input.

With that said, what are you looking to get from the plugin?

On 2/11/08, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:


 Hi,

 I'm looking for a jquery plugin that will help me upload files, some
 which may be large ( 20 MB).  I have seen jqUploader, but it seems
 like that requires Flash and I would not want to i mpose that
 requirement on end users.

 Thanks for any advice, - Dave




-- 
Benjamin Sterling
http://www.KenzoMedia.com
http://www.KenzoHosting.com
http://www.benjaminsterling.com


[jQuery] Appending content in order

2008-02-11 Thread Feijó





consider that html:

div class=main
 div class=sub/div
 div class=sub/div
 div class=sub/div
 div class=sub/div
 div class=sub/div
/div


I need to append a new div class=sub/div as the 2nd,
3rd, middle, etc.
Append() add after the last one.

How can I do that? Its possible?



Thanks
Feij





[jQuery] Re: ANNOUNCE: Truncate plugin v.2.3 -- now preserves HTML

2008-02-11 Thread Giant Jam Sandwich

We can play a game of Checkers or Go Fish for ownership rights ;)

I actually scoped out Expander this past weekend for some ideas.
Regular Expressions don't exactly bring about resounding joy in my
voice, but in order to get this to work I had to go down that route.
http://www.regexpal.com is my friend.

Keep on keeping on with the Expander plugin -- we may join forces in
the future sometime :)

Brian


On Feb 11, 12:51 pm, Karl Swedberg [EMAIL PROTECTED] wrote:
 Excellent job, Brian!

 Seems we have some overlap, which I'm sure is my fault because your
 plugin was around long before mine was 
 (http://plugins.learningjquery.com/expander/
 ). If only I had known before I got to work on mine... Oh well. It'll
 be fun to poke around the truncate plugin's code to see how similar
 our approaches were.

 Cheers,

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

 On Feb 11, 2008, at 12:22 PM, Giant Jam Sandwich wrote:



  This has been a long time coming, and is a major update for the
  plugin. Previously, if you decided to truncate a string, it would
  strip all the HTML from that string. Essentially, it worked by slicing
  the string in two, and by hiding the second half. The new version uses
  a series of regular expressions, and maintains two copies of the
  string. I won't go into all the technical details, but I threw some
  pretty nasty HTML at it, and it seemed to work well. Empty HTML tags
  after the truncate will be removed, but any HTML closing tag after the
  truncate associated with an HTML opening tag before the truncate will
  remain. So if you truncated mid list item, formatting would still be
  maintained for the list.

  Give it a go, and let me know if you discover any bugs. Thanks!

 http://www.reindel.com/truncate/

  Brian Reindel


[jQuery] Re: How do I attach a toggle to a checkbox. I want a table row to fade out/in, when a checkbox is toggled

2008-02-11 Thread quirksmode

I managed to come up with this, which seems to work to some extent.

script
  $(document).ready(function(){
  $('input#go').click(function() {
 if($(this).attr(checked)) {
$(tr).animate({
opacity: 0.2,
  }, 500 );
 } else {
$(tr).animate({
opacity: 1,
  }, 500 );
 }
});
});
  /script

My next problem is how can I tell only the selected row to fade. At
the moment everything that is a tr is fading. Is there a way of
passing a style to the tr and then fading that style? Also, I want to
apply a red striped background image to the faded row. How do i fade
in a background-image?


[jQuery] [NEW] jQuery.SerialScroll

2008-02-11 Thread Ariel Flesler

Hi everyone

   I added the first release of jQuery.SerialScroll. This is a generic
and very customizable plugin to navigate series of elements.

This plugin is similar to jQuery.LocalScroll: (http://
flesler.blogspot.com/2007/10/jquerylocalscroll-10.html)
But it serves a different purpose. Instead scrolling to elements at
random, this one takes a prev and next button, and a group of
items and it will take care of the navigation.

It also uses jQuery.ScrollTo (http://flesler.blogspot.com/2007/10/
jqueryscrollto.html) to handle the animation part, you get access to
all its settings. That gives you around 20 options to customize.

It doesn't have a fixed purpose and in the demo, I exemplified 3
different uses.

While doing it, I realized some of its settings, were also useful for
jQuery.LocalScroll so I added them into a new release.
The latter has 3 new options: stop, lock and hash. I also added a
function called $.localScroll.hash(). They are all well explained.

jQuery.ScrollTo got a new option called 'over'. And it is demonstrated
in the demo page.

Here's the blog entry of jQuery.SerialScroll:
   http://flesler.blogspot.com/2008/02/jqueryserialscroll.html

Cheers :)

Ariel Flesler


[jQuery] Re: IE/FF Memory Leak

2008-02-11 Thread Jeffrey Kretz

I'm a bit confused by your method, as its going to recurse every 5 seconds.

But regardless of that, have you thought of using a callback on your ajax?

$.ajax({url:'blabla',data:'param1=value',success:dothis});

function dothis(results)
{
$('#xyz').html(results);
do_something_else(results);
}

-Original Message-
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of optimalcapacity
Sent: Monday, February 11, 2008 7:17 AM
To: jQuery (English)
Subject: [jQuery] IE/FF Memory Leak


I am a newbie to jQuery so this may be a simple answer...

My goal in this exercise is to return a specific html table block
(table.DetailTable) from a dynamically generated html page which is
the result of a servlet call into a div (xyz).  The issue I am having
is that whether I set the timer interval to 1 second (1000) or 30
seconds (3), this code is leaking horriblly.  I verified the leak
in both IE6 and FF 2.0.0.12.

Here's the abbreviate code snippet that I'm working with:

function loadMyData(){
var t;
$(#xyz).load(http://URL table.DetailTable,{Param1:Param1Value});
t = setTimeout(loadMyData(), 5000);
}

$(document).ready(
function(){
loadMyData();
}
);

Any help with this issue is very much appreciated!



[jQuery] Re: advanced callbacks?

2008-02-11 Thread andrea varnier

On 11 Feb, 13:40, lgr888999 [EMAIL PROTECTED] wrote:
 how would i go for doing a slideUp and an ajax request simultanously
 but only handle the ajax response once the slideUp is finished?

uhm... I'd try something like this:

$.ajax({
url: 'myfile',
...
success: function(data){
 $('#target').slideUp(function(){
   // do what you have to do with your
data
 });
 }
});


[jQuery] Re: bug with animate and a duration of 0 milliseconds?

2008-02-11 Thread Ariel Flesler

Indeed, I had this problem with a plugin and 1 turned out to be the
solution, 0.5 (etc) also works.

Cheers

Ariel Flesler

On 11 feb, 23:12, Dave Methvin [EMAIL PROTECTED] wrote:
  Class zero gets initially set to 40% opacity over 0ms.  Upon hover over the
  opacity should get set to 100% over 0ms (immediately), but instead the
  animation takes the default duration to complete.

  Class one is the same as class zero, but the haver animation takes one
  millisecond to execute and works much like class zero was originally
  intended.

 I haven't looked at the animate code, but the || operator is probably
 used to assign the default value. The behavior of that operator means
 that a value of numeric 0 gets the default.

 If you are using your own variable for the duration and want to make
 sure the default is never used, just use || 1 to make sure it is at
 least 1 millisecond.


[jQuery] Re: Hash as URL

2008-02-11 Thread frizzle

Thanks for your reply oliver.
No offence, but i kinda was heading this way, until i realized that it
wouldn't solve my back/forward buttons problem,
since the event would only be called by a click on a link...

(Though your approach looks a lot better then mine...)

Thanks,
Frizzle.

On Feb 11, 9:00 am, oliver [EMAIL PROTECTED] wrote:
 That function is only firing once, when the DOM is ready.  You want it
 to fire every time one of your links is clicked, so add a click
 handler to each of them.  Inside of that handler, don't look at the
 location, instead look at the href of the clicked item and extract
 that hash.

 Assuming a like looks like this:
 a href=#foobar/a

 $(document).ready(function() {
 $('#files a').click(function(event) {
 $(#files).load(index.php?explore= +
 this.href.substring(1));
 });

 });

 The problem is that when #files get loaded with new data, those click
 handlers won't be on the new items; so a better approach would be to
 just add one click handler to the parent and inspect the target:

 $(document).ready(function() {
 $('#files').click(function(event) {
 if (event.target.href) {
 $(this).load(index.php?explore= +
 event.target.href.substring(1));
 }
 });

 });

 o

 On Feb 10, 9:05 am, frizzle [EMAIL PROTECTED] wrote:

  Hi there,

  I have some links on a page inside div id=files/div.
  They link to the same page, but with a different hash.
  The hash should define what url will be loaded into #files.

  I have the script below:

  script type=text/javascript
$(function() {
  $('#files').load(index.php?
  explore=+location.hash.substring(1));
});
  /script

  It works when someone goes to the page with a defined hash, or if you
  refresh the page with a certain hash,
  but just by clicking the links and back/forward in the browser it
  won't work. The script doesn't get fired again..

  I hope this is clear.

  Thanks,
  Frizzle.


[jQuery] UI DatePicker Interface on IE, datepicker fails to show

2008-02-11 Thread Neek

When UI Date Picker and Interface are both included into a page in IE,
datepicker will pop-up and become transparent. Only the drop-down
month and year list will show. You are still able click the dates, but
there is nothing showing.
I know it relates to the absolute positioning of datepicker_div
element which interface is making disappear.
Lines 330 - 331 in ui.datepicker.js is where the positioning is where
the datepicker_div element positioning is set, but I don't know where
in interface.js the error is being created, because interface.js is
packed.

Any clarification on this so I can submit a bug tracker to interface
people would be greatly appreciated.

jQuery 1.2.2
Interface 1.2
UI Date Picker v3.3


[jQuery] Load result of form get into div

2008-02-11 Thread sharq

Hi,
im new in jquery and all javascript, and id like to load the search
result into div. For search i used Search Engine Builder, but i dont
know how can i make this script work together with jquery. Or i can
see search result on main page, or when try to load it into div i get
only that words that i wrote to input. Could someone look on
http://www.sharq.yoyo.pl/commonlaw/ and help me with that? Regards


[jQuery] Assigning an animation toggle to a checkbox to fade a table row in/out

2008-02-11 Thread quirksmode

I have created a table, at the end of each table row is a checkbox.
When the user selects the checkbox, that row will fade out to give the
illusion its now disabled. When the checkbox is unchecked I want the
row to fade back.

Can this be done? I have managed to do it rather crudely in the
following example:

Javascript...

script
 $(document).ready(function(){
$(.deleteRow).click(function(){
  $(tr).animate({
opacity: 0.2,
  }, 1000 );
});
  });
 /script


Html...

table
tr
thHeading/th
thSecond Heading/th
thThird Heading/th
/tr
tr
tdtest row 1/td
tdinput name=input1 type=text //td
tdselect name=select1 option value =firstfirst/option/
select/td
td class=rightinput id=go name=deleteRow type=checkbox
class=deleteRow value=deleteRow //td
/tr
/table

Css...

style type=text/css

table{
width:500px;
border-collapse:collapse;
}

tr th{
font-weight:bold;
text-align:left;
}

tr td.right{
text-align:right;
}

tr{
border-bottom:1px solid #ccc;
}

/style


[jQuery] Re: Copying menu item from one menu to another

2008-02-11 Thread Karl Swedberg


I just saw this tutorial that explains something just like what you've  
described:


http://jmar777.blogspot.com/2008/02/easy-multi-select-transfer-with-jquery.html


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



On Feb 11, 2008, at 5:30 PM, [EMAIL PROTECTED] wrote:



Hi,

Let's say I have a SELECT menu with id = fromMenu and if a user
clicks the Add button, I want the selected menu item from the
fromMenu to be appended as the last item in antoher menu with id =
toMenu.

I'm sure this is simple.  How can it be done?

Thanks, - Dave




[jQuery] advanced callbacks?

2008-02-11 Thread lgr888999

how would i go for doing a slideUp and an ajax request simultanously
but only handle the ajax response once the slideUp is finished?


[jQuery] Re: say goodbye to sifr

2008-02-11 Thread Dan G. Switzer, II

That was my thought too. Microsoft released the ability to send downloadable
fonts back in like 1996 with IE4. I remember thinking Hey, finally I won't
be forced to make images every time I want to use a non-standard font. Boy
was I wrong!

-Dan

-Original Message-
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Dragan Krstic
Sent: Monday, February 11, 2008 3:17 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: say goodbye to sifr

I will stick with sifr. Microsoft tried their solution for fonts on web,
but without success. Safari doesn't have great share on browser market.


On 10/02/2008, schnuck [EMAIL PROTECTED] wrote:



http://www.appleinsider.com/articles/08/02/07/apples_safari_3_1_to_su
pport_downloadable_web_fonts_more.html





--
Dragan Krstić krdr
http://krdr.ebloggy.com/



[jQuery] Re: Plugin method

2008-02-11 Thread Olivier Percebois-Garve
Thanks alot Richard

I finally came up with the following (makes a nested list of checkboxes and
their labels behave like a tree):


-Olivier

(function($){
$.fn.treeview = function(o){
var defaults = {
minus:
'url(style/site/interface/public/treeview/minus.gif) 0 0 no-repeat',
plus:
'url(style/site/interface/public/treeview/plus.gif) 0 0 no-repeat'
};
var opt = $.extend(defaults, o);
var $uls = $('ul', this);

var setparentbg = function(o){
if ($(o).css('display') != 'none')
$(o).parent().children('label').css({background: opt.minus});
else
$(o).parent().children('label').css({background: opt.plus});
}

//add plus / minus icons
$uls.each(function(i, o){
setparentbg($(o));
});

//set behavior
$('li', this).each(function(i, o){
if ($('ul', o).length != 0){
 $(o).children('label').toggle(

function(){

$(o).children('ul').hide('slow');

$(o).children('label').css({background: opt.plus});

},

function(){

$(o).children('ul').show('slow');

$(o).children('label').css({background: opt.minus});

}

);
}
});

}
})(jQuery);







On Feb 7, 2008 3:50 PM, Richard D. Worth [EMAIL PROTECTED] wrote:


 On Feb 7, 2008 6:54 AM, Olivier Percebois-Garve [EMAIL PROTECTED]
 wrote:

  $li.each(function(o, i){
  $(o).setBg();
  });
 

 I think you want:

 $li.each(function(i, o) {
   setBg(o);
 });

 -or-

 $li.each(function() {
   setBg(this);
 });

 Also, on the documentation for each():

 http://docs.jquery.com/Core/each

 I noticed i comes first, o second.

 - Richard




[jQuery] jquery slider on DIV problem

2008-02-11 Thread wilq

There is simplest code ever:

DIV id='sliderArmyMove' class='ui-slider-1' style=margin: 0px;
div class='ui-slider-handle'
/div/div

styles for classes set:

.ui-slider-1 { width: 200px; height: 23px; position: relative;
background-image: url(images/forms/slider.png); background-repeat: no-
repeat; background-position: center center; }
.ui-slider-handle { position: absolute; height: 23px; width: 12px;
top: 0px; left: 0px; background-image: url(images/forms/
slider.gif);  }
.ui-slider-disabled .ui-slider-handle { opacity: 0.5; filter:
alpha(opacity=50); }


If i put those two DIV in a body, slider works well, if i put them on
a div, that is on div that is on another div it stop working (last DIV
that the slider is on have position:absolute). Anyone got any solution
for this problem? (I tried to find problem on googles and no luck this
time;() Thanks for any reply




[jQuery] Re: handle in draggable() does not work - whole div is draggable

2008-02-11 Thread asle

Sorry, here is the dragable code:

 $(#trekning).livequery(function(){
$(this).draggable({opacity: .7,handle:#dragTitle})


[jQuery] [validate] Adding custom behaviours following validation

2008-02-11 Thread kapowaz

I'm looking to modify the markup surrounding my form elements once
validation has taken place so as to indicate success/failure with a
particular input element's contents, and I'm wondering if the Validate
plugin can do this without any modification? To give an example,
imagine I have the following markup:

dl
dtlabel for=usernameUsername/label/dt
ddinput name=username //dd
dtlabel for=passwordPassword/label/dt
ddinput type=password name=password //dd
dtlabel for=confirmpasswordConfirm password/label/dt
ddinput type=password name=confirmpassword //dd
/dl

Adding validation rules to this using the plugin is very easy, and
since by default it will add a class of error to any elements with
invalid values, I can add a highlight rule for inputs easily enough.
However, what I'd like to do is set a class of 'pass' or 'fail' to the
containing DD element, so that I can indicate which fields have been
successfully filled in.

If I was doing this in a nice jQuery-esque fashion, I'd hook in some
functionality to addClass/removeClass using a custom event, but as far
as I can see this plugin doesn't provide any custom events to handle
this (unless I'm missing something blindingly obvious?). Can anybody
suggest a route to achieving what I've got in mind that doesn't
involve hacking the plugin itself?


[jQuery] Madness in IE6

2008-02-11 Thread Ash

Hi,

I am using jQuery Cycle on our portfolio page and all is fine, apart
from IE6 (Shock IE6 not playing ball?) can anyone help me? Please?

Here's the page...
http://www.c9dd.com/v2/portfolio/index.php

Thanks

Ash


[jQuery] Re: submit problem [validation]

2008-02-11 Thread expresso

Are you using JQuery?  This looks like plain old JavaScript.  I don't
think you need to be using Onclick.  That's the whole point of using
JQuery.

Check the following tutorial: 
http://docs.jquery.com/Tutorials:Getting_Started_with_jQuery

We don't need to write an onclick for every single element. We have a
clean separation of structure (HTML) and behavior (JS), just as we
separate structure and presentation by using CSS.

On Feb 10, 5:44 pm, Josoroma [EMAIL PROTECTED] wrote:
 I have a form without a submit button, i was making the submit with
 the following code:

 div class=buttons
 a href=javascript:{} class=positive id=button_confirmAction
 style=display: block; title=Register
 onClick=confirmAction('confirmAction'); return false; img src=/
 hoyque/img/icons/tick.png alt=/Register/a
 div

 How do i enable the call to validate before to realize the submit with
 my href onclick button above?

 Thanks in advance.


[jQuery] combining Cycle and Thickbox

2008-02-11 Thread Jeroen Coumans

Hi all,

I'm trying to create a simple, automatic slideshow by combining the
Cycle plugin and the Thicbox plugin. With the cycle plugin I can
easily convert a paragraph with images to a highlighy configurable
automatic slideshow, which I want to open in a thickbox. Markup is as
follows:

p id=slideshow
  img src=img1.png
  img src=img2.png
  img src=img3.png
  img src=img4.png
/p

Here's what I've come up with so far:

$(document).ready(function() {

  // wrap the slideshow and add pager
  $('#slideshow')
  .wrap('div id=wrapper')
  .before('div id=nav')
  .cycle({
  pager:  '#nav'
  });

  // hide the wrapper
  $('#wrapper').hide();

  // create a link to start the slideshow in a thickbox
  $('pa href=#TB_inline?height=600width=800inlineId=wrapper
class=thickboxStart slideshow/a/p')
  .insertAfter('#wrapper');

  // Initialise thickbox
  tb_init('a.thickbox');

});

However, the cycle plugin doesn't seem to work inside the thickbox,
eg. the pager doesn't work and the slides don't automatically change.
Anybody got an idea on how to solve this? Thanks!

Regards,
Jeroen Coumans


[jQuery] Getting the highlighted text

2008-02-11 Thread duggoff

I have a textarea and a button that allows me to select some text and
apply a span and class to it. What I need to do is select that text
later and remove the span and class by clicking on a button. I think I
can handle to part that removes the span and class, but I don't know
how to get the selected text after I've highlighted it. Can anyone
help me?


[jQuery] Slow script startup times in IE6

2008-02-11 Thread Gordon

A few months back I wrote the client side code for our IT assistant
(http://www.pcwb.com/assistants/) as a project to find more
interesting ways for people to shop. The idea being that if we give
the users an interesting user interface that encourages them to play
with it then they might be more inclined to actually purchase.

It lay dormant for a few months but interest in pushing the assistant
has increased recently so we started setting up some product mixes for
it.

unfortunately we hit a bit of a snag when the product count got above
about 30, in Internet Explorer 6 the script started throwing up
messages saying the script was running slowly when the initial page
setup was happening. The system works fine if you let the script run
to completion but we really don't want requesters like this popping up
in actual use.

The problem only manifested itself in IE6, it seems the improvements
made to the script engine in IE7 cut the setup time down enough to
prevent the slow script warning appearing.  It hasn't yet happened in
FireFox, Opera or Safari.

I spent a lot of time optimizing this script to run at acceptable
speeds in IE6, but the optimizations focused on improving performance
of the interactivity, which was unbearably slow in IE6 in early
iterations.  So in order to get the performance up I started doing
things like cacheing the properties of all the DOM elements I'd be
interacting with in a Javascript object so I wouldn't have to incur
the cost of reading them in from the DOM and the only time I'd
actually hit the DOM directly is when the script actually changes
something.  It would seem though that the things I've done to improve
interactivity speed have made the setup run too slow for IE 6.

If any of you guys can take a look at the page (I'd recommend using
the laptops assistant as it has a more representative product feed
than the others) and offer suggestions I'd appreciate it.  At the
moment anything I can see that can be taken out of setup would mean
poorer interactive response.


[jQuery] Re: sites made with jQuery

2008-02-11 Thread GianCarlo Mingati

very nice.
GC

On Feb 8, 6:43 pm, RenatoCarvalho.com [EMAIL PROTECTED] wrote:
 Hey, here is another site made with jQuery:

 It's a governmental brazilian website.

 http://www.desenvolvimento.gov.br/

 Plugins used:
 jquery.easing.js
 jquery.color.js
 jquery.dimensions.js
 jquery.thickbox.js
 jquery.cookie.js
 jquery.datePicker.js

 On Feb 7, 3:07 pm, GianCarlo Mingati [EMAIL PROTECTED]
 wrote:

 http://mjijackson.com/2008/01/22/shadowbox-js-media-viewer-1-0-beta/

  On Feb 7, 5:23 pm, cfdvlpr [EMAIL PROTECTED] wrote:

   Can someone please post a link to the shadowbox plugin?


[jQuery] Re: say goodbye to sifr

2008-02-11 Thread Dragan Krstic
I will stick with sifr. Microsoft tried their solution for fonts on web, but
without success. Safari doesn't have great share on browser market.

On 10/02/2008, schnuck [EMAIL PROTECTED] wrote:



 http://www.appleinsider.com/articles/08/02/07/apples_safari_3_1_to_support_downloadable_web_fonts_more.html




-- 
Dragan Krstić krdr
http://krdr.ebloggy.com/


[jQuery] Can we detect whether images are turned off?

2008-02-11 Thread [EMAIL PROTECTED]

Hello again

Still trying to adhere to 'Web Standards' while using (almost too
many) whizzy jQuery effects, I see I'll need to provide some
alternative text styles for users that don't see my lovely background
images. I imagine Javascript can do the detection? Can you please
advise - I read this: 
http://www.thewatchmakerproject.com/journal/53/images-offcss-on-image-replacement
but am confounded by the last paragraph (the script)!

Thanks :o
Cherry


[jQuery] jQuery + SelectBox + IE don't work

2008-02-11 Thread Mr Bola A Bola

There is some problem with this script working in IE. It works in
FireFox. The whole thing consists of HTML page, JS file and CSS file.
The following html page is validated XHTML. It contains Select box and
two anchors for filtering the content of that select box.
One filter filters options by first letter. The other filter is toggle
type.

!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN
   http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd;
html xmlns=http://www.w3.org/1999/xhtml; xml:lang=en lang=en
head
title/title
meta http-equiv=Content-Type content=text/html; 
charset=utf-8 /

link rel=stylesheet type=text/css href=style.css /
script type=text/javascript src=jquery/jquery-1.2.3.js/
script
script type=text/javascript src=script.js/script
/head
body
a id=toggle href=Just own/Not just own/a
br /
a id=alphabetall href=#Все/a
a class=alphabet href=#A/a
a class=alphabet href=#B/a
a class=alphabet href=#C/a
a class=alphabet href=#P/a
br /
select id=market
option class=product own value=0/option
option class=product own A value=11Apple/option
option class=product own B value=12Banana/option
option class=product own A 
value=13Apricot/option
option class=product P value=21Potato/option
option class=product own P value=14Peach/option
option class=product C value=22Carrot/option
option class=product C value=23Cabbage/option
/select
/body
/html

Script file is quite simple and follows:

$(document).ready(function(){
$(.alphabet).click(function() {
var al = $(this).html();
if(onlyown==0) {
$(.product).hide();
alert($(.product).text());
$(.product).hide().filter(.+al).show();
$(#market).val(0);
} else if(onlyown==1) {
$(.product).hide().filter(.own.+al).show();
$(#market).val(0);
}
return false;
});


//*When All is clicked show all records
$(#alphabetall).click(function() {
if(onlyown==0) {
$(.product).show()
return false;
} else if (onlyown==1) {
$(.product.own).show()
return false;
}
});


//*When this is toggled show only OWN or ALL records
var onlyown=0;
$(#toggle).click(function() {
if(onlyown==0) {
$(.product).hide().filter(.own).show();
onlyown=1;
} else if (onlyown==1) {
$(.product).show();
onlyown=0;
}
return false;
});
});

Just in case here is CSS:

.product {
font-family:Arial;
color:green;
}
.own {
font-weight:bold;
color:blue;
}


[jQuery] Re: ClearType rendering issue in IE

2008-02-11 Thread Giant Jam Sandwich

Thanks for that additional resource Bill. Very helpful to have that
information.

On Feb 11, 12:18 pm, Bil Corry [EMAIL PROTECTED] wrote:
 Giant Jam Sandwich wrote on 2/11/2008 11:06 AM:

  Thanks Mike -- that fixed it. The brief flicker in IE7 between
  ClearType and regular type I suppose is unavoidable. I could use a
  slide transition instead, but it wouldn't look as good. Oh well.

 This talks a bit about the problem and offers a second workaround:

 http://mattberseth.com/blog/2007/12/ie7_cleartype_dximagetransform.html

 - Bil


[jQuery] Problem with AJAXQueue: dequeue not a function

2008-02-11 Thread sozzi

Hi there,

I'm trying to write a plugin for the SmugMug JSONP API. One quirk is
that they require a SessionID. So prior to asking for any data the
initial JSONP call for the SessionID has to be returned.

I think the AJAXQueue plugin (http://dev.jquery.com/~john/plugins/
ajaxqueue/) would be a perfect fit. Unfortunately the plugin throws
and error:
FireBug Console output:
jQuery.dequeue is not a function
   complete()ajaxqueue (line 12)
   complete()jquery.js (line 2790)
   onreadystatechange(5)jquery.js (line 2740)
[Break on this error] jQuery.dequeue( jQuery.ajaxQueue, ajax );

I'm not quite certain what would cause this and if it is a problem for
my case at all.

Any help is appreciated.


[jQuery] Re: jQuery.SerialScroll

2008-02-11 Thread Ariel Flesler

Those 2 urls broke down... Here I go again:
ScrollTo: http://flesler.blogspot.com/2007/10/jqueryscrollto.html
LocalScroll: http://flesler.blogspot.com/2007/10/jqueryscrollto.html

By the way.. this plugin is a replacement for jQuery.ScrollShow, it
never got over beta, this one has a better approach.

Ariel Flesler

On 11 feb, 23:57, Ariel Flesler [EMAIL PROTECTED] wrote:
 Hi everyone

    I added the first release of jQuery.SerialScroll. This is a generic
 and very customizable plugin to navigate series of elements.

 This plugin is similar to jQuery.LocalScroll: (http://
 flesler.blogspot.com/2007/10/jquerylocalscroll-10.html)
 But it serves a different purpose. Instead scrolling to elements at
 random, this one takes a prev and next button, and a group of
 items and it will take care of the navigation.

 It also uses jQuery.ScrollTo (http://flesler.blogspot.com/2007/10/
 jqueryscrollto.html) to handle the animation part, you get access to
 all its settings. That gives you around 20 options to customize.

 It doesn't have a fixed purpose and in the demo, I exemplified 3
 different uses.

 While doing it, I realized some of its settings, were also useful for
 jQuery.LocalScroll so I added them into a new release.
 The latter has 3 new options: stop, lock and hash. I also added a
 function called $.localScroll.hash(). They are all well explained.

 jQuery.ScrollTo got a new option called 'over'. And it is demonstrated
 in the demo page.

 Here's the blog entry of jQuery.SerialScroll:
    http://flesler.blogspot.com/2008/02/jqueryserialscroll.html

 Cheers :)

 Ariel Flesler


[jQuery] Re: bug with animate and a duration of 0 milliseconds?

2008-02-11 Thread Dave Methvin

 Class zero gets initially set to 40% opacity over 0ms.  Upon hover over the
 opacity should get set to 100% over 0ms (immediately), but instead the
 animation takes the default duration to complete.

 Class one is the same as class zero, but the haver animation takes one
 millisecond to execute and works much like class zero was originally
 intended.

I haven't looked at the animate code, but the || operator is probably
used to assign the default value. The behavior of that operator means
that a value of numeric 0 gets the default.

If you are using your own variable for the duration and want to make
sure the default is never used, just use || 1 to make sure it is at
least 1 millisecond.


[jQuery] Re: jqGrid with SQL Server version

2008-02-11 Thread Tony

Maybe a good start can be here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnpag/html/scalenethowto05.asp

Personally I use adodb ( http://adodb.sf.net ) with php.
In this case you do not care about what of SQL do you use.

Regards
Tony

On Feb 11, 3:51 pm, Web Specialist [EMAIL PROTECTED]
wrote:
 Hi all. Tony, jqgrid creator, did a good job with that great plugin. Using
 LIMIT clause supported by MySQL is very easy for records pagination. Does
 anyone have a SQL Server 2000 version working with that plugin?

 Cheers


[jQuery] plugin to upload files

2008-02-11 Thread [EMAIL PROTECTED]

Hi,

I'm looking for a jquery plugin that will help me upload files, some
which may be large ( 20 MB).  I have seen jqUploader, but it seems
like that requires Flash and I would not want to i mpose that
requirement on end users.

Thanks for any advice, - Dave


[jQuery] Re: How do I attach a toggle to a checkbox. I want a table row to fade out/in, when a checkbox is toggled

2008-02-11 Thread Christoph Haas

On Mon, Feb 11, 2008 at 04:51:54AM -0800, quirksmode wrote:
 I have created a table, at the end of each table row is a checkbox.
 When the user selects the checkbox, that row will fade out to give the
 illusion its now disabled. When the checkbox is unchecked I want the
 row to fade back.

Not exactly a solution for your task. But remember that TRs are not
writeable in the IE. So you may not be able to hide TRs.

 Christoph
-- 
[EMAIL PROTECTED]  www.workaround.org   JID: [EMAIL PROTECTED]
gpg key: 79CC6586 fingerprint: 9B26F48E6F2B0A3F7E33E6B7095E77C579CC6586


[jQuery] Re: Uploader 0.9 beta

2008-02-11 Thread Bhaarat Sharma

pretty cool functionality.

one thing i can think of is showing the user a thumbnail version of
the image after it has been placed in the queue. rather than just the
name.

great work!

On Feb 11, 10:26 am, Gilles (Webunity) [EMAIL PROTECTED] wrote:
 http://docs.jquery.com/UI/Uploader

 On 11 feb, 14:35, Cloudream [EMAIL PROTECTED] wrote:

  Nice work.

  Is there any documents? I think i can write an asp (server) demo for
  other developers.

  On Feb 11, 3:37 pm, Gilles (Webunity) [EMAIL PROTECTED] wrote:

   Well it is almost finished, my Flash-based file uploader for jQuery.
   The docs are finished, and the widget itself also. Originally intended
   to be a part of UI, but since it has no real connection to UI
   (dependencies and so on) i have decided to release it as a standalone
   plugin.

   Most of you have seen the demo allready but here it is 
   again.http://uploader.webunity.nl/

   Originally based upon swfupload, but based on a really old version of
   swfupload. The version i based the uploader on had:
   - no callbacks for dialog open/dialog hide
   - no multiple file selection masks
   - no filesize limit pre-upload

   I've build all these things into my version, and now they released a
   new version which also has that... (hmmm)
   Anyway, since i based my version on theirs it is only fair that they
   also gather ideas from other sources.

   Let me know if you run into any bugs and i'll try to add the code to
   SVN later this week.


[jQuery] Re: Do tabulations and spaces make a difference?

2008-02-11 Thread Carlos Antonio da Silva

Cristian escreveu:
 Thank you Carlos, probably I was very tired last night. I spent 30
 minutes trying to spot the problem. I'll probably never forget to add
 a semi colon again. :-)
You're welcome..
I'm glad to help...
=)

---
Carlos Antonio da Silva
Sistemas de Informação
Rio do Sul - Santa Catarina

Não deixa de fazer algo que gosta devido à falta de tempo,
a única falta que terá, será desse tempo que infelizmente não voltará mais.




[jQuery] Object doesn't support this property or method on $.post(/Validation/TestAlert,

2008-02-11 Thread expresso

I'm trying to figure out why the browser is complaining about the
following JavaScript which I obtained off a blog post:

var t = $(obj).parent().siblings(0).val();

$.post(/Validation/TestAlert,
{
content: t
},
function(txt){
alert(txt);
});

I get the error Object doesn't support this property or method.

I'm trying to communicate back to my ASP.NET MVC Controller in this
case.

I got the example code from: 
http://www.chadmyers.com/Blog/archive/2007/12/13/using-jquery-with-asp.net-mvc.aspx


[jQuery] jqmodal (ajaxed markup) can't access javascript loaded in page on IE

2008-02-11 Thread [EMAIL PROTECTED]

Hey all,

I've run into an interesting bug.  I'm using jquery's jqmodal plugin
for modals and I'm pulling down additional markup to populate the
modal via ajax.  The new markup is supposed to leverage the existing
javascript (javascript functions, not jquery functions) that modal
owner had retrieved on page load.  And it doesn't seem to be working
on internet explorer... on firefox and safari it works just fine!
Does the new markup need to call eval()? or do something to re-load
the existing javascript so it can use those functions?

Any insight will be greatly appreciated!  Thanks in advance!

P


[jQuery] Re: jquery slider on DIV problem

2008-02-11 Thread wilq

Ok i solved the problem

The problem was, that if u hide element with slider it becomes
unavilable to move when shown again. So to use sliders after showing
context that is on u have to make $(sliderID).slider(options) again...
Is that a bug? Do i have to notice it to creators?


[jQuery] How do I attach a toggle to a checkbox. I want a table row to fade out/in, when a checkbox is toggled

2008-02-11 Thread quirksmode

I have created a table, at the end of each table row is a checkbox.
When the user selects the checkbox, that row will fade out to give the
illusion its now disabled. When the checkbox is unchecked I want the
row to fade back.

Can this be done? I have managed to do it rather crudely in the
following example:

Javascript...

script
 $(document).ready(function(){
$(.deleteRow).click(function(){
  $(tr).animate({
opacity: 0.2,
  }, 1000 );
});
  });
 /script


Html...

table
tr
thHeading/th
thSecond Heading/th
thThird Heading/th
/tr
tr
tdtest row 1/td
tdinput name=input1 type=text //td
tdselect name=select1 option value =firstfirst/option/
select/td
td class=rightinput id=go name=deleteRow type=checkbox
class=deleteRow value=deleteRow //td
/tr
/table

Css...

style type=text/css

table{
width:500px;
border-collapse:collapse;
}

tr th{
font-weight:bold;
text-align:left;
}

tr td.right{
text-align:right;
}

tr{
border-bottom:1px solid #ccc;
}

/style


[jQuery] Re: ClearType rendering issue in IE

2008-02-11 Thread Mike Alsup
Brian,

In IE6 you can usually solve the problem by setting an explicit background
color on the element in question.  But for IE7 you need to remove the
opacity filter after the animation completes:

$('#myDiv').fadeIn(function() {
if ($.browser.msie)
this.style.removeAttribute('filter');
});

Mike


On Feb 11, 2008 8:15 AM, Giant Jam Sandwich [EMAIL PROTECTED] wrote:


 I was inserting some text to a (display:none) DIV with .html(), and
 then showing it with .fadeIn(), and I noticed that IE loses
 ClearType rendering. The font I am using is Georgia. I haven't tested
 any other scenarios other than the one I just described, but has
 anyone else experienced this? I'm on Windows XP SP2 Home Edition.

 Thanks.

 Brian



[jQuery] jqGrid with SQL Server version

2008-02-11 Thread Web Specialist
Hi all. Tony, jqgrid creator, did a good job with that great plugin. Using
LIMIT clause supported by MySQL is very easy for records pagination. Does
anyone have a SQL Server 2000 version working with that plugin?

Cheers


[jQuery] ClearType rendering issue in IE

2008-02-11 Thread Giant Jam Sandwich

I was inserting some text to a (display:none) DIV with .html(), and
then showing it with .fadeIn(), and I noticed that IE loses
ClearType rendering. The font I am using is Georgia. I haven't tested
any other scenarios other than the one I just described, but has
anyone else experienced this? I'm on Windows XP SP2 Home Edition.

Thanks.

Brian


[jQuery] Re: Hash as URL

2008-02-11 Thread oliver

That function is only firing once, when the DOM is ready.  You want it
to fire every time one of your links is clicked, so add a click
handler to each of them.  Inside of that handler, don't look at the
location, instead look at the href of the clicked item and extract
that hash.

Assuming a like looks like this:
a href=#foobar/a

$(document).ready(function() {
$('#files a').click(function(event) {
$(#files).load(index.php?explore= +
this.href.substring(1));
});
});

The problem is that when #files get loaded with new data, those click
handlers won't be on the new items; so a better approach would be to
just add one click handler to the parent and inspect the target:

$(document).ready(function() {
$('#files').click(function(event) {
if (event.target.href) {
$(this).load(index.php?explore= +
event.target.href.substring(1));
}
});
});

o

On Feb 10, 9:05 am, frizzle [EMAIL PROTECTED] wrote:
 Hi there,

 I have some links on a page inside div id=files/div.
 They link to the same page, but with a different hash.
 The hash should define what url will be loaded into #files.

 I have the script below:

 script type=text/javascript
   $(function() {
     $('#files').load(index.php?
 explore=+location.hash.substring(1));
   });
 /script

 It works when someone goes to the page with a defined hash, or if you
 refresh the page with a certain hash,
 but just by clicking the links and back/forward in the browser it
 won't work. The script doesn't get fired again..

 I hope this is clear.

 Thanks,
 Frizzle.


  1   2   >