Property Sets: Fatal error due export!

Hello everybody!

I detected 2 fatal errors on “Contexts Property Sets” when exporting to a file.

  1. Error:
    If you have a hashtag (#) somewhere within a property (even inside the comment field!) and you try to export the complete set, MODX shuts down and returns the following error message:
    {"success":false,"message":"Access denied.","total":0,"data":[],"object":{"code":401}}

  2. Error:
    When you want to export a bigger property set, the server interrupts the connection with the following error message:
    "Request-URI Too Long (The requested URL's length exceeds the capacity limit for this server.)"
    To solve this problem, you must increase the “LimitRequestLine” on the apache server!
    This is a question for the MODX developer team: It seems, that MODX exchanges it’s data via GET - if so, wouldn’t it be better to send them via POST?

The scenario:
(Running MODX 2.7.2 “traditional” locally on an older machine for some dev’s with PHP 7.4 via XAMP/Apache Server).
I collected a bunch of possible META-Tags for the templates header which I like to embed via different property sets resp. with the ability to adjust some parameters if required. All together I have about 20 entries (common text fields, plus some option lists, plus some yes/no toggles). The saved file size is about 8 KB - this is too much for the default apache limitations! I have a setting for the Apple-META “theme-color” with e.g. content="#000000" - this can’t be done because of the hashtag problem!

Another (little) stumbling block is, that you get stuck when you write HTML-Tags with attributes inbetween quotation marks into an option list! It seems, that MODX has problems, to compare the default value with the list items when they are too long or too complex. I tried first, to collect a list of complete META-Tags as options - fault! To solve this problem, you must prepare the HTML-Tags static and insert only the varying attribute data (I can live with that).

Greetings to all from Dresden (Saxonia, Germany) - yours:
ejomi

Yeah, POST would definitely be preferable. I reckon using GET is also the reason you’re getting the first error with the # because that has special meaning in URLs.