Module:Redirect: Difference between revisions

The dang things can be either upper or lower case
m (line breaks to keep long comment from side-scrolling)
(The dang things can be either upper or lower case)
Line 29: Line 29:
       --  if rpage.fileExists then
       --  if rpage.fileExists then
             if rpage.isRedirect then
             if rpage.isRedirect then
               return (bb.. tostring(mw.ustring.match(tostring(rpage.getContent(rpage)),"REDIRECT.-%[%[(.-)%]%]")..be) or [=[<span style="text-color:red;">[[Module:redirect]] error: failed to understand - [[]=] .. rname .. [=[]]</span]=])
               return (bb.. tostring(mw.ustring.match(tostring(rpage.getContent(rpage)),"[Rr][Ee][Dd][Ii][Rr][Ee][Cc][Tt].-%[%[(.-)%]%]")..be) or [=[<span style="text-color:red;">[[Module:redirect]] error: failed to understand - [[]=] .. rname .. [=[]]</span]=])
             else return rname -- not a redirect so leave the original text (for some general-purpose template use)
             else return rname -- not a redirect so leave the original text (for some general-purpose template use)
             end
             end
Anonymous user