Posts: 6,266
Threads: 181
Joined: Sep 2011
2014-07-31, 00:56:02
I need to know any plugins that use
html-editor-init hook
This hook no longer applies in 3.4, but I will try to make it continue to work if possible.
Also what uses front end languages ?
How are they set are you using core functions and global $LANG or your own lang variables ? Where is the lang coming from ? querystring?
And when do you set it, via hook, etc.
The structure of globals and constants is also changing in 3.4, but will retain any functionality I can.
Posts: 3,491
Threads: 106
Joined: Mar 2010
html-editor-init is used by the I18N plugin (at i18n_navigation.php), don't know about other plugins (and it seems that no other I18N_* plugins do)
AFAIK mvlcek's I18N_* plugins use (own) global $language
Posts: 40
Threads: 5
Joined: May 2015
2020-08-06, 18:59:16
(This post was last modified: 2020-08-06, 19:00:01 by Knobbles.)
Hi,
what is the current situation here?
I am writing a plugin for the edit page that currently uses html-editor-init.
The reason is that I need a place on the edit page that is outside the edit form (because it renders its own form), but before the footer.
I would like to have this compatible in the future. On Github I see that there are some more hooks planned for 3.4, but none of them is available now.
So what can I do to stay compatible?
Best would probably be to somehow find out whether html-editor-init is still supported, and if not use a different hook (perhaps edit-body)?
Or should I simply hook on both, because there will always be only one of them being supported?
Thank you very much!
Posts: 515
Threads: 21
Joined: Feb 2019
Hi,
Have a look how this is used in i18n_navigation.php it will give you an example on how to use it in GS 3.4
Posts: 6,266
Threads: 181
Joined: Sep 2011
what do you need to do ?
For html and code editors you simply have to add a class, its all automatic in 3.4
or are you trying to insert stuff at a hook ?
Posts: 40
Threads: 5
Joined: May 2015
(2020-08-07, 01:49:26)Felix Wrote: Hi,
Have a look how this is used in i18n_navigation.php it will give you an example on how to use it in GS 3.4
Thank you Felix,
I will have a look. I always love to learn from better people and from existing code.
Posts: 40
Threads: 5
Joined: May 2015
2020-08-07, 04:17:10
(This post was last modified: 2020-08-07, 17:46:18 by Knobbles.)
(2020-08-07, 02:08:05)shawn_a Wrote: what do you need to do ?
For html and code editors you simply have to add a class, its all automatic in 3.4
or are you trying to insert stuff at a hook ?
Yes, I add stuff there (a kind of modal popup with a form, initially hidden, but activated on demand). That is the reason why edit-extras is the wrong place for it.
Edit:
I solved it the other way now.
Added it in footer hook, later on move it past the edit form with jquery.
Both will still exist unchanged in 3.4.
Thank you very much.
Posts: 6,266
Threads: 181
Joined: Sep 2011
edit-content after page edit content html output
3.4 also has a tab interface and the ability to add tabs