Skip to content

Fix undefined array key warning when iframe parameters are omitted and add Chinese language support - #21

Open
doge24190 wants to merge 2 commits into
Chris--S:masterfrom
doge24190:master
Open

Fix undefined array key warning when iframe parameters are omitted and add Chinese language support#21
doge24190 wants to merge 2 commits into
Chris--S:masterfrom
doge24190:master

Conversation

@doge24190

Copy link
Copy Markdown

1. Fixes #20.

When using iframe syntax without optional parameters, for example:

{{url>https://example.com}}

explode(' ', $url, 2) returns only one element. Assigning it to
list($url, $param) triggers an "Undefined array key 1" warning on PHP 8.x.

This change pads the exploded array with an empty string so $param defaults
to the expected "no parameters" value.

2. Add Chinese language support

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant