{"action":"created","issue":{"url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/issues/1189","repository_url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS","labels_url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/issues/1189/labels{/name}","comments_url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/issues/1189/comments","events_url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/issues/1189/events","html_url":"https://github.com/ILIAS-eLearning/ILIAS/pull/1189","id":361244041,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE2MjYyNzEz","number":1189,"title":"Use new inputs from UI-framework in Study Programme","user":{"login":"klees","id":10611082,"node_id":"MDQ6VXNlcjEwNjExMDgy","avatar_url":"https://avatars0.githubusercontent.com/u/10611082?v=4","gravatar_id":"","url":"https://api.github.com/users/klees","html_url":"https://github.com/klees","followers_url":"https://api.github.com/users/klees/followers","following_url":"https://api.github.com/users/klees/following{/other_user}","gists_url":"https://api.github.com/users/klees/gists{/gist_id}","starred_url":"https://api.github.com/users/klees/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/klees/subscriptions","organizations_url":"https://api.github.com/users/klees/orgs","repos_url":"https://api.github.com/users/klees/repos","events_url":"https://api.github.com/users/klees/events{/privacy}","received_events_url":"https://api.github.com/users/klees/received_events","type":"User","site_admin":false},"labels":[{"id":546850796,"node_id":"MDU6TGFiZWw1NDY4NTA3OTY=","url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/labels/improvement","name":"improvement","color":"fbca04","default":false}],"state":"open","locked":false,"assignee":{"login":"klees","id":10611082,"node_id":"MDQ6VXNlcjEwNjExMDgy","avatar_url":"https://avatars0.githubusercontent.com/u/10611082?v=4","gravatar_id":"","url":"https://api.github.com/users/klees","html_url":"https://github.com/klees","followers_url":"https://api.github.com/users/klees/followers","following_url":"https://api.github.com/users/klees/following{/other_user}","gists_url":"https://api.github.com/users/klees/gists{/gist_id}","starred_url":"https://api.github.com/users/klees/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/klees/subscriptions","organizations_url":"https://api.github.com/users/klees/orgs","repos_url":"https://api.github.com/users/klees/repos","events_url":"https://api.github.com/users/klees/events{/privacy}","received_events_url":"https://api.github.com/users/klees/received_events","type":"User","site_admin":false},"assignees":[{"login":"klees","id":10611082,"node_id":"MDQ6VXNlcjEwNjExMDgy","avatar_url":"https://avatars0.githubusercontent.com/u/10611082?v=4","gravatar_id":"","url":"https://api.github.com/users/klees","html_url":"https://github.com/klees","followers_url":"https://api.github.com/users/klees/followers","following_url":"https://api.github.com/users/klees/following{/other_user}","gists_url":"https://api.github.com/users/klees/gists{/gist_id}","starred_url":"https://api.github.com/users/klees/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/klees/subscriptions","organizations_url":"https://api.github.com/users/klees/orgs","repos_url":"https://api.github.com/users/klees/repos","events_url":"https://api.github.com/users/klees/events{/privacy}","received_events_url":"https://api.github.com/users/klees/received_events","type":"User","site_admin":false}],"milestone":null,"comments":3,"created_at":"2018-09-18T10:45:03Z","updated_at":"2018-10-04T14:52:56Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/pulls/1189","html_url":"https://github.com/ILIAS-eLearning/ILIAS/pull/1189","diff_url":"https://github.com/ILIAS-eLearning/ILIAS/pull/1189.diff","patch_url":"https://github.com/ILIAS-eLearning/ILIAS/pull/1189.patch"},"body":"This shows how a switch from `Service\\Form` to the new inputs from the UI-framework might look like. Although I'm the maintainer of the SP (and thus may just merge this) I decided to open a PR to give others the possibility to scrutinize the changes, since this basically is the first time the new input-API is used in a real scenario. Thus I'm very interested in the stuff you like or dislike in the new code-wise appearance of forms and inputs and also in the questions you might have."},"comment":{"url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/issues/comments/427049579","html_url":"https://github.com/ILIAS-eLearning/ILIAS/pull/1189#issuecomment-427049579","issue_url":"https://api.github.com/repos/ILIAS-eLearning/ILIAS/issues/1189","id":427049579,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNzA0OTU3OQ==","user":{"login":"klees","id":10611082,"node_id":"MDQ6VXNlcjEwNjExMDgy","avatar_url":"https://avatars0.githubusercontent.com/u/10611082?v=4","gravatar_id":"","url":"https://api.github.com/users/klees","html_url":"https://github.com/klees","followers_url":"https://api.github.com/users/klees/followers","following_url":"https://api.github.com/users/klees/following{/other_user}","gists_url":"https://api.github.com/users/klees/gists{/gist_id}","starred_url":"https://api.github.com/users/klees/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/klees/subscriptions","organizations_url":"https://api.github.com/users/klees/orgs","repos_url":"https://api.github.com/users/klees/repos","events_url":"https://api.github.com/users/klees/events{/privacy}","received_events_url":"https://api.github.com/users/klees/received_events","type":"User","site_admin":false},"created_at":"2018-10-04T14:52:56Z","updated_at":"2018-10-04T14:52:56Z","author_association":"MEMBER","body":"Hi @mjansenDatabay,\r\n\r\nI fixed the `Select Field` in [this PR](https://github.com/ILIAS-eLearning/ILIAS/pull/1203).\r\n\r\nThen I had a long long look into `ilUtil::stripSlashes`. At some point it looked back and I got horrified. As far as I understood up to this point, the `Service\\Form` only ever calls `stripSlashes` without parameters (with one exception, which is the `EMailInputGUI` we currently are not implementing in the UI-Framework).\r\n\r\n[`ilUtil::stripSlashes`](https://github.com/ILIAS-eLearning/ILIAS/blob/release_5-3/Services/Utilities/classes/class.ilUtil.php#L2655) checks the deprecated ini-setting `magic_quotes_gpc` and calls `stripslashes` if it is present. This IMHO won't be the case, so `stripslashes` will not be called (and the name of the method is lying). Do you consider it necessary that `stripslashes` gets called on general input? Why?\r\n\r\nThus `ilUtil::stripSlash` basically is the same as [`ilUtil::secureString`](https://github.com/ILIAS-eLearning/ILIAS/blob/release_5-3/Services/Utilities/classes/class.ilUtil.php#L2689). Since `$a_allow = \"\"`, [this branch](https://github.com/ILIAS-eLearning/ILIAS/blob/release_5-3/Services/Utilities/classes/class.ilUtil.php#L2696) won't be executed and the execution will run into [that branch](https://github.com/ILIAS-eLearning/ILIAS/blob/release_5-3/Services/Utilities/classes/class.ilUtil.php#L2711) and set `$allow_array` to some tags. The function then attempts to remove all but the allowed tags, [this branch here](https://github.com/ILIAS-eLearning/ILIAS/blob/release_5-3/Services/Utilities/classes/class.ilUtil.php#L2733) won't be executed.\r\n\r\nSo, as far as I understand that stuff, the usage of `stripSlashes` boils down to removing all but some HTML-Tags from the input. We have `HTMLPurifier` for that exact use case, right? So IMO a good way forward would be to implement a transformation that strips all but the allowed tags from some string using `HTMLPurifier` and attach that to `Text Field` and `Textarea Field` per default.  Any opinion? Would you help me to teach `HTMLPurifier` that trick?\r\n\r\nBest regards! "}}
{"actor":{"display_login":"klees"}}