#wordpress 2019-11-04

2019-11-04 UTC
[fluffy] and gRegorLove_ joined the channel
#
GWG
Looks like WordPress is going to try for oauth2 with dynamic client registration
#
GWG
Oh well
#
GWG
Maybe they will write some code I might use
damidam and dmcweeney joined the channel
#
dmcweeney
I was wondering if anyone is able to help me with what might be a minor issue with my website
#
GWG
How can we help?
#
dmcweeney
If you go to my website (drewmcweeney.com), scroll down to the bottom of the page
#
dmcweeney
The two sidebars are suppose to be all gray and towards the bottom of the page there is some white showing on both sides
[asuh] joined the channel
#
[asuh]
Overwrite or remove the bottom padding on `.sidebar`
#
[asuh]
.sidebar {
#
[asuh]
padding-bottom: 20px;
#
dmcweeney
Okay let me try
#
dmcweeney
Didn't work
#
[asuh]
dmcweeney, here’s a screenshare of what i did in devtools.
#
dmcweeney
I see-How do I get it to change on my website? Do I have to enter it in CSS?
#
[asuh]
easy answer, yes, you have to update your css.
#
[asuh]
hard answer, your css has been minified and probably converted from a preprocessor. do you know how to set up your theme to properly edit the original css and compile it down to the minified version to overwrite it?
#
[asuh]
scratch that, i made a bad assumption. it appears your file called `main.min.css` is not minified even though the file says it is. so it can be edited without much problem.
#
dmcweeney
So how would I edit it? Would I click on the customize button and then enter CSS in the CSS box?
#
[asuh]
that’s one way to do it, yes.
#
dmcweeney
What would be the CSS I enter or modify/delete?
#
[asuh]
but that will not overwrite the original, just override. you can add this:
#
[asuh]
.sidebar {
#
[asuh]
padding-bottom: 0;
#
dmcweeney
Perfect. Now how do I get the other sidebar on the right to do the same?
#
dmcweeney
Is it .sidebar.s2?
#
[asuh]
yes, but it’s more complicated
#
dmcweeney
What would I enter?
#
dmcweeney
What would I enter?
#
[asuh]
you’ll add three rules
#
[asuh]
.main-inner.group {
#
[asuh]
display: flex;
#
[asuh]
@media (min-width: 1200px) {
#
[asuh]
.content {
#
[asuh]
order: 1;
#
[asuh]
.sidebar-content {
#
[asuh]
height: 100%;
#
dmcweeney
I'm confused
#
dmcweeney
Okay I entered it all in and it is showing a red X for the line @media ... etc
#
[asuh]
dmcweeney, does your customizer looks like this?
#
dmcweeney
Okay I did everything and have it exactly like what you put and it didn't do anything
#
[asuh]
dmcweeney, you left off the % from .sidebar-content
#
dmcweeney
Got it! It worked. Now, my next question is: how do I get the music widgets to expand?
#
[asuh]
awesome! not sure about music widgets. i guess you’re talking about apple
#
[asuh]
dmcweeney, hopefully you’re looking to install some Indieweb plugins in addition to all of this.
#
dmcweeney
Yeah absolutely-I entered in the music widget code through CSS
#
dmcweeney
Is it something I would change with that?
#
[asuh]
min-height: 290px;
#
[asuh]
.widget iframe[src*=“embed.apple.com”] {
#
[asuh]
oh, change to embed.music.apple.com
#
dmcweeney
I'm not following
#
dmcweeney
I'm sorry if I sound stupid
#
[asuh]
.widget iframe[src*=“embed.music.apple.com”] {
#
[asuh]
min-height: 290px;
#
dmcweeney
Do I type that in CSS or where I copied and pasted the HTML for widget?
#
[asuh]
below the other code in Customizer
#
dmcweeney
It is showing an red X
#
dmcweeney
does iframe go first of the word .widget?
#
[asuh]
i think it’s the quotation marks.
#
dmcweeney
Do you see how I entered it?
#
dmcweeney
Should .widget come first and iframe is the next line or should it be .widget iframe ... etc?
#
[asuh]
the way I wrote it is the correct order, yes
#
dmcweeney
Do you see how I entered it? It is showing me an red X still
#
dmcweeney
It says "expected RBRACKET at line 191, col. 27"
#
[asuh]
I’d retype everything manually just to make sure
#
[asuh]
i don’t see it in your code
#
dmcweeney
It is not letting me save the code because it is saying the red X
#
dmcweeney
Can you show me what you are talking about using imgur?
#
GWG
Been a bit sporadic tonight, making my descent
#
GWG
Hi, [asuh]
#
[asuh]
good evening, GWG, how goes it?
#
dmcweeney
Perfect! It worked! So if I wanted it to extend longer, what would I change? Right now I see the scroll bar on the right (first widget top left under #culture)
#
GWG
Returning from WordCamp
#
Loqi
[David Shanske] Just hacked up a script using Tasker for Android that extracts the location from the Southwest inflight wifi and posts it to my location tracking server… which is queried by my website. Fun
#
[asuh]
GWG, I saw some of the chatter about it. good talks? good progress with Indieweb + WordPress? Indieauth sounds like there’s some drama in what’s gonna happen
#
GWG
[asuh]: They had a talk about finally building authentication into WordPress. OAuth2.
#
[asuh]
dmcweeney, you can increase or decrease the number “290px” as needed. It’s a universal number that targets all of the widgets, so you can find another class that’s specific to the widget and target the iframe that way
#
GWG
Lots of interest in tantek's talk
#
GWG
It didn't translate as much into concrete questions about installation though
#
[asuh]
Chris mentioned in a new blog post he’s gonna take Tantek’s talk to the beginners level, probably with installation and such. So it’ll be a complementary talk in Riverside
#
GWG
I saw. I have work to do to improve the experience
#
[asuh]
Your plugin consolidation work will be good for UX improvement
#
GWG
It will be slow
gRegorLove_ joined the channel
#
[asuh]
understandably
#
GWG
I also have to get consensus
#
GWG
Avatar handling already moved
gRegorLove_ joined the channel
#
[asuh]
oh, i need to review your blog post to see what the avatar changes are
#
GWG
The avatar code was simplified, rewritten and added to the webmention plugin
#
[asuh]
I really like the idea of not having to go to Gravatar for the avatars when possible
#
[asuh]
locally cached avatars is good for performance
[chrisaldrich] and [manton] joined the channel
#
GWG
[asuh]: I got into a debate with someone who didn't think so
#
[asuh]
what was his opinion?
#
Loqi
It looks like we don't have a page for "his opinion" yet. Would you like to create it? (Or just say "his opinion is ____", a sentence describing the term)
#
GWG
He liked gravatar handling everything
#
GWG
[asuh]: pfefferle I believe had a proof of concept for storing avatars in a cache to prevent blank spots on sites.
#
[asuh]
i agree with caching things locally when possible. the less 3rd-party domains websites have to make calls to, the better for performance most of the time
#
GWG
[asuh]: With gravatar, it only caches under very specific circumstances
#
[asuh]
but, i understand the idea of what a CDN can do for performance in areas that aren’t close to the server
#
[asuh]
GWG would it be possible for the cached avatar to be served as inline SVG?
#
GWG
[asuh]: Right now we aren't caching the avatar, we are only caching whether an avatar exists
#
GWG
But once there is a cache, anything is theoretically possible
#
[asuh]
GWG, so the one coming from `wp-content/plugins/semantic-linkbacks/img/mm.jpg`can’t be pulled by default for comments that aren’t associated with something already?
#
GWG
That's happening now
#
GWG
It is not an svg though
#
[asuh]
ok that’s what i was referring to by cached avatar
#
[asuh]
instead of serving the JPG, this could just as easily be inline SVG to avoid the request
#
GWG
The file is pulled by webmentions if there's no email or no gravatar
#
[asuh]
that makes sense. i thought that was the cached avatar itself
#
GWG
That's harder because of how get_avatar works
#
[asuh]
ok, probably not worth the trouble to implement
[fluffy], maxwell, [schmarty], [frank], gRegorLove_, [jgmac1106], [jeremycherfas], [KevinMarks] and [chrisbergr] joined the channel
#
[chrisbergr]
On the side I am working on a plugin that has local stored avatars for the users and will copy the avatars/gravatars from the comments. The biggest problem that is delaying me right now is the upload into custom folders from the Edit Profile.
#
[chrisbergr]
There is also the possibility to upload several avatars for one user, from which they can then choose one when posting. But that's irrelevant to the discussion above.
#
beko[m]
👍️
[LewisCowles] joined the channel
#
GWG
Caching is a different design than custom avatars, though similar
#
[chrisbergr]
Oh, thats true, David. I just wanted to mention that it's going in a similar direction.
#
[chrisbergr]
My reason for this: tbh I don't care where the avatars are stored. gravatar, other webseite, my website... But now that the GDPR has become even stricter, related to cookies, I can no longer ignore this situation.
#
[chrisbergr]
And even I dont care about my own data privacy, I'll do everything I can to protect the privacy of my users.
#
[chrisbergr]
One simple step is to cut all connections to 3rd party sites, including gravatar, webfonts, analytics...
#
GWG
[chrisbergr]: I had a conversation with someone at WordCamp who loves gravatar and doesn't see the point in changing it
#
[chrisbergr]
And because I hate those cookie consensus banners, I'm also going to prevent all cookies. -But that's not so easy with WordPress.
#
GWG
Cookie banners are useless
#
[chrisbergr]
Actually they are. But regarding to the eu rights, I must not write one single cookie before the user opt in
#
[chrisbergr]
I tried some ways. A script to prevent all javasripts from writing cookies, but I can not affect 3rd party scripts. A php script to prevent php from writing cookies, but because there is no wp function like for the db queries, it's almost not possible to prevent all ways..
#
GWG
Yes, I am in favor of some parts of European privacy rules, but some are not thought out
[grantcodes] joined the channel
#
[grantcodes]
That's not quite true I don't think. If they are required my the website to function you don't have to make them opt in.
#
[chrisbergr]
[grantcodes] that's right. in detail. Cookies like session cookies for webshops are one case of required cookies. But gravatar and analytics are not. And in case of typekit or google fonts idk.
#
beko[m]
[chrisbergr]: mine sets no cookies as well so I don't display any banner. This is as long as you don't log in. I don't show links to login or comment boxes at all as well. If someone knows WP it can be triggered manually, oc. Don't care in that case.
#
[chrisbergr]
beko: this is exactly what I want. Some plugins are still a problem. But: https://beko.famkos.net/author/beko/page/4/ chrome dev tools -> Application -> Cookies tells me, there is a cookie.
#
Loqi
Beko Pharm
#
beko[m]
[chrisbergr]: I see. It's from fireside due to an avatar. I hate this. No idea how to solve this. I started to mirror avatars manually _if_ I can dig out a free image BUT that is a PITA to do.
#
beko[m]
Killed it, thanks for notice.
#
[chrisbergr]
I've written a function in my previous self written system
#
[chrisbergr]
public function copy_imge( $image, $path = '' ) {
#
[chrisbergr]
$uploads_dir = EXPLORER_ABSPATH . '/public/uploads/' . $path;
#
[chrisbergr]
$type = "jpg";
#
[chrisbergr]
if ( strpos( $image, '.gif' ) !== false ) {
#
[chrisbergr]
$type = "gif";
#
[chrisbergr]
if ( strpos( $image, '.png' ) !== false ) {
#
[chrisbergr]
$type = "png";
#
[chrisbergr]
$filename = md5( $image ) . "." . $type;
#
[chrisbergr]
if ( ! file_exists( $uploads_dir . $filename ) ) {
#
[chrisbergr]
copy( $image, $uploads_dir . $filename );
#
[chrisbergr]
I'll use this as a boilerplate for a filter used every time a avatar is displayed on my page.
#
[chrisbergr]
*an avatar
#
beko
It's not that easy. Re-distributing is also kinda grey and while probably fair use (that does not apply in the EU) there are _some_ avatars I really don't even _want_ on my server.
#
[chrisbergr]
Displaying a tweet from someone else without their knowledge is also at least... not that easy. So yes, I understand your point.
#
beko
Killing auto preview and iframe is also already a task. That emoji stuff for example WP does.
#
beko
I really start to understand the static page ppl
#
GWG
I tried to be aware of it in my plugins, even if I am not legally bound per se
#
[chrisbergr]
I'm starting to hate that whole GDPR crap. For us small web page operators who want to do their own little cool stuff without harming anyone suffer from the trash of others, big and powerful. But I do not want to start any discussion here now, certainly not in the wordpress chat.
#
GWG
I just feel I should respect people's preferences
#
GWG
I wrote my privacy policy on my site
#
[chrisbergr]
That's great, David 🙂
#
GWG
If you want me to take something down referencing you, I will is the basic idea
#
[chrisbergr]
But I think you're still using font awesome with 3rd party domain, right?
#
[chrisbergr]
*in some of your plugins
#
beko
Same. I wish I could simply kill foreign cookies via Access-Control but that's all client side ._.
#
beko
Copying the avatar is probably the best way :/ They sneak in again and again otherwhise.
#
GWG
[chrisbergr]: No, I store my icons locally
#
GWG
I do not serve them from font awesome
#
[chrisbergr]
That helps alot, thanks 🙂
#
[chrisbergr]
@beko Yes, as I said, I'll do this. And if someone ask me to remove their image, I'll overwrite the url with mystery man so it won't be copied again.
#
beko
Started do to the same :D Using from semantic-linkbacks so I'll be very sorry if that path changes someday :D
#
beko
Will probably plug it with a rewrite then
#
GWG
beko, it has already
#
GWG
But it does backcompat
#
beko
👍
#
beko
You really put a lot of thoughts in your plugins, GWG++
#
Loqi
GWG has 75 karma in this channel over the last year (144 in all channels)
#
[chrisbergr]
I'm using a very old version of semantic linkbacks because I tried to implement templating functionality and now I'm using this templates on my page ^^
#
[chrisbergr]
btw: https://github.com/pfefferle/wordpress-semantic-linkbacks/issues/210#issuecomment-473667645 David, do you remember your idea mentioned in this comment? Have you evaluated something since then?
#
Loqi
[dshanske] I like the idea, but have a slightly different idea on implementation.
[Inigo_Garcia] joined the channel
#
GWG
Yee, we're just behind on moving functionality over to Webmentions
#
[chrisbergr]
I am very curious 🙂
#
beko
same.
[KevinMarks], emraeshine, gRegorLove_, [jgmac1106], [qubyte], [chrisaldrich] and [tonz] joined the channel
#
[tonz]
It seems the Mastodon Autopost WP plugin has trouble with scheduled post. Those get posted to Mastodon when the post goes live even if doing posting to Mastodon isn’t selected as option.
amimDiscord[m], [manton], [Jeannie], [chrisaldrich], yalangctc, [fluffy], [chrisbergr], [tantek], [bradleyallen], [jgmac1106] and jeremycherfas joined the channel