Re: AjaxUtils.redirectTo() and IE7
Re: AjaxUtils.redirectTo() and IE7
- Subject: Re: AjaxUtils.redirectTo() and IE7
- From: Sacha Michel Mallais <email@hidden>
- Date: Thu, 14 Jan 2010 07:58:55 -0800
On Jan 13, 2010, at 1:57 AM, Amedeo Mantica wrote:
I Sasha,
seem to work on IE 7.0.5730.13
I get the umich login page
Yes, the error actually occurs after the login page. Unfortunately,
this site is being protected by UMich's Cosign so I can't give you a
login to try it (and our other, non-UMich test site is down at the
moment).
It looks like the error is generated from this return Element... (at
least, it is line 4176 in prototype.js, the Char 5 doesn't make a lot
of sense, though):
optionValue: function(opt) {
return Element.extend(opt).hasAttribute('value') ? opt.value :
opt.text;
}
Which looks like it is part of this code block:
--------------------------------------------------------------
Form.Element.Serializers = {
input: function(element, value) {
switch (element.type.toLowerCase()) {
case 'checkbox':
case 'radio':
return Form.Element.Serializers.inputSelector(element, value);
default:
return Form.Element.Serializers.textarea(element, value);
}
},
inputSelector: function(element, value) {
if (Object.isUndefined(value)) return element.checked ?
element.value : null;
else element.checked = !!value;
},
textarea: function(element, value) {
if (Object.isUndefined(value)) return element.value;
else element.value = value;
},
select: function(element, value) {
if (Object.isUndefined(value))
return this[element.type == 'select-one' ?
'selectOne' : 'selectMany'](element);
else {
var opt, currentValue, single = !Object.isArray(value);
for (var i = 0, length = element.length; i < length; i++) {
opt = element.options[i];
currentValue = this.optionValue(opt);
if (single) {
if (currentValue == value) {
opt.selected = true;
return;
}
}
else opt.selected = value.include(currentValue);
}
}
},
selectOne: function(element) {
var index = element.selectedIndex;
return index >= 0 ? this.optionValue(element.options[index]) :
null;
},
selectMany: function(element) {
var values, length = element.length;
if (!length) return null;
for (var i = 0, values = []; i < length; i++) {
var opt = element.options[i];
if (opt.selected) values.push(this.optionValue(opt));
}
return values;
},
optionValue: function(opt) {
return Element.extend(opt).hasAttribute('value') ? opt.value :
opt.text;
}
};
--------------------------------------------------------------
Unfortunately, my JS-fu is weak, so I'm not able to suss what might be
wrong here.
Anyone have any ideas?
sacha
On 12/gen/2010, at 19.17, Sacha Michel Mallais wrote:
Hi all,
Has anyone had any issues with using AjaxUtils.redirectTo() with
IE7? I'm getting this error on each page that uses redirectTo() on
IE7 (typed by hand due to IE7 lameness, please excuse typos):
-----------------------------------------------
Line: 4176
Char: 5
Error: Object doesn't support this property or method
Code: 0
URL: https://test.global-village.net/apps/WebObjects/SMTest.woa/wa/218.0.9.1.1.1.1
-----------------------------------------------
... and the page doesn't redirect, it just sits there, and the rest
of the Ajax on the page no longer works.
The code I use to redirect is:
-----------------------------------------------
public WOComponent sectionRepetitionObserverAction()
{
if (selectedSectionAction.count() > 0)
{
// should only be a single key and value in the dictionary
aSection = (Section)
selectedSectionAction.allKeys().lastObject();
String actionForCurrentSection = (String)
selectedSectionAction.objectForKey(aSection);
if ("Edit Content".equals(actionForCurrentSection))
{
AjaxUtils.redirectTo(editSection());
return null;
}
....
[snip]
-----------------------------------------------
Where editSection() returns an initialized component.
This is under WO 5.4.3, the latest Wonder ("svn up" at 2:00pm
Monday).
Anyone have any ideas why this is not working? My client claims it
was working a week or two ago, but I didn't touch any of this
stuff, so I'm even more confused...
sacha
--
Sacha Michel Mallais 400 kg chimp
Global Village Consulting Inc. http://www.global-village.net/
PGP Key ID: 7D757B65 AIM: smallais
"Choke on that, causality!" -- the Professor, "Futurama"
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
--
Sacha Michel Mallais Senior Developer / President
Global Village Consulting Inc. http://www.global-village.net/
PGP Key ID: 7D757B65 AIM: smallais
A plan without a schedule is just a dream. -- Chuck Hill
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden