Manila syndication error: array out of range
Jim Byrne
j.byrne at gcal.ac.uk
Wed Nov 21 09:21:47 PST 2001
on 19/11/01 3:49 pm, Jim Byrne at j.byrne at gcal.ac.uk wrote:
> I have turned on syndication for my Manila site. But when I point
> to the file
> http://www.ispn.gcal.ac.uk:81/makingconnections/xml/scriptingNews2.xml I get
> the following error message:
>
> <?xml version="1.0" ?>
> <error>Array index is out of range. The list "lines" doesn't have an item
> #3.</error>
>
> I have looked in the scriptingNews2.xml script which is in the xml table of
> my makingconnections Manila Website - but it doesn't seem to be running that
> script at all. What script is it running? How do I debug it?
>
There error is somewhere in the bundle below ( of the script
getScriptingNewsXml) - four urls are being returned and only 3 pieces of
text for the links:
on extractLinks (s, adrLinks, adrLines) {
local (links = {}, lines = {}, pat = "<a href=\"", ix, leftHalf);
s = html.processMacros (s, true, pta);
loop {
ix = string.patternMatch (pat, s);
if ix == 0 {
break};
leftHalf = string.mid (s, 1, ix - 1);
s = string.delete (s, 1, ix + sizeOf (pat) - 1);
ix = string.patternMatch ("\"", s); //the end of the url
url = string.mid (s, 1, ix - 1);
s = string.delete (s, 1, ix);
ix = string.patternMatch (">", s); //PBS 11/1/00: find end of
opening a tag
s = string.delete (s, 1, ix);
if s [1] == ">" {
s = string.delete (s, 1, 1)};
ix = string.patternMatch ("</a>", s);
lineText = string.mid (s, 1, ix - 1);
s = s - "</a>";
s = leftHalf + s;
links = links + url;
lines = lines + lineText};
adrLinks^ = links;
adrLines^ = lines;
return (s)}
Is this a bug? If so can someone look into it please.
Thanks,
Jim
--
Jim Byrne Project Director, The Making Connections Unit, Glasgow Caledonian
University, Glasgow G4 OBA, 0141 331 3893
Everything you need to know about publishing accessible information on the
Web.
Connections Disability: http://www.mcu.org.uk/
Scottish Disability Information Mailing list:
Connections Disability: http://www.mcu.org.uk/mailinglists/
More information about the Frontier-Users
mailing list