[jQuery] Pause after .load request

2008-11-15 Thread [EMAIL PROTECTED]

Hello,

I'm trying to fetch some data from a Perl script and have it begin to
display as many times as there is data. More or less a "data"
slideshow. The data is actually very visual, but at the moment, i dont
want to implement a pause, forward/backward option, until I get the
automatic option working.

Basically what I'm trying to do is have the content load, wait, load,
wait, etcWith a reasonable 2 - 3 seconds between each load...Here
is the code I have that isn't quite working:

$(document).ready(function() {
var date_reg = $("input#date_requested").val();
var counter = -1;
while (counter <= date_reg)
{
$("#result").load('/get_time_lapse.pl', {date_requested:
date_reg});
counter = counter + 1;
date_reg = date_reg - 1;
}
});

where date_reg is just the number of times I want to load the screens.
However, if I look at the logs for my Perl script, it does say all 10
calls, immediately, as fast as it can. I've tried to put a javascript
pause or whatever that function was called in here, but it doesnt seem
to work.

Any suggestions to implement a pause between each .load?

Thanks


[jQuery] Re: Confirming submit using Validate plugin

2008-11-15 Thread FrenchiINLA

Add return false; in case of cancel
function confSubmit(form) {
if (confirm("Are you sure you want to submit the form?")) {
   $("#employmentForm").submit();
}
else return false; <--
}//End of confSubmit function


On Nov 15, 3:03 pm, flycast <[EMAIL PROTECTED]> wrote:
> I have a long form where some of the fields are required. The problem
> is that the user is sometimes getting to the point where they have
> filled all the required fields in but is not done and then hits enter
> rather than tab to go to the next field. When they do this the form
> submits. I want to conform that the user really wants to submit when
> they hit enter.
>
> This does not work:
>
> function confSubmit(form) {
> if (confirm("Are you sure you want to submit the form?")) {
>    $("#employmentForm").submit();
>
> }
> }//End of confSubmit function
>
> I get a popup corectly but if I hit cancel on the confirm dialog then
> the form validates/submits anyway rather than returning to the form.


[jQuery] Re: Modernized Portlets?

2008-11-15 Thread Shawn Grover


Thanks Karl, but that is a poor imitation of what is needed (for my 
customer's needs).  Or perhaps I'm not understanding how to work 
with that code quite right?


I have a functional sample of what I'm after here 
http://grover.open2space.com/files/dev/panels/index.htm - click the 
titlebars to collapse, and the "maximize" button to expand even more. 
The panels can be dragged around, and Panel 3 is "mandatory" - it cannot 
be collapsed.


There are still issues here though - dragging panel 2 into the first 
column, and then you cant add to the second column.  And placeholders 
are not showing while dragging.


I stumbled across the portlets while working on this and was hoping 
there might be something a little more complete and modern.  Guess I'll 
keep plugging away at this


Shawn

Karl Swedberg wrote:

Hey Shawn,

There is a rudimentary one in the jQuery UI demos:

http://ui.jquery.com/repository/real-world/layout/

--Karl


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




On Nov 15, 2008, at 5:31 PM, Shawn Grover wrote:



I found the jQuery Portlets at 
http://sonspring.com/journal/jquery-portlets.  This appears to be 
outdated (makes use of the interface library for the sortables rather 
than ui.jquery...).  Does anyone know if there is a more current 
version of this?  And one that doesn't necessarily depend on tables 
would be nice too...


If there isn't one, I guess I'll have to update it...  A customer 
wants this sort of functionality


Thanks for any tips...

Shawn




[jQuery] Re: image toggle

2008-11-15 Thread bob

Thanks ricardo,

Is it possible to do something like this?
It did not seem to work for me.

var menu = ['home','news','sport','music'];

for(var i=0; i

[jQuery] I am trying to fire functions for ui tabs before the show callback

2008-11-15 Thread tripdragon

Right now in this code it fires the hide(); after it has shown. So it
flickers.
And I do not seem to find a hide callback.
Should I use a different system of tabs in the case that it can not do
this?
If so do you have any suggestions?


http://www.pastie.org/315865

$("#gallery2").tabs({
fx: {
  opacity: "toggle", duration: 300
   },

show: function() {
  var seeThis = $(this).parent().find("p.title-text")
  $(seeThis).hide();
  $(seeThis).slideDown();

 //alert('onShow');
}
}).tabs('rotate', 3000);


[jQuery] Re: select a div with a specific value

2008-11-15 Thread Mauricio (Maujor) Samy Silva


Yes I know. :-)
But you is using an *invalid* document and this is the point.
Regards
Mauricio

PS: You can developer an entiere site using *only* the span element and
all jQuery selectors will work.

-Mensagem Original- 
De: "Alfredo Alessandrini" <[EMAIL PROTECTED]>

Para: 
Enviada em: sábado, 15 de novembro de 2008 22:52
Assunto: [jQuery] Re: select a div with a specific value




Hi Mauricio,

whit this:

$("div [value='f1']")

work very good

I can :-)



Thanks,

Alfredo 




[jQuery] [HOWTO] Update IMG SRC after AJAX call?

2008-11-15 Thread Fluffy Convict

Using the following code in my CMS, I can grant or deny certain user
groups access to a certain page. In this example, usergroup #1 has
access to page #2. By clicking the image, the server will respond with
"role-1-2|icons/user-0.gif" (0 meaning "no access"). In the admin of
the site, I have many of these links underneath each other:


  


The code that I'm using to update the image src (from icons/user-1.gif
to icons/user-0.gif), I'm using the following functions. My question
is: how could I accomplish the same with jQuery? Could anybody give me
some pointers, please? Your help is greatly appreciated!

function sendRequest(url) {
  http.open('get', url);
  http.onreadystatechange = handleResponse;
  http.send(null);
}

function handleResponse() {
  if (http.readyState == 4 && http.status == 200) {
var response = http.responseText;
var update = new Array();
if (response.indexOf('|') != -1) {
  update = response.split('|');
  for (i = 0; i < update.length; i = i + 2) {
updatePage(update[i], update[i + 1]);
  }
}
  }
}

function updatePage(div, text) {
  var viewer = document.getElementById(div);
  if (viewer.nodeName == 'IMG') {
viewer.src = text;
  }
  else {
viewer.innerHTML = text;
  }
}


[jQuery] Re: select a div with a specific value

2008-11-15 Thread Alfredo Alessandrini

Hi Mauricio,

whit this:

$("div [value='f1']")

work very good

I can :-)



Thanks,

Alfredo


[jQuery] Re: select a div with a specific value

2008-11-15 Thread Mauricio (Maujor) Samy Silva


Hi Alfredo,
You can't,  because the attribute *value* isn't a valid one for the div 
element in XHTML documents.

And going further:

1-) The attribute *id* must be unique within a document.
2-) Avoid use inline styles.

Regards
Maurício


I've a html page like this:


  
  
  
  


Can I select a div by the value??

$(".chess-board value='b4'")




Thanks,

Alfredo 




[jQuery] Re: Validate. Can I validate using 2 values?

2008-11-15 Thread shapper

Hi Jorn,

You mean using:

 $.ajax({
   beforeSend: function(){
   }
 });

And in before send get the value of the text box and add it to the
ajax validate request of the validate?

But how can I link it to the Validate email validation?

Thanks,
Miguel

On Nov 15, 2:21 pm, Alexsandro_xpt <[EMAIL PROTECTED]> wrote:
> And about form submit before to validate e-mail field?
>
> Do you know something about that?
>
> Thanks
> Alexsandro
>
> On 13 nov, 14:00, "Jörn Zaefferer" <[EMAIL PROTECTED]>
> wrote:
>
> > The plugin doesn't support that. As a workaround, you can use jQuery's
> > ajaxSend callback to add additional data to the 
> > request:http://docs.jquery.com/Ajax/ajaxSend#callback
>
> > Jörn
>
> > On Thu, Nov 13, 2008 at 3:35 PM, shapper <[EMAIL PROTECTED]> wrote:
>
> > > Hello,
>
> > > I am using the following to validate an email field:
>
> > > Email: { email: true, remote: "/Account/FindEmail", required: true }
>
> > > I am checking if there is already an account with that email.
>
> > > In my form I also have an input where the user inserts its username.
> > > When validating the email I need to send also the Username an not only
> > > the email.
>
> > > Can I do this?
>
> > > Thanks,
> > > Miguel


[jQuery] Re: select a div with a specific value

2008-11-15 Thread CodingCyborg

http://docs.jquery.com/Selectors/attributeEquals#attributevalue

On Nov 15, 6:11 pm, "Alfredo Alessandrini" <[EMAIL PROTECTED]>
wrote:
> I've a html page like this:
>
> 
>     value="b4"/>
>     value="c4"/>
>     value="d4"/>
>     value="e4"/>
> 
>
> Can I select a div by the value??
>
> $(".chess-board value='b4'")
>
> Thanks,
>
> Alfredo


[jQuery] select a div with a specific value

2008-11-15 Thread Alfredo Alessandrini

I've a html page like this:


   
   
   
   


Can I select a div by the value??

$(".chess-board value='b4'")




Thanks,

Alfredo


[jQuery] Re: add property name via a variable

2008-11-15 Thread Theodore Ni
Something like this would work:

foo("bar");

function foo(prop) {
window[prop] = 1;
}

Ted


On Sat, Nov 15, 2008 at 1:24 PM, Johnnie Walker <[EMAIL PROTECTED]> wrote:

>
> Hi,
>
> Is there any way to add a property named via a variable to a
> javascript object?
>
> this is what I would like to do:
>
> 
>
> foo(bar);
>
> function foo(x)
> {
>window.x = 1;
> }
> --
>
> so that the object window will end up with a property called bar. i.e.
> window.bar==1
>
> Any ideas?
>
> John.
>


[jQuery] Re: add property name via a variable

2008-11-15 Thread klkmva

Something like :

--
function foo(x)
{
   window[x] = 1;
}

foo('bar');
alert(window.bar);




On 15 nov, 19:24, Johnnie Walker <[EMAIL PROTECTED]> wrote:
> Hi,
>
> Is there any way to add a property named via a variable to a
> javascript object?
>
> this is what I would like to do:
>
> 
>
> foo(bar);
>
> function foo(x)
> {
>     window.x = 1;}
>
> --
>
> so that the object window will end up with a property called bar. i.e.
> window.bar==1
>
> Any ideas?
>
> John.


[jQuery] help with jquery add/remove class

2008-11-15 Thread bjreed

Hello.  I am new to JQuery, and I thought I'd try creating a small app
to learn more.  I've hit a problem that I cannot seem to fix.   I have
a right navigation bar with 8 floor plan links.  When you click one,
the accordian menu drops and shows some details (this works great),
the other thing that is suppose to happen on click is a large image is
to appear in the left area.  You'll see that it works fine at first,
BUT when you start clicking down the list AND then try and return to
an earlier click, is when the problem occurs.  It seems there is
problem removing the classes that have already been called.

I know that there is probably an easy solution, but I have not found
it yet.  I'd appreciate any advice.  Thanks

You can view it at http://jquery.pixeltrails.com/
All the script is on the default.htm source page.  Add/Remove class
script is at the bottom of the source.


[jQuery] Confirming submit using Validate plugin

2008-11-15 Thread flycast

I have a long form where some of the fields are required. The problem
is that the user is sometimes getting to the point where they have
filled all the required fields in but is not done and then hits enter
rather than tab to go to the next field. When they do this the form
submits. I want to conform that the user really wants to submit when
they hit enter.

This does not work:

function confSubmit(form) {
if (confirm("Are you sure you want to submit the form?")) {
   $("#employmentForm").submit();
}
}//End of confSubmit function

I get a popup corectly but if I hit cancel on the confirm dialog then
the form validates/submits anyway rather than returning to the form.


[jQuery] Re: "this" and z-index changes

2008-11-15 Thread CodingCyborg

Would it be plausible to create a custom tag of  ? I
think part of the problem is because all of the windows have 2
classes. One is the .draggableWindow the other defines the group they
are in. With a custom tag it would allow for each to have one class.

On Nov 14, 3:02 pm, CodingCyborg <[EMAIL PROTECTED]> wrote:
> http://arkaydea.com/zIndexTest.php
>
> That is the closest thing I can get to the real thing.
>
> On Nov 14, 12:38 pm, ricardobeat <[EMAIL PROTECTED]> wrote:
>
> > Right. This is getting a bit complex. Judging by your code things
> > should be going well, could you put up a test page?
>
> > the global vars suggestion was a shot in the dark, if you a run loop
> > they will be overwritten for every iteration unless the assignment
> > doesn't execute.
>
> > On Nov 14, 2:23 pm, CodingCyborg <[EMAIL PROTECTED]> wrote:
>
> > > I have confirmed that when one of a group of windows is clicked, it
> > > runs as if every window in that group was clicked at the same time and
> > > runs the code for each of them.
>
> > > This causes quite an awkward outcome, but I have no idea why its
> > > happening, nor how to stop it.
>
> > > On Nov 14, 9:03 am, ricardobeat <[EMAIL PROTECTED]> wrote:
>
> > > > I haven't looked througly at your code, but I see you're using global
> > > > variables, that might be an issue:
>
> > > > $('.draggableWindow').mousedown(function(){
> > > >                 var numWindows=$('.draggableWindow').length + 500;
> > > >                 var zindexIt2 = parseInt($(this).css("z-index"));
> > > >                 if(zindexIt2 < numWindows){
> > > >                         $(this).css("z-index",numWindows);
> > > >                         $('.draggableWindow').each(function(){
> > > >                             var newZ2=$(this).css("z-index");
> > > >                             if(newZ2 > zindexIt2){ //being greater
> > > > doesn't mean it's only 1 unit greater
> > > >                                 newZ2 = zindexlt2-2; //just to be safe
> > > >                                 $(this).css("z-index",newZ2);
> > > >                                 $(this).children('h1').text(parseInt($
> > > > (this).css("z-index")));
> > > >                             }
> > > >                         });
> > > >                 }
> > > >         });
>
> > > > On Nov 14, 11:13 am, CodingCyborg <[EMAIL PROTECTED]> wrote:
>
> > > > >         jQuery('.draggableWindow').mousedown(function(){
> > > > >                 numWindows=jQuery('.draggableWindow').size() + 500;
> > > > >                 zindexIt2 = parseInt($(this).css("z-index"));
> > > > >                 if(zindexIt2 < numWindows){
> > > > >                         $(this).css("z-index",numWindows);
> > > > >                         $('.draggableWindow').each(function(){
> > > > >                             newZ2=$(this).css("z-index");
> > > > >                             if(newZ2 > zindexIt2){
> > > > >                                 newZ2--;
> > > > >                                 $(this).css("z-index",newZ2);
> > > > >                                 
> > > > > $(this).children('h1').text(parseInt($(this).css("z-index")));
> > > > >                             }
> > > > >                         });
> > > > >                 }
> > > > >         });
>
> > > > > I added a line so I could watch the z-index movements of the draggable
> > > > > windows. I found that they are all on separate layers but for some
> > > > > reason instead of each of them above the one you bring to front
> > > > > dropping one, some will drop two while others don't move. I'm not sure
> > > > > why this is happening, it's almost as if some windows are run through
> > > > > the .each() multiple times while others don't move. Or when others go
> > > > > through it they affect the first one through it.
>
> > > > > Help would be highly appreciated!
>
> > > > > On Nov 13, 1:08 pm, CodingCyborg <[EMAIL PROTECTED]> wrote:
>
> > > > > > I recently have been playing around with a "Desktop" module that was
> > > > > > on nettuts and made a modification for it that doesn't fully work.
> > > > > > There are many draggable windows, and in order for them to function
> > > > > > like a real desktop they need to have z-index changes such that if 
> > > > > > you
> > > > > > close one on top the last one you had on top is right below it.
>
> > > > > > I believe my error comes in with "this" or possibly something else,
> > > > > > but when you pull one to the front it causes some or all of the 
> > > > > > others
> > > > > > to end up in the same z-index causing them to not stay in order of
> > > > > > recently viewed.
>
> > > > > >         jQuery('.draggableWindow').mousedown(function(){
> > > > > >                 numWindows=jQuery('.draggableWindow').size() + 
> > > > > > 500;//the + 500 is to
> > > > > > make sure they are above other objects on the page
> > > > > >                 zindexIt2 = parseInt($(this).css("z-index"));
> > > > > >                 if(zindexIt2 < numWindows

[jQuery] Re: Modernized Portlets?

2008-11-15 Thread Karl Swedberg

Hey Shawn,

There is a rudimentary one in the jQuery UI demos:

http://ui.jquery.com/repository/real-world/layout/

--Karl


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




On Nov 15, 2008, at 5:31 PM, Shawn Grover wrote:



I found the jQuery Portlets at http://sonspring.com/journal/jquery-portlets 
.  This appears to be outdated (makes use of the interface library  
for the sortables rather than ui.jquery...).  Does anyone know if  
there is a more current version of this?  And one that doesn't  
necessarily depend on tables would be nice too...


If there isn't one, I guess I'll have to update it...  A customer  
wants this sort of functionality


Thanks for any tips...

Shawn




[jQuery] Modernized Portlets?

2008-11-15 Thread Shawn Grover


I found the jQuery Portlets at 
http://sonspring.com/journal/jquery-portlets.  This appears to be 
outdated (makes use of the interface library for the sortables rather 
than ui.jquery...).  Does anyone know if there is a more current version 
of this?  And one that doesn't necessarily depend on tables would be 
nice too...


If there isn't one, I guess I'll have to update it...  A customer wants 
this sort of functionality


Thanks for any tips...

Shawn


[jQuery] Re: A "real" modal window... is it possible?

2008-11-15 Thread Berke

Doesn't this work?

if (IsDefined(window.showModalDialog))
{
//Handles IE6 & 7
retVal= window.showModalDialog(sPage,argsArr, sFeatures);
}
else
{
   //Handles Firefox
retVal=window.open(sPage,sFeatures+"modal=yes");
}

Then in the window you can set:

window.returnValue=something;




[jQuery] safari & chrome form plugin problem

2008-11-15 Thread led

My question is if someone report prroblems with form plugin  and the
ajaxsubmit?
Don't work on both.


[jQuery] add property name via a variable

2008-11-15 Thread Johnnie Walker

Hi,

Is there any way to add a property named via a variable to a
javascript object?

this is what I would like to do:



foo(bar);

function foo(x)
{
window.x = 1;
}
--

so that the object window will end up with a property called bar. i.e.
window.bar==1

Any ideas?

John.


[jQuery] Re: A "real" modal window... is it possible?

2008-11-15 Thread Berke

Sorry if this is a double post but the first time it gave me an error,

This should work for you and creates a real Modal now if your looking
for one of the fancier modals that are not actually windows use the
callbacks like they described.

if (IsDefined(window.showModalDialog))
{

retVal= window.showModalDialog(sPage,argsArr, sFeatures);
}
else
{
retVal=window.open(sPage,sFeatures+"modal=yes");
}

When close the window do window.returnValue=somethign; so you can get
the return value.

josh


[jQuery] [HOWTO] Rewrite my own library functions to jQuery?

2008-11-15 Thread Fluffy Convict

I have a lot of little functions I use on my website, like these. Is
there a standard way how I should rewrite them to jQuery? Could
somebody give me an example with one of these functions to go by,
using best practices? Your help would be greatly appreciated!

function select_goto(obj, base_url) {
  var selected = obj.options[obj.selectedIndex].value, url = '';
  url = (selected == 'ignore') ? base_url : base_url + '?type=' +
selected;
  document.location.href = BASE_HREF + url;
}

function limitChars(obj) {
  obj.value = obj.value.replace(/[^-a-z0-9_]/ig,'');
  obj.value = obj.value.toLowerCase();
}

function arg(index) {
  var url = String(document.location).split("//");
  var pad = url[1].split("?");
  var arg = pad[0].split("/");
  return arg[index];
}


[jQuery] Double label issue in IE

2008-11-15 Thread bmclaughlin

Hello,
I was investigating show/hide features with form elements and found
this one by Scott Jehl the ever impressive Filament Group folks:
http://www.alistapart.com/d/testprogressiveenhancement/demos/demo3.html

At the bottom of the sample is an example of what I am looking
forthe Dog/Cat item.

Does anyone know why, or how to stop what appears to be a doubling of
the label that is revealed when it's parent is selected?
It only happens in IE 6/7 on a Windows machine.


Thanks


[jQuery] Re: livequery not binding to ajax loaded links in ie6 and ie7?

2008-11-15 Thread n00bert

Got it sorted. ie doesn't like the selector. Now using a different
method, but still with livequery. Sorry to have bothered you Brandon,
and thanks for such a powerful plugin.

Sameer

On Nov 14, 9:50 pm, n00bert <[EMAIL PROTECTED]> wrote:
> Hi Brandon,
>
> I've tried changing this code:
>
> $('#mainMenu ul li ul li a[href$="' + href + '"]').triggerHandler
> ('click');
>
> to:
>
> $('#mainMenu ul li ul li a:first').triggerHandler('click');
>
> in order to see if it was the selector that's causing the problem. It
> seems it is. The second line of code works as expected in ie6 and ie7.
>
> Is there another way of selecting a link with a href that matches the
> clicked link's href?
>
> Thanks,
>
> Sameer
>
> On Nov 14, 3:31 pm, n00bert <[EMAIL PROTECTED]> wrote:
>
> > Hi Brandon,
>
> > no errors in ie at all. I've uploaded the site I'm working on 
> > athttp://rosiespencer.co.ukWhenit loads, click a small thumb. The menu
> > should slide down and the contents of #content are replaced via ajax.
> > Some larger thumbs appear. This is where it breaks in ie. In other
> > browsers if you click one of the bigger thumbs, #content is replaced
> > as expected.
>
> > Thanks again for your help,
>
> > Sameer
>
> > On Nov 14, 2:23 pm, "Brandon Aaron" <[EMAIL PROTECTED]> wrote:
>
> > > On Thu, Nov 13, 2008 at 10:26 PM, n00bert <[EMAIL PROTECTED]> wrote:
>
> > > > Hi Brandon,
>
> > > > I put an alert in like so:
>
> > > > $('#content div.thumb a').livequery('click', function(e) {
> > > >         alert ('clicked');
> > > >         e.preventDefault();
> > > >        var href = $(this).attr('href');
> > > >        $('#mainMenu ul li ul li a[href$="' + href + '"]').triggerHandler
> > > > ('click');
> > > >        return false;
> > > > });
>
> > > > Safari, Firefox and Opera all show the alert when clicked. ie6 and ie7
> > > > do not. In firebug, there are no errors. Any clues?
>
> > > But are there any errors in IE?
>
> > > --
> > > Brandon Aaron


[jQuery] newbie jquery.load help wanted!

2008-11-15 Thread bumblebean

HI. I'm really new to jquery, and PHP for that matter. I'm trying to
complete a school assignment, and I'm s stuck. What I'm trying to
do is submit form data through jquery to a php page. The php works as
intended when called outside of jquery. It basically takes some POST
values, and writes them to a database. It's then supposed to return a
string which lets a user know the result of the attempt. All I want to
do is load the resulting string into a div on my form page.

However, in the way I'm calling it from Jquery, I'm doing something
wrong, since all I'm getting back in my alert message is a huge pop up
with the entire contents of the PHP page. It's never actually
processing. Here's my jquery call (the one letter variables are
derived from my validation script. These also hold the correct
values):

***
 $.post("bin/uploadstory.php",
   {heading: h, story: s, urllink: u, image: p,
category: c},
   function(data){
   alert("Data Loaded: " + data);
});
***

and here's my php page, bin/uploadstory.php (this is the full code on
this page).

***



[jQuery] Re: jeditable, tablesorter work slow with livequery

2008-11-15 Thread tomek_swat


anyone has some idea?
thx
-- 
View this message in context: 
http://www.nabble.com/jeditable%2C-tablesorter-work-slow-with-livequery-tp20223996s27240p20518608.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.



[jQuery] Re: Why is img_width always 0 (zero)?

2008-11-15 Thread ricardobeat

If the image has no width set in CSS, it will equal 0. That happens
because when ready() fires the image hasn't been loaded yet, so the
browser has no idea of it's size. In this case you have to use the
onload event.

- ricardo

On Nov 15, 11:59 am, Fluffy Convict <[EMAIL PROTECTED]>
wrote:
> I'm rewriting my own js library to jquery functions. A huge
> undertaking, but hopefully worth it in the future :) Question: why
> does the script always return 0 for img_width? Logo.gif exists and
> moving the code to the end of the page (before the closing body-tag)
> doesn't help either. Any help would be greatly appreciated!
>
>   
>   
>     
>     
>     $(document).ready(function(){
>       $("img.caption").each(function(i) {
>         var img_width = $(this).width();
>         var img_title = $(this).attr('title');
>         var img_align = $(this).attr('align');
>         $(this).wrap("
\"float:" + img_align + "\">
"); >         $(this).parent().width(img_width); >         $(this).parent().append("
" + > img_title + "
"); >       }); >     }); >     >   >   >     >   >  

[jQuery] Re: image toggle

2008-11-15 Thread ricardobeat

The jQuery object has no 'src' property, use attr() to get the
element's attributes, and you can only pass a single function to click
():

$('#my_header').click(function(){
   var $img = $(this).find('img');
   var src = $img.attr('src');
   var newsrc = /up\.gif$/.test(src) ? src.replace('up','down') :
src.replace('down','up');
   $img.attr('src',newsrc);
});

- ricardo

On Nov 15, 12:15 am, bob <[EMAIL PROTECTED]> wrote:
> Hi,
> I am trying to create a toggler that I would like to work
> as follows:
> User clicks on #my_header and source of the image gets replaced.
> I tried the following but it did not work.
>
> 
>         
>         Some title here
> 
>
> $(function() {
>         $('#my_header').click(
>             function() {
>                                 $('#my_header img').src = $('#my_header 
> img').src.replace( /_down
> \.gif$/, '_up.gif' );
>             },
>             function() {
>                                 $('#my_header img').src = $('#my_header 
> img').src.replace( /_up
> \.gif$/, '_down.gif' );
>             }
>         );
>
> });


[jQuery] Re: A "real" modal window... is it possible?

2008-11-15 Thread Wagner

thank you all for the answers... basically I will have to work with
the callbacks! ;-)

On Nov 15, 3:31 pm, Wagner <[EMAIL PROTECTED]> wrote:
> Hey friends... of course when I say about stop the flow of code, I
> mean to stop the flow of code that called the window, the flow would
> be passed to the window being drawn, the internal events of window,
> etc, etc,  when I close the window, the flow should go back to the
> point that called the modal window... like "call a function"
>
> ex:
>
> var a = 2;
> var b = a + 2;
> CallWindow();
> // I don't want etc() to be executed until I close the window :-)
> etc();
> etc2();
> c = a + b;
> etc...
>
> On Nov 15, 1:22 am, Brice Burgess <[EMAIL PROTECTED]> wrote:
>
> > Wagner,
>
> >   Javascript's flow is single threaded, and a delay in execution (I/O
> > starvation) will halt the entire script including timeouts and
> > intervals. As such, timeouts and intervals are "kind of asynchronous",
> > in that the script hypervisor is polling for these each "tick", and
> > will direct program flow into them when encountered.
>
> >   Shawn is correct in that limiting execution to the modal window is
> > an architecture / program structure issue. jqModal (when in "modal"
> > mode) assigns a global event handler that examines the source of the
> > event, and stops it from propogating (and calling any other attached
> > event) if it occurs OUTSIDE the modal dialog. This mimick's modal
> > behavior -- but will NOT halt the execution setTimeout/Interval and
> > ajax handling. To halt these processes, you could examine the state of
> > the modal dialog in the handling function, and return false if it is
> > "open". E.g.
>
> > -- handling function --
> > if ($('#modalDialog').is(':visible')
> >   return false; // handle not!
>
> > // handle ho!
> > ...
> > -- !handling function --
>
> > Hope this helps,
>
> > ~ Brice
>
> > On Nov 14, 8:42 pm, Shawn Grover <[EMAIL PROTECTED]> wrote:
>
> > > This is a coding approach issue, rather than a modal window issue.  To
> > > me at least.
>
> > > When I needed behavior like this, I wrote my code in such a way that a
> > > function was called that set up the environment and then opened the
> > > modal window.  Now that the modal window is open, I know that nothing
> > > else should be receiving events, so there is no code to execute other
> > > than for the modal stuff specifically.  Now when the window is closed, I
> > > call the appropriate function (cancel, save, etc) and continue
> > > processing from there.  In this way, my processing has "stopped" until
> > > the Modal window triggers the next part of processing.
>
> > > Of course, this is not the answer for all cases.  But, working in an
> > > asynchronous and event driven environment, this tends to work well enough.
>
> > > To acheive what you are asking for would be possible if you were working
> > > in a synchronous or procedural environment.  But that doesn't describe a
> > > web page per se
>
> > > My thoughts...
>
> > > Shawn
>
> > > Richard D. Worth wrote:
> > > > What I mean to say is, a modal isn't about stopping flow of code. It's
> > > > about restricting interaction to a certain set of elements, until the
> > > > interaction is complete. So it allows interaction with elements in that
> > > > modal (requiring code flow - remember javascript is single-threaded),
> > > > preventing interaction with all others, until it's closed.
>
> > > > If you're wanting to call a modal like a function and have it return a
> > > > value (think confirmation dialog), it won't work to block like that. An
> > > > alternative pattern is to provide a callback function that will resume
> > > > execution after the modal is closed.
>
> > > > - Richard
>
> > > > On Fri, Nov 14, 2008 at 4:48 PM, Eric Martin <[EMAIL PROTECTED]
> > > > > wrote:
>
> > > >     I guess it depends on what you mean by "flow of code must STOP".
>
> > > >     On Nov 14, 12:11 pm, Wagner <[EMAIL PROTECTED]
> > > >     > wrote:
> > > >      > Is it possible to make a window like jqModal, etc, etc,  BUT 
> > > > WITH A
> > > >      > REAL MODAL way of work?
>
> > > >      > I mean the flow of code must STOP until the window be closed!
> > > >     Does
> > > >      > it exist?


[jQuery] Re: A "real" modal window... is it possible?

2008-11-15 Thread Wagner

Hey friends... of course when I say about stop the flow of code, I
mean to stop the flow of code that called the window, the flow would
be passed to the window being drawn, the internal events of window,
etc, etc,  when I close the window, the flow should go back to the
point that called the modal window... like "call a function"

ex:

var a = 2;
var b = a + 2;
CallWindow();
// I don't want etc() to be executed until I close the window :-)
etc();
etc2();
c = a + b;
etc...


On Nov 15, 1:22 am, Brice Burgess <[EMAIL PROTECTED]> wrote:
> Wagner,
>
>   Javascript's flow is single threaded, and a delay in execution (I/O
> starvation) will halt the entire script including timeouts and
> intervals. As such, timeouts and intervals are "kind of asynchronous",
> in that the script hypervisor is polling for these each "tick", and
> will direct program flow into them when encountered.
>
>   Shawn is correct in that limiting execution to the modal window is
> an architecture / program structure issue. jqModal (when in "modal"
> mode) assigns a global event handler that examines the source of the
> event, and stops it from propogating (and calling any other attached
> event) if it occurs OUTSIDE the modal dialog. This mimick's modal
> behavior -- but will NOT halt the execution setTimeout/Interval and
> ajax handling. To halt these processes, you could examine the state of
> the modal dialog in the handling function, and return false if it is
> "open". E.g.
>
> -- handling function --
> if ($('#modalDialog').is(':visible')
>   return false; // handle not!
>
> // handle ho!
> ...
> -- !handling function --
>
> Hope this helps,
>
> ~ Brice
>
> On Nov 14, 8:42 pm, Shawn Grover <[EMAIL PROTECTED]> wrote:
>
> > This is a coding approach issue, rather than a modal window issue.  To
> > me at least.
>
> > When I needed behavior like this, I wrote my code in such a way that a
> > function was called that set up the environment and then opened the
> > modal window.  Now that the modal window is open, I know that nothing
> > else should be receiving events, so there is no code to execute other
> > than for the modal stuff specifically.  Now when the window is closed, I
> > call the appropriate function (cancel, save, etc) and continue
> > processing from there.  In this way, my processing has "stopped" until
> > the Modal window triggers the next part of processing.
>
> > Of course, this is not the answer for all cases.  But, working in an
> > asynchronous and event driven environment, this tends to work well enough.
>
> > To acheive what you are asking for would be possible if you were working
> > in a synchronous or procedural environment.  But that doesn't describe a
> > web page per se
>
> > My thoughts...
>
> > Shawn
>
> > Richard D. Worth wrote:
> > > What I mean to say is, a modal isn't about stopping flow of code. It's
> > > about restricting interaction to a certain set of elements, until the
> > > interaction is complete. So it allows interaction with elements in that
> > > modal (requiring code flow - remember javascript is single-threaded),
> > > preventing interaction with all others, until it's closed.
>
> > > If you're wanting to call a modal like a function and have it return a
> > > value (think confirmation dialog), it won't work to block like that. An
> > > alternative pattern is to provide a callback function that will resume
> > > execution after the modal is closed.
>
> > > - Richard
>
> > > On Fri, Nov 14, 2008 at 4:48 PM, Eric Martin <[EMAIL PROTECTED]
> > > > wrote:
>
> > >     I guess it depends on what you mean by "flow of code must STOP".
>
> > >     On Nov 14, 12:11 pm, Wagner <[EMAIL PROTECTED]
> > >     > wrote:
> > >      > Is it possible to make a window like jqModal, etc, etc,  BUT WITH A
> > >      > REAL MODAL way of work?
>
> > >      > I mean the flow of code must STOP until the window be closed!
> > >     Does
> > >      > it exist?


[jQuery] Re: Why is "width" always zero?

2008-11-15 Thread Fluffy Convict

Thanks, setting the width explicitly helps. I am disappointed, though.
Is there a way to read an image's width even without it being set
explicitly?

Secondly, I have a lot of little functions I use on my website, like
these. Is there a way how I should rewrite them to jQuery?

function select_goto(obj, base_url) {
  var selected = obj.options[obj.selectedIndex].value, url = '';
  url = (selected == 'ignore') ? base_url : base_url + '?type=' +
selected;
  document.location.href = BASE_HREF + url;
}

function limitChars(obj) {
  obj.value = obj.value.replace(/[^-a-z0-9_]/ig,'');
  obj.value = obj.value.toLowerCase();
}

function arg(index) {
  var url = String(document.location).split("//");
  var pad = url[1].split("?");
  var arg = pad[0].split("/");

  return arg[index];
}

On 15 nov, 17:50, Karl Swedberg <[EMAIL PROTECTED]> wrote:
> could be that the images aren't finished loading by the time you're  
> trying to get their width. Maybe putting your script inside a window  
> load rather than document ready would help. I'm guessing, too, that  
> the images don't have a width and height attribute explicitly set in  
> the html.
>
>   $(window).bind('load', function() {
>     // your code ...
>
> });
>
> --Karl
>
> 
> Karl Swedbergwww.englishrules.comwww.learningjquery.com
>
> On Nov 15, 2008, at 8:55 AM, Fluffy Convict wrote:
>
>
>
> > I'm rewriting my own javascript library to jQuery. A huge undertaking,
> > but hopefully it will payoff in the future :) Anyways - I'm trying to
> > write a function that takes the title-attribute of an image and
> > inserts is as a caption:
>
> >  
> >  
> >    
> >    
> >    $(document).ready(function(){
> >      $("img.caption").each(function(i) {
> >        var img_width = $(this).width();
> >        var img_title = $(this).attr('title');
> >        var img_align = $(this).attr('align');
> >        $(this).wrap("
> \"float:" + img_align + "\">
"); > >        $(this).parent().width(img_width); > >        $(this).parent().append("
" + > > img_title + "
"); > >      }); > >    }); > >     > >   > >   > >     > >   > >   > > > But img_width is zero (and logo.gif exists). Moving my script to the > > bottom of the page (before the closing body-tag) makes no difference. > > Any suggestions?

[jQuery] Re: Why is "width" always zero?

2008-11-15 Thread Karl Swedberg
could be that the images aren't finished loading by the time you're  
trying to get their width. Maybe putting your script inside a window  
load rather than document ready would help. I'm guessing, too, that  
the images don't have a width and height attribute explicitly set in  
the html.


 $(window).bind('load', function() {
   // your code ...
});


--Karl


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




On Nov 15, 2008, at 8:55 AM, Fluffy Convict wrote:



I'm rewriting my own javascript library to jQuery. A huge undertaking,
but hopefully it will payoff in the future :) Anyways - I'm trying to
write a function that takes the title-attribute of an image and
inserts is as a caption:

 
 
   
   
   $(document).ready(function(){
 $("img.caption").each(function(i) {
   var img_width = $(this).width();
   var img_title = $(this).attr('title');
   var img_align = $(this).attr('align');
   $(this).wrap("
"); $(this).parent().width(img_width); $(this).parent().append("
" + img_title + "
"); }); }); But img_width is zero (and logo.gif exists). Moving my script to the bottom of the page (before the closing body-tag) makes no difference. Any suggestions?

[jQuery] Why does img_width always return 0 (zero)?

2008-11-15 Thread Fluffy Convict

I'm rewriting my own js library to jquery functions. A huge
undertaking, but hopefully worth it in the future :) Question: why
does the script always return 0 for img_width? Logo.gif exists and
moving the code to the end of the page (before the closing body-tag)
doesn't help either. Any help would be greatly appreciated!

My apologies is this message appears twice now. After 15 mins my first
post still did not appear in the list, so I image something went
wrong...


  
  


$(document).ready(function(){
  $("img.caption").each(function(i) {
var img_width = $(this).width();
var img_title = $(this).attr('title');
var img_align = $(this).attr('align');
$(this).wrap("
"); $(this).parent().width(img_width); $(this).parent().append("
" + img_title + "
"); }); });

[jQuery] Re: Identifying the tag

2008-11-15 Thread donb

$(this).attr('tagName') or more simply, this.tagName.


On Nov 15, 9:27 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> Let's say we have the following set up where doSomething is a function:
>
> $("h1, h2, h3").doSomething();
>
> How can one identify which tag is currently having something done to it?
>
> Thanks


[jQuery] Why does img_width always return 0 (zero)?

2008-11-15 Thread Fluffy Convict

I'm rewriting my own js library to jquery functions. A huge
undertaking, but hopefully worth it in the future :) Question: why
does the script always return 0 for img_width? Logo.gif exists and
moving the code to the end of the page (before the closing body-tag)
doesn't help either. Any help would be greatly appreciated!

My apologies is this message appears twice now. After 15 mins my first
post still did not appear in the list, so I image something went
wrong...


  
  


$(document).ready(function(){
  $("img.caption").each(function(i) {
var img_width = $(this).width();
var img_title = $(this).attr('title');
var img_align = $(this).attr('align');
$(this).wrap("
"); $(this).parent().width(img_width); $(this).parent().append("
" + img_title + "
"); }); });

[jQuery] Why is img_width always 0 (zero)?

2008-11-15 Thread Fluffy Convict

I'm rewriting my own js library to jquery functions. A huge
undertaking, but hopefully worth it in the future :) Question: why
does the script always return 0 for img_width? Logo.gif exists and
moving the code to the end of the page (before the closing body-tag)
doesn't help either. Any help would be greatly appreciated!

  
  


$(document).ready(function(){
  $("img.caption").each(function(i) {
var img_width = $(this).width();
var img_title = $(this).attr('title');
var img_align = $(this).attr('align');
$(this).wrap("
"); $(this).parent().width(img_width); $(this).parent().append("
" + img_title + "
"); }); });

[jQuery] Why is "width" always zero?

2008-11-15 Thread Fluffy Convict

I'm rewriting my own javascript library to jQuery. A huge undertaking,
but hopefully it will payoff in the future :) Anyways - I'm trying to
write a function that takes the title-attribute of an image and
inserts is as a caption:

  
  


$(document).ready(function(){
  $("img.caption").each(function(i) {
var img_width = $(this).width();
var img_title = $(this).attr('title');
var img_align = $(this).attr('align');
$(this).wrap("
"); $(this).parent().width(img_width); $(this).parent().append("
" + img_title + "
"); }); }); But img_width is zero (and logo.gif exists). Moving my script to the bottom of the page (before the closing body-tag) makes no difference. Any suggestions?

[jQuery] Re: Need JQuery guidence

2008-11-15 Thread CodingCyborg

http://codingcyb.org/jQueryFun/Robot/robotHumor.html

http://codingcyb.org/jQueryFun/Robot/js/humor.js

Its pretty simple, and shows a fun application.

On Nov 15, 8:47 am, "bharani kumar" <[EMAIL PROTECTED]>
wrote:
> Hi Dear Friends
>
> I am new to jquery program, ya i already did small snipets in jquery, but am
> not expert ,
>
> I very much intrested to learn Jquery from start point
>
> Ya i Read some tutorial like jquery.com,
>
> But i am basically very much intrested in discussions,
>
> Can any one tell me and send me , sample snipet
>
> That please write small (Basic) Jquery program and send to me,
>
> Please dont redirect to some site likewww.jquery.com
>
> Because i already visited that sites and all, good tutorial with example ,
>
> But i expect more then that ,
>
> Thank you
>
> --
> உங்கள் நண்பன்
> பரணி  குமார்
>
> Regards
> B.S.Bharanikumar
>
> POST YOUR OPINIONhttp://bharanikumariyer.hyperphp.com/


[jQuery] Re: has anyone come across a plugin like this ?

2008-11-15 Thread Pixelstuff

I am curious about what is running the forums on Biocompare. Vanilla
maybe? It's so nice to see forums that are fully integrated into a
site rather than the commonly seen implmentations of SMF, phpBB, and
vBulletin.



On Nov 15, 8:03 am, Gildas <[EMAIL PROTECTED]> wrote:
> Take a look at MonoRail if you don't already know it ;-)
>
> http://castleproject.org/
>
> On Nov 13, 7:28 pm, heysatan <[EMAIL PROTECTED]> wrote:
>
> > Sean,
>
> > Thanks!  I really feel that's how web 2.0 should be used, minimally
> > and usefully.  I'll start working on the plugin next week, I'll try
> > and have a beta version up by the end of november.
>
> > We were working within .NET which made it hard to implement some of
> > the things I wanted to.  The sign in/registration popups ended up
> > being iframes because of the whole .NET validation model, I would have
> > made them pure ajax if possible.  Not to sound down too down on .NET
> > (well, I am a little down on it), but we could have done more in a
> > less "framework" based web environment (PHP or Ruby).
>
> > Also, I have been a flash developer for a while, and doing this
> > project made me fall for jQuery.  I can't wait to use some of my code
> > based flash animation background to build a full jQuery (flash like)
> > site for fun.
>
> > Jason
>
> > On Nov 12, 4:04 am, CliffordSean <[EMAIL PROTECTED]> wrote:
>
> > > hi Jason
>
> > > what luck - i get to speak to the person that actually built the thing !
>
> > > you guys did some amazing work on that biocompare site i must say - i came
> > > across it just by chance but am happy i did as its a great example of a 
> > > real
> > > simple web2.0 implementation and some near jquery work.
>
> > > id say that plugin would be a real hit ! so please do if you have some 
> > > time
> > > please do make it available!
>
> > > thanks alot
> > > sean
>
> > > heysatan wrote:
>
> > > > Hi Sean,
>
> > > > I built this breadcrumb animation.  Due to time limitations at the end
> > > > of the project I wasn't able to make it into a plugin (I built a lot
> > > > of other plugins for this project), but I'd like to when I get a
> > > > chance.
>
> > > > I really solved a problem for us because our category and page titles
> > > > are so long (scientists are long winded).  Before we would show only a
> > > > couple of steps in the HTML to get around this.  This method was more
> > > > SEO friendly, more usable, and I thought, kind of cool.
>
> > > > If there is a demand for it I'll work on porting it to a plugin, but
> > > > probably not for the next 2 weeks or so.
>
> > > > Jason
> > > > Lead UI Developer - CompareNetworks
>
> > > --
> > > View this message in 
> > > context:http://www.nabble.com/has-anyone-come-across-a-plugin-like-this---tp2...
> > > Sent from the jQuery General Discussion mailing list archive at 
> > > Nabble.com.


[jQuery] Re: issue with jQuery's trigger function

2008-11-15 Thread Dave Methvin

> After running the Webkit javascript debugger, I was able to trace it to the
> trigger function in jQuery:
>
> line #2041: elem[ type ]();

That's where it's calling the native handler for that element. I guess
prototype.js must hook into the native event handling and that causes
it to trigger. jQuery has a .triggerHandler() method that is
like .trigger() but it doesn't fire the native handler. Does that
work? Let us know.

http://docs.jquery.com/Events/triggerHandler#typedata


[jQuery] Re: Identifying the tag

2008-11-15 Thread Dave Methvin

> $("h1, h2, h3").doSomething();
> How can one identify which tag is currently having something done to it?

Try  the tagName property of the DOM element:

$("h1, h2, h3").each(function(){
  alert(this.tagName);
});


[jQuery] Need JQuery guidence

2008-11-15 Thread bharani kumar
Hi Dear Friends


I am new to jquery program, ya i already did small snipets in jquery, but am
not expert ,

I very much intrested to learn Jquery from start point

Ya i Read some tutorial like jquery.com,

But i am basically very much intrested in discussions,

Can any one tell me and send me , sample snipet

That please write small (Basic) Jquery program and send to me,


Please dont redirect to some site like www.jquery.com

Because i already visited that sites and all, good tutorial with example ,

But i expect more then that ,

Thank you


-- 
உங்கள் நண்பன்
பரணி  குமார்

Regards
B.S.Bharanikumar

POST YOUR OPINION
http://bharanikumariyer.hyperphp.com/


[jQuery] Identifying the tag

2008-11-15 Thread [EMAIL PROTECTED]

Hi All,

Let's say we have the following set up where doSomething is a function:

$("h1, h2, h3").doSomething();

How can one identify which tag is currently having something done to it?

Thanks



[jQuery] Re: Validate. Can I validate using 2 values?

2008-11-15 Thread Alexsandro_xpt

And about form submit before to validate e-mail field?

Do you know something about that?


Thanks
Alexsandro

On 13 nov, 14:00, "Jörn Zaefferer" <[EMAIL PROTECTED]>
wrote:
> The plugin doesn't support that. As a workaround, you can use jQuery's
> ajaxSend callback to add additional data to the 
> request:http://docs.jquery.com/Ajax/ajaxSend#callback
>
> Jörn
>
> On Thu, Nov 13, 2008 at 3:35 PM, shapper <[EMAIL PROTECTED]> wrote:
>
> > Hello,
>
> > I am using the following to validate an email field:
>
> > Email: { email: true, remote: "/Account/FindEmail", required: true }
>
> > I am checking if there is already an account with that email.
>
> > In my form I also have an input where the user inserts its username.
> > When validating the email I need to send also the Username an not only
> > the email.
>
> > Can I do this?
>
> > Thanks,
> > Miguel


[jQuery] Re: mooTools to jQuery conversion job

2008-11-15 Thread Balazs Endresz

That page has about three body and html tags so maybe you have to
correct it to work, usage example at the bottom:
http://jsbin.com/ibuje/edit

It could have been done with UI's widget factory as well:
http://docs.jquery.com/UI/Developer_Guide
but no dependency this way.

What compromises? :)

On Nov 14, 9:18 pm, WatermarkShaun <[EMAIL PROTECTED]> wrote:
> I love a particular news scoller example done in MooTools (http://
> woork.bravehost.com/newsticker/index.html).  Not knowing jQuery
> enough, I don't have time to convert it over (and using both
> frameworks is not an option).  I would think this could be done
> quickly by one that knows jQuery well (with very little compromises).
> Anyone up for the job ($)?  Or at least recommend a better place to
> post this request?


[jQuery] Re: My cycle plugin code

2008-11-15 Thread Rakibul Hasan
Looks really awesome. Happy to see it !
-
Best Regards
Rakib




On Sat, Nov 15, 2008 at 6:37 PM, Mike Alsup <[EMAIL PROTECTED]> wrote:

>
> > I hope you enjoy the plugin as much as I do!
>
> Thanks for the kind words, Girish.  I'm happy to hear you've found the
> Cycle plugin so useful.
>
> Cheers!


[jQuery] Re: has anyone come across a plugin like this ?

2008-11-15 Thread Gildas

Take a look at MonoRail if you don't already know it ;-)

http://castleproject.org/

On Nov 13, 7:28 pm, heysatan <[EMAIL PROTECTED]> wrote:
> Sean,
>
> Thanks!  I really feel that's how web 2.0 should be used, minimally
> and usefully.  I'll start working on the plugin next week, I'll try
> and have a beta version up by the end of november.
>
> We were working within .NET which made it hard to implement some of
> the things I wanted to.  The sign in/registration popups ended up
> being iframes because of the whole .NET validation model, I would have
> made them pure ajax if possible.  Not to sound down too down on .NET
> (well, I am a little down on it), but we could have done more in a
> less "framework" based web environment (PHP or Ruby).
>
> Also, I have been a flash developer for a while, and doing this
> project made me fall for jQuery.  I can't wait to use some of my code
> based flash animation background to build a full jQuery (flash like)
> site for fun.
>
> Jason
>
> On Nov 12, 4:04 am, CliffordSean <[EMAIL PROTECTED]> wrote:
>
> > hi Jason
>
> > what luck - i get to speak to the person that actually built the thing !
>
> > you guys did some amazing work on that biocompare site i must say - i came
> > across it just by chance but am happy i did as its a great example of a real
> > simple web2.0 implementation and some near jquery work.
>
> > id say that plugin would be a real hit ! so please do if you have some time
> > please do make it available!
>
> > thanks alot
> > sean
>
> > heysatan wrote:
>
> > > Hi Sean,
>
> > > I built this breadcrumb animation.  Due to time limitations at the end
> > > of the project I wasn't able to make it into a plugin (I built a lot
> > > of other plugins for this project), but I'd like to when I get a
> > > chance.
>
> > > I really solved a problem for us because our category and page titles
> > > are so long (scientists are long winded).  Before we would show only a
> > > couple of steps in the HTML to get around this.  This method was more
> > > SEO friendly, more usable, and I thought, kind of cool.
>
> > > If there is a demand for it I'll work on porting it to a plugin, but
> > > probably not for the next 2 weeks or so.
>
> > > Jason
> > > Lead UI Developer - CompareNetworks
>
> > --
> > View this message in 
> > context:http://www.nabble.com/has-anyone-come-across-a-plugin-like-this---tp2...
> > Sent from the jQuery General Discussion mailing list archive at Nabble.com.


[jQuery] Re: [validate] Two page form won't validate on IE

2008-11-15 Thread Jörn Zaefferer
Yes, thats right. Usually the process of extracting already reveals
the problem to the extractor...

Jörn

On Fri, Nov 14, 2008 at 9:05 PM, Michael Smith <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I've added some validate() calls now.  I assumed that this wasn't
> necessary when I explicitly call valid() but perhaps I've got that
> wrong.  Anyways, it doesn't appear to have changed things.  The valid
> call on the second form is always returning true (for IE), even if the
> required fields are empty.  On Firefox it's doing the right thing.
>
> When you say extract a testpage, what do you mean?  Remove as much
> from the page as possible whilst keeping the problem?
>
> Thanks
>
> Michael
>
>
> On Fri, Nov 14, 2008 at 4:54 PM, Jörn Zaefferer
> <[EMAIL PROTECTED]> wrote:
>> I see the "valid" calls in your code, but none where you actually
>> initialize the validation via $(...).validate().
>>
>> Could you extract a testpage?
>>
>> Jörn
>>
>> On Fri, Nov 14, 2008 at 4:48 PM, Michael Smith <[EMAIL PROTECTED]> wrote:
>>>
>>> Hi there
>>>
>>> I'm having trouble getting the Validation plug in to work on this page
>>>
>>> http://dev2.savingforchildren.co.uk/mjs/health/index.epl
>>>
>>> I have two forms - the second one appears when the first one is
>>> successfully completed.
>>>
>>> The first form validates correctly (you only need to choose a day,
>>> month and year from the dropdowns)
>>>
>>> However, when using IE no validation is applied to the second form (ie
>>> you can leave the whole page blank and it is accepted).  Firefox works
>>> fine
>>>
>>> Any help much apprecited
>>>
>>> Thanks,
>>> Michael
>>>
>>
>


[jQuery] Re: [autocomplete] where did the doc go?

2008-11-15 Thread Jörn Zaefferer
You're looking for this, right?
http://docs.jquery.com/Plugins/Autocomplete/autocomplete#url_or_dataoptions

Jörn

On Sat, Nov 15, 2008 at 3:49 AM, thierry <[EMAIL PROTECTED]> wrote:
>
> Hey guys,
>
> I hope it's just I can't find it anymore, but where's the (complete)
> doc on autocomplete? The plugin page on jQuery seems pretty light
> (http://docs.jquery.com/Plugins/Autocomplete), and the official page
> redirects to this new jQuery page.
>
> If I remember correctly, there was a list of all options available in
> autocomplete(url, [options])...
>
> Mostly, I was looking for an option so when the user hits 'enter',
> autocomplete plugin would not automatically selects by default a
> suggestion, but would submit exactly what was entered. Any idea on how
> to do this?
>
> Thanks for your help!
>


[jQuery] Re: My cycle plugin code

2008-11-15 Thread Mike Alsup

> I hope you enjoy the plugin as much as I do!

Thanks for the kind words, Girish.  I'm happy to hear you've found the
Cycle plugin so useful.

Cheers!


[jQuery] Re: Nesting toddle div's

2008-11-15 Thread Richard D. Worth
This should work:

$("div.togglecontainer div.togglebutton").click(function() {
$(this).siblings("div.toggletarget").slideToggle();
});
$('div.toggletarget').hide();

A couple of notes:

- I combined your first two selectors into one
- I've used .click(fn) in place of .bind("click", fn)
- No need for .each as .click will automatically do .each inside it
- I first changed your .parent().find("div.toggletarget") to
.parent().children("div.toggletarget") - this was your biggest issue
- I then substituted .siblings for .parent().children("div.toggletarget")
- No need to compare event.target, nor return false, since you are binding
to elements with no descendants

- Richard

On Fri, Nov 14, 2008 at 12:34 PM, sinkingfish <[EMAIL PROTECTED]> wrote:

>
>
> Thanks for the reply Richard, unfortunately that wasn't the issue. Ive
> tided
> up my example to make it clearer :  http://pastie.org/314976
> http://pastie.org/314976
>
> So at startup you should see 'Click me' then upon clicking, 'I'm Hidden' &
> 'Click ME To see more' will be revealed. After clicking 'Click ME To see
> more', 'Nested Hidden' would be revealed.
>
> Thanks for the help
>
>
>
> Richard D. Worth-2 wrote:
> >
> > You may want to start by validating your html. You're missing a closing
> > , so it's not clear how you intend it to be nested. Once you've
> > corrected that, let us know if you still have a problem.
> >
> > - Richard
> >
> > On Fri, Nov 14, 2008 at 10:26 AM, sinkingfish <[EMAIL PROTECTED]>
> > wrote:
> >
> >>
> >>
> >> Hi,
> >>
> >> Im new to jQuery and looking for a bit of help. Im trying to have
> >> toggleable
> >> content within toggleable content.
> >>
> >>
> >> http://pastie.org/314861 Code
> >>
> >>
> >> It's just not working for me, when I click the first toggle all is
> >> revealed?
> >> Am I way off? Something to do with propagation?
> >>
> >> Thanks
> >> Brian
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/Nesting-toddle-div%27s-tp20502521s27240p20502521.html
> >> Sent from the jQuery General Discussion mailing list archive at
> >> Nabble.com.
> >>
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Nesting-toggle-div%27s-tp20502521s27240p20505081.html
> Sent from the jQuery General Discussion mailing list archive at Nabble.com.
>
>


[jQuery] jCarousel with links

2008-11-15 Thread Savvas

Hello everybody

I like to know  if is it possible to make anchor tags instead of img
via changing the xml file created by the asp page.

http://2244.gr/scripts/jcarousel/examples/dynamic_ajax_asp.html

http://2244.gr/scripts/jcarousel/examples/dynamic_ajax.asp

function mycarousel_getItemHTML(url)
{
return '';
};

To behave like

function mycarousel_getItemHTML(url)
{
return '';
};


Thank you






[jQuery] Please Help me regarding Webservice method call via saop client

2008-11-15 Thread Hassan

System.Web.Services.Protocols.SoapException: Server did not recognize
the value of HTTP Header SOAPAction: http://tempuri.org/GetSessionParts.
   at
System.Web.Services.Protocols.Soap11ServerProtocolHelper.RouteRequest
()
   at System.Web.Services.Protocols.SoapServerProtocol.RouteRequest
(SoapServerMessage message)
   at System.Web.Services.Protocols.SoapServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type
type, HttpContext context, HttpRequest request, HttpResponse response,
Boolean& abortProcessing)


[jQuery] [autocomplete] where did the doc go?

2008-11-15 Thread thierry

Hey guys,

I hope it's just I can't find it anymore, but where's the (complete)
doc on autocomplete? The plugin page on jQuery seems pretty light
(http://docs.jquery.com/Plugins/Autocomplete), and the official page
redirects to this new jQuery page.

If I remember correctly, there was a list of all options available in
autocomplete(url, [options])...

Mostly, I was looking for an option so when the user hits 'enter',
autocomplete plugin would not automatically selects by default a
suggestion, but would submit exactly what was entered. Any idea on how
to do this?

Thanks for your help!


[jQuery] image toggle

2008-11-15 Thread bob

Hi,
I am trying to create a toggler that I would like to work
as follows:
User clicks on #my_header and source of the image gets replaced.
I tried the following but it did not work.




Some title here



$(function() {
$('#my_header').click(
function() {
$('#my_header img').src = $('#my_header 
img').src.replace( /_down
\.gif$/, '_up.gif' );
},
function() {
$('#my_header img').src = $('#my_header 
img').src.replace( /_up
\.gif$/, '_down.gif' );
}
);
});