Yes, client side it is. You could add a binding like onclick = "return false;"; to the hyperlink. That should deactivate it, though it will still appear as a clickable link. To get the effect that you want, you will probably want to change this to

onclick = "return canSubmit();";

And implement canSubmit() to perform your checks and return true or false.


Chuck


On Aug 12, 2009, at 9:54 AM, Matthew Kidd wrote:


so far client-side seems to be the only way to do what I want. I want the action the user ultimately performs to default to disabled but I still want to be able to turn it back on once the user has met a set of criteria actions.

I just tried using a binding but it didn't work. It may have to do with the WOHyperlink being a subcomponent of the actual component I'm using but even putting something like "^disabled" into the disabled binding didn't seem to work.

So as it stands now it does appear that it has to be done client side.

The reason the WOHyperlink is subcomponent is because it also does a form submit as well.




Chuck Hill <[email protected]>
08/11/09 01:28 PM

To
Matthew Kidd <[email protected]>
cc
[email protected]
Subject
Re: Trouble disabling/nulling href of a WOHyperlink using JavaScript






On Aug 11, 2009, at 11:20 AM, Matthew Kidd wrote:

>
> I'm attempting to copy and store the href attached to a WOHyperlink
> so that I can deactivate a "button" on a form. Numerous attempts
> have resulted in the closest attempt being a link that appears to
> refer to the previous page.
>
> Is there a way to disable a WOHyperlink via JavaScript or java that
> effectively deactivates the WOHyperlink?
>
> Matt

The disabled = true; binding does not do what you want?  You want
client side de-activation?


Chuck

--
Chuck Hill             Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their
overall knowledge of WebObjects or who are trying to solve specific
problems.
http://www.global-village.net/products/practical_webobjects








------------------------------------------------------------------------
Disclaimer
The information in this email and any attachments may contain proprietary and confidential information that is intended for the addressee(s) only. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution, retention or use of the contents of this information is prohibited. When addressed to our clients or vendors, any information contained in this e-mail or any attachments is subject to the terms and conditions in any governing contract. If you have received this e- mail in error, please immediately contact the sender and delete the e-mail.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-village.net

This email sent to [email protected]

--
Chuck Hill             Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects






_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to