[tei-council] Uploading files to the WIKI (fwd)

Martin Holmes mholmes at uvic.ca
Sun Nov 4 23:17:29 EST 2012


I'm feeling a bit guilty about how much effort David and James are 
putting into this now. I figured it was just a setting that got 
inadvertently turned off. If it's not straightforward, please don't put 
any more time into it.

Cheers,
Martin

On 12-11-04 06:17 PM, David Sewell wrote:
> Sorry: having just created a temporary wiki account lacking
> administrator privileges, I see that upload of the XML file is not only
> warned but prevented.
>
> It may be that upgrading WikiMedia is the only fix. But I'll poke around
> some more as well.
>
> David
>
> On Sun, 4 Nov 2012, David Sewell wrote:
>
>> I am getting the same error message. But it is totally ignorable, no?
>>
>> Here is all that I did:
>>
>> 1) Click "Upload file" in sidebar.
>>
>> 2) Upload a random XML file on my machine called Test.xml
>>
>> 3) The file uploads, and produces a file page that indeed contains an ominous
>> warning:
>>
>> http://wiki.tei-c.org/index.php/File:Test.xml
>>
>> but it doesn't prevent the file from being opened:
>>
>> http://wiki.tei-c.org/images/d/d1/Test.xml
>>
>> or referenced:
>>
>> http://wiki.tei-c.org/index.php/User:DavidSewell
>>
>> (click on link in last line).
>>
>> If an ordinary registered user can do that, we have no problem, I think.
>>
>> David
>>
>> On Sun, 4 Nov 2012, James Cummings wrote:
>>
>>>
>>> Bah I've hacked and hacked and hacked and not been able to solve this.
>>>
>>> I went through includes/SpecialUpload.php commenting out *all* the checks
>>> it does on mimetype, on whether it is an HTML file, javascript, etc. ...
>>> ihad huge functions  doing absolutely nothing but returning that everything
>>> was ok.
>>>
>>> *still* same error message.
>>>
>>> I give up until after the members meeting if you or shayne haven't fixed it
>>> by then. ;-)
>>>
>>> -James
>>>
>>>
>>> On 04/11/12 18:46, David Sewell wrote:
>>>> James,
>>>>
>>>> Thanks for tweaking the MediaWiki settings! And if anyone
>>>> continues to have problems uploading files that should be
>>>> legitimately accepted we can investigate further.
>>>>
>>>> On Sun, 4 Nov 2012, James Cummings wrote:
>>>>
>>>>>
>>>>> David (Council CC'ed),
>>>>>
>>>>> This is actually a different problem. We've always had the
>>>>> permitted file types: png, gif, jpg, jpeg, ogg, zip, xsl, xml,
>>>>> dtd, odd, rnc, rng, txt, pdf. It is just an earlier upgrade on
>>>>> media wiki introduced script checking where it (falsely)
>>>>> identifies TEI files as potentially dodgy HTML or javascript.
>>>>> I've not investigated how it does this check and why it is
>>>>> failing, but found a number of reported  bugs about it.
>>>>>
>>>>> I've set $wgDisableUploadScriptChecks to true, and explicitly
>>>>> marked non-registered users as not being able to upload (though
>>>>> I think this was our default any way).  Piotr and Kevin will
>>>>> probably advise if this results in people who shouldn't being
>>>>> able to upload files.
>>>>>
>>>>> It allowed me to, but I might have special powers.
>>>>>
>>>>> Lou: We're not talking about uploading and processing TEI files
>>>>> of any particular type, but just uploading XML files in the
>>>>> same way you might upload PDFs or PNGs, etc.  Frankly if I was
>>>>> Martin I'd probably just link to the XML file provided elsewhere.
>>>>>
>>>>> -James
>>>>>
>>>>> On 04/11/12 13:52, David Sewell wrote:
>>>>>> During the last upgrade of the TEI wiki, we ran into a PHP issue
>>>>>> or two that required changes to files on the server that were
>>>>>> root-access only, meaning Shayne needed to intervene. If that's
>>>>>> the case this time, a fix will probably need to wait until
>>>>>> Monday. But I'll take a look at things when I can today--may not
>>>>>> be until evening as I have a commitment earlier.
>>>>>>
>>>>>> On Sun, 4 Nov 2012, Piotr Bański wrote:
>>>>>>
>>>>>>> Hi Martin,
>>>>>>>
>>>>>>> It might have been inadvertently changed during the upgrade of
>>>>>>> the wiki
>>>>>>> software (veeery useful, it fixed a few problems, spambots among
>>>>>>> others). David has done a great wizarding job on that,
>>>>>>> hopefully he can
>>>>>>> help with the file upload issue as well.
>>>>>>>
>>>>>>>   P.
>>>>>>>
>>>>>>> On 04/11/12 03:19, Martin Holmes wrote:
>>>>>>>> Hi all,
>>>>>>>>
>>>>>>>> I'm working on my Prefix Definition Proposal on the wiki, and
>>>>>>>> I've
>>>>>>>> drafted a new section of the Guidelines that I wanted to
>>>>>>>> include as part
>>>>>>>> of the proposal. This is a regular TEI file, including a div
>>>>>>>> which could
>>>>>>>> be inserted into the SA chapter. It's obviously easier to
>>>>>>>> write it
>>>>>>>> directly in TEI, and then insert it into the chapter if and
>>>>>>>> when it gets
>>>>>>>> approval, than to draft it in a word-processor and then have
>>>>>>>> to tag it
>>>>>>>> up afterwards.
>>>>>>>>
>>>>>>>> I wanted to upload this to the wiki so people could vet it,
>>>>>>>> but when I
>>>>>>>> tried to upload it as an XML file, the wiki said:
>>>>>>>>
>>>>>>>> "This file contains HTML or script code that may be erroneously
>>>>>>>> interpreted by a web browser."
>>>>>>>>
>>>>>>>> So I tried zipping it up (as I've done before with a script
>>>>>>>> file). This
>>>>>>>> time, it said:
>>>>>>>>
>>>>>>>> "Files of the MIME type "application/zip" are not allowed to
>>>>>>>> be uploaded."
>>>>>>>>
>>>>>>>> But the wiki upload page also says:
>>>>>>>>
>>>>>>>> "Permitted file types: png, gif, jpg, jpeg, ogg, zip, xsl,
>>>>>>>> xml, dtd,
>>>>>>>> odd, rnc, rng, txt, pdf."
>>>>>>>>
>>>>>>>> In other words, it's supposed to be able to accept both XML
>>>>>>>> and zip
>>>>>>>> files, but it won't. Someone or something must have changed
>>>>>>>> the settings
>>>>>>>> since I last uploaded a zip file last year, but not changed
>>>>>>>> the text of
>>>>>>>> the page which explains the limitations.
>>>>>>>>
>>>>>>>> I think a TEI wiki that doesn't allow us to upload XML files
>>>>>>>> is a bit
>>>>>>>> ridiculous. Could we get this changed?
>>>>>>>>
>>>>>>>> Cheers,
>>>>>>>> Martin
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>
>>>
>>>
>>
>>
>


More information about the tei-council mailing list