#wordpress 2022-05-24

2022-05-24 UTC
angelo, ben_thatmustbeme, jsbach, gRegor, NewNewNew, [jamesg483], [Zandy_Ring], [echo], scojjac and dronerdude joined the channel
#
dronerdude
hi everyone :)
#
dronerdude
is it OK to ask a Wordpress code question here?
[tw2113_Slack_] joined the channel
#
[tw2113_Slack_]
it is the WordPress channel after all
#
dronerdude
I have a probably fairly stupid newbie question; in a WP Code Snippet (PHP) I'd like to do some DOM editing... for instance, I have: $links = document.getElementsByTagName("a"); Error message is: document is an undefined constant
#
dronerdude
the script is hooked on 'shutdown', I figured the DOM must be rendered by then
#
dronerdude
it's probabaly a variable scope thing but I can't get my head around it
#
[tw2113_Slack_]
GWG congrats on the WP 6.0 props
#
[tw2113_Slack_]
dronerdude that looks like a mix of PHP and javascript
#
[tw2113_Slack_]
at least for what part I’ve seen so far
#
dronerdude
Actually it was just hitting me that I probably caanot change live html using php :P
#
dronerdude
And I see what you mean now, thanks
#
dronerdude
i'll try to do it with js instead
wagle joined the channel
#
GWG
[tw2113_Slack_]: I forget what I did
#
[tw2113_Slack_]
GWG probably https://core.trac.wordpress.org/changeset/53147 got you in