[jQuery] Re: Once validated..

2009-01-13 Thread mbraybrook

You can check a var in jQuery using the following method:


var my_js_var = "";
if (my_js_var == "Value) {
alert("Value set");
}


Thats one of the Q's down!

M

On Jan 13, 3:45 am, Nikola  wrote:
> I'm validating a form in php and am wondering how I can bind a jQuery
> function to a successful validation or how to check a var set in php
> with jQuery.


[jQuery] Re: jeditable and XHTML?

2008-11-14 Thread mbraybrook

I can't see anything wrong with the JS, can you perhaps provide a more
complete picture?
.: Are you calling the JS when the DOM is ready?
.: Are you posting the changes to a URL that is prepared to handle it?
.: Are you using the latest versions of the scripts?

Regards
M

On Nov 13, 11:23 pm, Rodent of Unusual Size <[EMAIL PROTECTED]>
wrote:
> Is there a known problem with jQuery/jeditable and
> XHTML?  I keep running into this 'invalid string'
> message with JS and XHTML.  First Dojo, now here..
> it's getting discouraging.  What am I doing wrong?
>
> Anyway, is there anything obviously wrong with
> the fragment athttp://apache.pastebin.ca/1254469?
> When I click in an appropriately-classed element,
> the current text disappears, but then the error
> crops up.
>
> I want to use jeditable to edit fields in a table,
> but right now I'm trying to get it to work on any
> old XHTML..
>
> And yes, I know IE doesn't do XHTML well/at all.
> And no, I don't care. :-/
>
> Thanks!
> --
> #ken    P-)}
>
> Ken Coar, Sanagendamgagwedweinini  http://Ken.Coar.Org/
> Author, developer, opinionist      http://Apache-Server.Com/
>
> "Millennium hand and shrimp!"


[jQuery] Re: Simple Filtering Script not working

2008-11-09 Thread mbraybrook

Have you checked what obj = $(this) returns?

Looks to me like it would return the document, of which there is only
one, so would only perform one iteration when used with .each.

Presumably it would need to reference a group of elements on the page
to work e.g.:
var obj = $('.class');

M

On Nov 9, 12:58 am, Nic Hubbard <[EMAIL PROTECTED]> wrote:
> I am working on a simple filtering script that will match the jquery
> selector, and find the text inside all the child nodes.  Then hide
> those that are not found.
>
> For some reason it is not working, and I am not sure why.  Is there a
> better way I could be doing this?
>
>         var obj = $(this);
>
>         $('#filter').keyup(function() {
>             var filter = $('#filter').val();
>             obj.each(function() {
>                 if ($(this + ':contains(filter)')) {
>                     $(this).show();
>                 } else {
>                     $(this).hide();
>                 };
>             });
>         });


[jQuery] Re: span tag is width:80px but is only showing the width of contents?

2008-11-09 Thread mbraybrook

It is not a good idea, in my experience, to use floats in that way,
but if it works - consistently - then i guess there is no real reason
not to, it just doesn't feel right...

I would avoid going down the road of using inline-block, IE will not
completely support it until IE8 is released, and Firefox only released
support in its most recent FF3 (http://www.quirksmode.org/css/
display.html).

Therefore it requires a whole lot of learning of how it reacts to
different browsers, for the sake of achieving the task, I'd use either
my overly simple idea, or for better expandability use Hectors'
example.

M

On Nov 7, 5:25 pm, nmiddleweek <[EMAIL PROTECTED]> wrote:
> Why is this bad markup? it works...
>
> On Nov 7, 4:27 pm, mbraybrook <[EMAIL PROTECTED]> wrote:
>
> > This works:
> >  A
>
> > However...
> > I feel bad telling you that - this is bad markup - perhaps you could
> > explain why you are trying to do this, or what the bigger picture here
> > is?
>
> > As stated by Andy, setting span, an inline element, to display:block,
> > defeats the object of using a span tag at all.
>
> > M
>
> > On Nov 7, 4:04 pm, nmiddleweek <[EMAIL PROTECTED]> wrote:
>
> > > Yes that works...
>
> > > What I'm trying to do is display a SPAN atg at the end of an Input
> > > text field of a fixed size. If I set the display to block, it is
> > > forcing itself to be on the next line.
>
> > > Have you got any idea on how I can do this?
>
> > > Cheers,
> > > Nick
>
> > > On Nov 7, 3:48 pm, mbraybrook <[EMAIL PROTECTED]> wrote:
>
> > > > try:
> > > > A > > > span>
>
> > > > Does that work?
>
> > > > M
>
> > > > On Nov 7, 3:45 pm, nmiddleweek <[EMAIL PROTECTED]> wrote:
>
> > > > > Hello,
>
> > > > > I've got a SPAN tag which is set to 80px...
>
> > > > > A
>
> > > > > The contents of the SPAN is a single character and when rendered on
> > > > > screen, the green SPAN is showing as only approx 15 pixels in width.
>
> > > > > How can I force the width to be 80px?
>
> > > > > Thanks,
> > > > > Nick


[jQuery] Re: Anyway to make flexigrid "liquid" ?

2008-11-07 Thread mbraybrook

Someone here may yet come up with an answer, but perhaps this question
would be better in http://groups.google.com/group/flexigrid?

Sorry i can't be any more use than that.

M

On Nov 7, 4:21 pm, yabdab <[EMAIL PROTECTED]> wrote:
> Anyone know a way to make this flexigrid "liquid"?
>
>  What I mean is, if it is in a browser window, it resizes with the
> window?
>
> It has grab tabs for this, but then you have to resize twice, first
> the browser, then the grid.
>
> http://www.webplicity.net/flexigrid/


[jQuery] Re: span tag is width:80px but is only showing the width of contents?

2008-11-07 Thread mbraybrook

This works:
 A

However...
I feel bad telling you that - this is bad markup - perhaps you could
explain why you are trying to do this, or what the bigger picture here
is?

As stated by Andy, setting span, an inline element, to display:block,
defeats the object of using a span tag at all.

M

On Nov 7, 4:04 pm, nmiddleweek <[EMAIL PROTECTED]> wrote:
> Yes that works...
>
> What I'm trying to do is display a SPAN atg at the end of an Input
> text field of a fixed size. If I set the display to block, it is
> forcing itself to be on the next line.
>
> Have you got any idea on how I can do this?
>
> Cheers,
> Nick
>
> On Nov 7, 3:48 pm, mbraybrook <[EMAIL PROTECTED]> wrote:
>
> > try:
> > A > span>
>
> > Does that work?
>
> > M
>
> > On Nov 7, 3:45 pm, nmiddleweek <[EMAIL PROTECTED]> wrote:
>
> > > Hello,
>
> > > I've got a SPAN tag which is set to 80px...
>
> > > A
>
> > > The contents of the SPAN is a single character and when rendered on
> > > screen, the green SPAN is showing as only approx 15 pixels in width.
>
> > > How can I force the width to be 80px?
>
> > > Thanks,
> > > Nick


[jQuery] Re: Triggering Validation using a button instead of submit

2008-11-07 Thread mbraybrook

It's my understanding that the validation plug-in listens for a form
to be submitted before performing its checks.  If this isn't the case
then this won't work, but, in your sample code you've used:
 validator.triggerHandler('submit');
which will need to be changed to:
 $('#formid').triggerHandler('submit');

Validator is the validate function itself and as far as i know does
not support a triggerHandler method, or a 'submit' event.  So this
rules needs to be applied to the form element itself.

JQuery has a nack for failing silently - good for production; bad for
development!

Friday has a nack for being lame - good for.. well.. nothing!

M


On Nov 7, 4:04 pm, Justin Kozuch <[EMAIL PROTECTED]> wrote:
> No joy there...
>
> Here's my code:
>
> // validate signup form on keyup and submit
>   var validator = $("#sourcing").validate();
>   $("#submit").click(function() {
>     validator.triggerHandler('submit');
>         rules: {
>         
>     }, // end rules
>
>     messages: {
>       ...
>     } // end messages
>     });
>   });
>
> });
>
> I'm not getting any JS errors, so I'm going to assume that everything
> is in order. However, validation still isn't occuring... Oh, how I
> love Fridays. ;)
>
> - justin
> On Nov 7, 10:47 am, mbraybrook <[EMAIL PROTECTED]> wrote:
>
> > Correction:
> >   validator.triggerHandler('submit');
> > change to
> >   $('#formid').triggerHandler('submit');
>
> > M
>
> > On Nov 7, 3:45 pm, mbraybrook <[EMAIL PROTECTED]> wrote:
>
> > > Try using the triggerhandler function:
> > > var validator = $("#sourcing").validate();
> > > $("#submit").click(function() {
> > >         validator.triggerHandler('submit');
>
> > > });
>
> > > Not tested...
>
> > > HTH
> > > M
>
> > > On Nov 7, 3:41 pm, Justin Kozuch <[EMAIL PROTECTED]> wrote:
>
> > > > Hi There,
>
> > > > I've been using the validation plug in for a while now and I love it,
> > > > but I am stuck on something.
>
> > > > I am trying to validate a form using:
>
> > > > 
> > > > instead of the usual:
>
> > > > 
>
> > > > I tried using:
>
> > > > var validator = $("#sourcing").validate();
> > > > $("#submit").click(function() {
> > > >         validator.form();
>
> > > > });
>
> > > > to do the validation but that doesn't do anything at all. Has anyone
> > > > been able to figure this out?
>
> > > > Thanks,
>
> > > > Justin


[jQuery] Re: Triggering Validation using a button instead of submit

2008-11-07 Thread mbraybrook

Correction:
  validator.triggerHandler('submit');
change to
  $('#formid').triggerHandler('submit');

M

On Nov 7, 3:45 pm, mbraybrook <[EMAIL PROTECTED]> wrote:
> Try using the triggerhandler function:
> var validator = $("#sourcing").validate();
> $("#submit").click(function() {
>         validator.triggerHandler('submit');
>
> });
>
> Not tested...
>
> HTH
> M
>
> On Nov 7, 3:41 pm, Justin Kozuch <[EMAIL PROTECTED]> wrote:
>
> > Hi There,
>
> > I've been using the validation plug in for a while now and I love it,
> > but I am stuck on something.
>
> > I am trying to validate a form using:
>
> > 
> > instead of the usual:
>
> > 
>
> > I tried using:
>
> > var validator = $("#sourcing").validate();
> > $("#submit").click(function() {
> >         validator.form();
>
> > });
>
> > to do the validation but that doesn't do anything at all. Has anyone
> > been able to figure this out?
>
> > Thanks,
>
> > Justin


[jQuery] Re: span tag is width:80px but is only showing the width of contents?

2008-11-07 Thread mbraybrook

try:
A

Does that work?

M

On Nov 7, 3:45 pm, nmiddleweek <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I've got a SPAN tag which is set to 80px...
>
> A
>
> The contents of the SPAN is a single character and when rendered on
> screen, the green SPAN is showing as only approx 15 pixels in width.
>
> How can I force the width to be 80px?
>
> Thanks,
> Nick


[jQuery] Re: Triggering Validation using a button instead of submit

2008-11-07 Thread mbraybrook

Try using the triggerhandler function:
var validator = $("#sourcing").validate();
$("#submit").click(function() {
validator.triggerHandler('submit');

});

Not tested...

HTH
M

On Nov 7, 3:41 pm, Justin Kozuch <[EMAIL PROTECTED]> wrote:
> Hi There,
>
> I've been using the validation plug in for a while now and I love it,
> but I am stuck on something.
>
> I am trying to validate a form using:
>
> 
> instead of the usual:
>
> 
>
> I tried using:
>
> var validator = $("#sourcing").validate();
> $("#submit").click(function() {
>         validator.form();
>
> });
>
> to do the validation but that doesn't do anything at all. Has anyone
> been able to figure this out?
>
> Thanks,
>
> Justin


[jQuery] Re: delay delivery of a link

2008-11-04 Thread mbraybrook

Javascript has a setTimeOut() function - this can delay the call of a
javascript function by a specified time.

http://www.w3schools.com/js/js_timing.asp - for more info.

M

On Nov 4, 4:45 pm, Manuel Meyer <[EMAIL PROTECTED]> wrote:
> Hey,
> is there a way of delay the delivery of a link?
> The idea I have is to display a disclaimer in case a -element,  
> pointing to an external site, is clicked.
> To ensure the user can read this disclaimer, i would like to delay the  
> browser for 1 or 2 seconds, as ie Opera reacts very fast, while with  
> FF on Mac OS X I have a lot time to read it.
>
> I hoped there would be an equivalent to preventDefault(), but there  
> isnt, right?
>
> So another solution could be writing the href-attribute to a variable  
> and make the browser execute it later.
> But as I am a jQuery-newbie I dont know how to do it. Is it possible  
> at all?
>
> Thanks, Manuel


[jQuery] Re: where are the plugin demos?

2008-11-04 Thread mbraybrook

!

Where is your sense of adventure!?

If everyone told us what their scripts did - they'd get no enjoyment
out of watching us struggle...

M

On Oct 28, 9:05 pm, JCQ <[EMAIL PROTECTED]> wrote:
> thanks, Mark.
>
> yes, I'm definitely in the right place --- I just did an interesting
> test. I randomly picked 25 plugins from the "latest plugins" list and
> only 2 had any demo/documentation attached in the Resources section.
> So either I'm not looking in the right spot, or maybe everyone is just
> advanced enough to visualize what a plugin can do just from looking at
> the plugin code?   Is no one else daunted by that?
>
> On Oct 28, 1:43 pm, mbraybrook <[EMAIL PROTECTED]> wrote:
>
> > Click the title to view the plugin itself, lookup the Resources
> > section, if a demo is available its listed there, else try the home
> > page for the project.
>
> > Assuming your onhttp://plugins.jquery.com?
>
> > M
>
> > On Oct 28, 5:30 pm, JCQ <[EMAIL PROTECTED]> wrote:
>
> > > I was wondering where the plugin demos are?
>
> > > Browsing thru the list of latest plugins, all it seems to list is the
> > > name, sometimes a version number and then a link to download the
> > > plugin itself
>
> > > Lots of times I don't even understand the plugin description until I
> > > see it working and code snippetwhat about links to a page that has
> > > the plugin working so we can see it in action?
>
> > > yes? no? maybe? is everyone else just such a javascript jock that they
> > > "get" what a plugin does just by looking at the plugin code? :)


[jQuery] Re: Is there a way to update an element while you're dragging it?

2008-10-31 Thread mbraybrook

Try looking at the 'drag' option of draggable, it provides a 'Function
that gets called when the mouse is moved during the dragging.'
something like:
$(".item").draggable({
  drag(function()
   $(this).text('new text');
  )
});
I've not tested, but this certainly seems to offer the answer.

HTH
M


On Oct 31, 4:48 am, tecmo <[EMAIL PROTECTED]> wrote:
> i'm using the sortables and dragging around div containers with text
> boxes.  I change the value of the text boxes while dragging, but the
> changed values don't appear on the item you're dragging.  Only when
> you drop the item do the changes appear on the dragged item.  Is there
> a way to refresh the dragged item while dragging?


[jQuery] Re: where are the plugin demos?

2008-10-28 Thread mbraybrook

Click the title to view the plugin itself, lookup the Resources
section, if a demo is available its listed there, else try the home
page for the project.

Assuming your on http://plugins.jquery.com?

M

On Oct 28, 5:30 pm, JCQ <[EMAIL PROTECTED]> wrote:
> I was wondering where the plugin demos are?
>
> Browsing thru the list of latest plugins, all it seems to list is the
> name, sometimes a version number and then a link to download the
> plugin itself
>
> Lots of times I don't even understand the plugin description until I
> see it working and code snippetwhat about links to a page that has
> the plugin working so we can see it in action?
>
> yes? no? maybe? is everyone else just such a javascript jock that they
> "get" what a plugin does just by looking at the plugin code? :)


[jQuery] Re: drag drop, and store dropped location

2008-10-27 Thread mbraybrook

The jQuery UI has a function called droppable, which can be applied to
any jQuery object $("#id").Droppable. (documentation@
http://docs.jquery.com/UI/Droppables).

This returns through the drop parameter the object which was dropped
on, as in:
drop: function(ev, ui) {
$(this).append("Dropped!");
}

This will allow you to access the element the item was dropped onto.
Within this same function you could also use the jQuery mouse
positioning http://docs.jquery.com/Tutorials:Mouse_Position to return
the exact co-ordinates.

Note:The above is not tested by myself.

HTH
M


On Oct 25, 6:13 pm, mark <[EMAIL PROTECTED]> wrote:
> hi all
> i want to be able to drag elements and drop it, and then store the
> location where it was dropped, so that i can make the drag drop
> persistent.
>
> i saw the jquery ui draggable library, but how do i get the dropped location?
> thanks!


[jQuery] Re: Traversing Question with Parent and Children

2008-10-27 Thread mbraybrook

Why not provide the solution to make the post a little more useful?

:P

On Oct 25, 7:39 pm, Jason <[EMAIL PROTECTED]> wrote:
> Resolved.
>
> On Oct 25, 11:51 am, Jason <[EMAIL PROTECTED]> wrote:
>
> > I have HTML similar to the following:
>
> > 
> > red border
> > 
>
> > Essentially I have a div with a link inside of it.
>
> > What I want to do is have the div selected when the link is clicked. I
> > need this done without referencing the class/id of the parent div.
>
> > So far I have:
>
> > $(".link").click(function () {
> >        //somehow select the parent div
>
> > });
>
> > I've looked at 'children' and 'parent' traversing but I can't wrap my
> > head around a solution for this problem. Thanks in advance, you guys
> > are great.
>
> > -Jason


[jQuery] Re: Autocomplete: Show full list before start typing

2008-10-27 Thread mbraybrook

Can you tell us how you currently initialize the list?

Perhaps a link or an extract of code.

It depends on how you populate the list as to how you would show all
items.
I can't personally see a built in function of the AutoComplete plugin
that supoprts this - hence it would likely be that you would populate
the list yourself manually.

Regards
Mark

On Oct 27, 3:08 pm, Mello <[EMAIL PROTECTED]> wrote:
> Hi all
> I've a filed that use the Ui.autocomplete plugin to show the list of
> possibile values, this list is shown when i start typing but i need to
> view the full list before start typing.
> This list is small (max 15 items) so there's no performance issues.
>
> There's a method to do this?
>
> Thank you.
>
> Mello.


[jQuery] Re: Can't apply date picker!

2008-09-23 Thread mbraybrook

Before I can help, I'll need a little more information, have you got a
page available online to view an example?

Can you provide the snippet of offending code at least?  Are you using
the JQueryUI date picker or a third-party plugin?

M

On Sep 23, 10:37 am, Ulan Zhandos <[EMAIL PROTECTED]> wrote:
> Firebug says
> (new Date).zeroTime is not a function
>
> :((


[jQuery] Re: javascript enabled

2008-09-09 Thread mbraybrook

Not a problem, glad I could help.

M

On Sep 9, 3:07 pm, "Sarmad AL-Saiegh" <[EMAIL PROTECTED]>
wrote:
> hi, thanks alot. ur answer was quit good :)
> the tip about  helped me to much.
>
> best wishes 2 u :)
>
> sarmad
>
>
>
> On Tue, Sep 9, 2008 at 3:24 PM, mbraybrook <[EMAIL PROTECTED]> wrote:
>
> > Whether or not a user has javascript is not something you would use
> > javascript for (if you use javascript, detecting a user that has not
> > got javascript is, by definition, impossible.
> > Alternatively, do some research into the html  attribute,
> > this will allow you to provide for those who do not have javascript at
> > all.
>
> > As for versions of Javascript (settings etc), it is often not
> > necessary, JQuery performs a lot of cross-browser/platform
> > compatibility testing and function replacements/supplements
> > internally, often you need only to call a function and the rest is
> > handled by JQuery.
>
> > Does this answer your question or have i missed the point?
>
> > Regards
> > Mark
>
> > On Sep 9, 8:30 am, "[EMAIL PROTECTED]"
> > <[EMAIL PROTECTED]> wrote:
> > > Hello again,
> > > howcan be detect whether or not the user has javascript enabled and
> > > then write certain if statements to account for that. How do I detect
> > > a user's javascript setting?
>
> > > thanks for ur help :)
>
> > > samrad
>
> --
> Sarmad AL-Saieghhttp://live.cs.uni-magdeburg.de/~alsaiegh/


[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread mbraybrook

Hmm, a quandry, I'll do a little testing for you and get back when/if
I can, unless someone else can provide an answer in the mean time.

Regards
Mark

On Sep 9, 3:10 pm, Velcrobelly <[EMAIL PROTECTED]> wrote:
> I will try to be clearer...
>
> The checkbox controls the hide/show toggle of the two divs.
>
> Initially, the first div is visible and the name value for the input
> field in it is 'data01'. The second div is hidden and the name value
> of the input field in it is 'data02'.
>
> When the checkbox is clicked the first div is hidden and the second
> becomes visible. This works as planned using the code above.
>
> However I also need the name values of the two input fields to swap.
> So...
>
> The first div becomes hidden and the name value for the input field in
> it changes from 'data01' to 'data02'. The second div becomes visible
> and the name value for the input field in it changes from 'data02' to
> 'data01'.
>
> If the checkbox is then unchecked, it needs to switch back to it's
> original state.
>
> I hope this makes more sense.
>
> On Sep 9, 8:00 am, tlob <[EMAIL PROTECTED]> wrote:
>
> > Can you be more specific? I dont get it
> > Sorry
>
> > You fill out the first Input, save the form via a submit button and
> > then?
>
> > > > But now I need to be able to swap the name values of the text fields
> > > > on the toggle as well, so that the visible text field always carries
> > > > the name value of "data01".


[jQuery] Re: javascript enabled

2008-09-09 Thread mbraybrook

Whether or not a user has javascript is not something you would use
javascript for (if you use javascript, detecting a user that has not
got javascript is, by definition, impossible.
Alternatively, do some research into the html  attribute,
this will allow you to provide for those who do not have javascript at
all.

As for versions of Javascript (settings etc), it is often not
necessary, JQuery performs a lot of cross-browser/platform
compatibility testing and function replacements/supplements
internally, often you need only to call a function and the rest is
handled by JQuery.

Does this answer your question or have i missed the point?

Regards
Mark

On Sep 9, 8:30 am, "[EMAIL PROTECTED]"
<[EMAIL PROTECTED]> wrote:
> Hello again,
> howcan be detect whether or not the user has javascript enabled and
> then write certain if statements to account for that. How do I detect
> a user's javascript setting?
>
> thanks for ur help :)
>
> samrad


[jQuery] Re: jQuery and swapping name values

2008-09-09 Thread mbraybrook

You may have to replace slideToggle with a conditional .hide() .show()
and some other information.

Pseudo-code:
.: Check the state of the two divs seperately, perhaps by providing
unique ID's for each one?
.: If one is hidden, show it and set the "name" attribute to "data01"
.: if one is shown, hide it and set the "name" attribute to "data02"

Sorry, no code, writing this in a bit of a rush.  I can supply code
later if you would like?

Hope this helps, though i may have missed the point of the question!?

Regards
Mark

On Sep 8, 11:01 pm, Velcrobelly <[EMAIL PROTECTED]> wrote:
> I am using the following to do a Hide/Show feature, and it works
> exactly as I want...
>
> --snip-
> 
> $(function(){
>         $('#sender').click(function(){
>                         $('#container div.toggleit').slideToggle('normal');
>         });});
>
> 
>
> 
> table#container div.hidden { display: none; }
> 
>
> 
> 
> 
> 
>  value="show second">
> 
> 
> 
> -end snip-
>
> But now I need to be able to swap the name values of the text fields
> on the toggle as well, so that the visible text field always carries
> the name value of "data01".
>
> I cannot figure out how to do this and hope someone can help out.
>
> I hope this makes sense, and thank you in advance for any help...


[jQuery] Re: Using JQuery with other libraries (Lightbox)

2008-09-09 Thread mbraybrook


I must add at this point that if at all possible eradicate the
requirement for 2 javascript libraries.

Javascript libraries, though incredibly useful, are fairly large in
size, and using two can raise all sorts of performance issues.

As you stated you are a novice it think its more important that you
work to use just one library, 1) getting used to a single library is a
lot easier to handle, 2) it is very important to get into good
practices early.

If I had to choose between the two, I'd suggest you opt for JQuery,
it's served me better historically than Prototype, but that is
personal opinion.

Regards
Mark

On Sep 9, 7:50 am, adeking <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I have read the documentation on using JQuery with other libraries by
> using the Noconflict call.  I have to admit to being a total novice at
> this.
>
> I want to use Jquery to do a text replace on my search box for my site
> - and I have lightbox working for my images.
>
> I cannot get the two libraries to work together.  If I try to
> implement both then only Lightbox will work.  If I comment out
> lightbox then JQuery works.
>
> The code from my head tag is below and here is the link 
> -http://www.macmillan-academy.org.uk/zeltha/index.php
>
> 
>                 
>
>         ">
>                  js/scriptaculous.js?load=effects,builder"?>">
>         ">
>          jquery.js"?>">
>          jquery.hint.js"?>" type="text/JavaScript">
>
>                 
>                 var $j =jQuery.noConflict();
>                     $(function(){
>                         // find all the input elements with title
> attributes
>                         $('input[title!=""]').hint();
>                     });
>                 
>
> Many thanks for your time.


[jQuery] Re: how to control a imageover making one image to fade in a menu and fade out when....

2008-09-09 Thread mbraybrook

As for a proper example i can't do that too well as i don't have any
original code to work with but something like this may work:

html:







JScript:

//Add a listener to the #container div, rather than the img.
$('#container').mouseover(function(){ $('#menu').show()  });
$('#container').mouseout(function(){ $('#menu').hide()  });


Without any example from you, this may well be useless unfortunately,
but the theory, at least to me, should work.

HTH
Mark


On Sep 9, 12:53 pm, Aaron <[EMAIL PROTECTED]> wrote:
> ok my problem is that I have the user upload a image file this image
> file on the page is a picture of them.
>
> What I want to do is when the mouse is over the image I want to fade
> in a menu this menu would contain buttons for editing the which photo
> to show and many other things about the image.
>
> the problem I run into is I seek a if statement. I want the mouse over
> the image to when going off meaning mouseout I want to fade out the
> menu only if the mouse is not on the menu.
>
> If I just put a mouseover and a mouseout on this image it would fade
> in the menu and when you try to put the mouse on the menu it would
> fade out.
>
> SO  I just made the mouseover and mouseout for both the menu and the
> persons image.
> This caused a bad effect. When you put the  mouse over the persons
> image it would fade in the menu and when you go off the image to go on
> the menu the menu would fade out and then fade back in.
>
> I want it in a way where when  my mouse leaves the persons image that
> if the mouse is on the menu it would fade out at all and only fade out
> only if the mouse is not on the persons image or the menu.
>
> How can I do this ??? can you give an example???