Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add gravatar virtual field and author-box styling #3

Open
bobbingwide opened this Issue Nov 25, 2016 · 4 comments

Comments

Projects
None yet
1 participant
@bobbingwide
Copy link
Owner

bobbingwide commented Nov 25, 2016

Prompted by the genesis_author_box() function and related hooks, it would be nice if we could have a shortcode to display the author box in situ, or deferred.

Is it also possible to make it turn off the author box if it has already been displayed?
Can this simply be achieved with appropriate use of action and filter hooks?

Note: [bw_user] already has the capability to display a number of standard fields, but this excludes the gravatar. Oik-user could provide the gravatar virtual field type, which will use get_avatar().

@bobbingwide bobbingwide self-assigned this Nov 25, 2016

@bobbingwide bobbingwide changed the title Add [bw_author_box] shortcode Add gravatar virtual field and author-box styling Nov 26, 2016

@bobbingwide bobbingwide reopened this Dec 18, 2017

@bobbingwide

This comment has been minimized.

Copy link
Owner Author

bobbingwide commented Dec 18, 2017

Even though I closed this a year ago, I never released the shortcode examples since there was a problem formatting the default display with class=author-box.

The CSS used to hide the labels doesn't work for the Email field, where Email is displayed twice.

It's OK in the https://qw/oikcom/shortcode_example/author-box-profile/
but not right in
https://www.oik-plugins.com/oik_shortcodes/bw_user/

Also, it would be nice to have the follow_me links as a virtual field.
Should I raise a separate Issue?

Also, don't forget to update any Gravatars that are being used in the examples. e.g. http://en.gravatar.com/herbmiller

@bobbingwide

This comment has been minimized.

Copy link
Owner Author

bobbingwide commented Mar 4, 2019

Finally got around to working on this as I need it for the Person block.
bobbingwide/oik-blocks#6

Normally we want the gravatar to be displayed on the left, on its own, then the other fields in a separate column.
To support this we allow for fields to be parsed by '/' separators for the horizontal divs ( columns ) then comma for the vertical separation ( rows ).

e.g.
[bw_user gravatar/about,bio,follow_me]

@bobbingwide

This comment has been minimized.

Copy link
Owner Author

bobbingwide commented Mar 4, 2019

The Gravatar field is not displayed correctly when selected as a column in the [bw_users] shortcode. It's always the same gravatar.

@bobbingwide

This comment has been minimized.

Copy link
Owner Author

bobbingwide commented Apr 15, 2019

To support this we allow for fields to be parsed by '/' separators for the horizontal divs ( columns ) then comma for the vertical separation ( rows ).

The default set of fields to display will become /name,bio,email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.