GRAYBYTE WORDPRESS FILE MANAGER6869

Server IP : 149.255.58.128 / Your IP : 216.73.216.66
System : Linux cloud516.thundercloud.uk 5.14.0-427.26.1.el9_4.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jul 17 15:51:13 EDT 2024 x86_64
PHP Version : 8.2.28
Disable Function : allow_url_include, apache_child_terminate, apache_setenv, exec, passthru, pcntl_exec, posix_kill, posix_mkfifo, posix_getpwuid, posix_setpgid, posix_setsid, posix_setuid, posix_setgid, posix_seteuid, posix_setegid, posix_uname, proc_close, proc_get_status, proc_open, proc_terminate, shell_exec, show_source, system
cURL : ON | WGET : ON | Sudo : OFF | Pkexec : OFF
Directory : /home/wheelch2/antalyamobilityscooter.com/wp-includes/blocks/
Upload Files :
Current_dir [ Writeable ] Document_root [ Writeable ]

Command :


Current File : /home/wheelch2/antalyamobilityscooter.com/wp-includes/blocks//avatar.php
<?php
/**
 * Server-side rendering of the `core/avatar` block.
 *
 * @package WordPress
 */

/**
 * Renders the `core/avatar` block on the server.
 *
 * @since 6.0.0
 *
 * @param array    $attributes Block attributes.
 * @param string   $content    Block default content.
 * @param WP_Block $block      Block instance.
 * @return string Return the avatar.
 */
function render_block_core_avatar( $attributes, $content, $block ) {
	$size               = isset( $attributes['size'] ) ? $attributes['size'] : 96;
	$wrapper_attributes = get_block_wrapper_attributes();
	$border_attributes  = get_block_core_avatar_border_attributes( $attributes );

	// Class gets passed through `esc_attr` via `get_avatar`.
	$image_classes = ! empty( $border_attributes['class'] )
		? "wp-block-avatar__image {$border_attributes['class']}"
		: 'wp-block-avatar__image';

	// Unlike class, `get_avatar` doesn't filter the styles via `esc_attr`.
	// The style engine does pass the border styles through
	// `safecss_filter_attr` however.
	$image_styles = ! empty( $border_attributes['style'] )
		? sprintf( ' style="%s"', esc_attr( $border_attributes['style'] ) )
		: '';

	if ( ! isset( $block->context['commentId'] ) ) {
		if ( isset( $attributes['userId'] ) ) {
			$author_id = $attributes['userId'];
		} elseif ( isset( $block->context['postId'] ) ) {
			$author_id = get_post_field( 'post_author', $block->context['postId'] );
		} else {
			$author_id = get_query_var( 'author' );
		}

		if ( empty( $author_id ) ) {
			return '';
		}

		$author_name = get_the_author_meta( 'display_name', $author_id );
		// translators: %s: Author name.
		$alt          = sprintf( __( '%s Avatar' ), $author_name );
		$avatar_block = get_avatar(
			$author_id,
			$size,
			'',
			$alt,
			array(
				'extra_attr' => $image_styles,
				'class'      => $image_classes,
			)
		);
		if ( isset( $attributes['isLink'] ) && $attributes['isLink'] ) {
			$label = '';
			if ( '_blank' === $attributes['linkTarget'] ) {
				// translators: %s is the Author name.
				$label = 'aria-label="' . esc_attr( sprintf( __( '(%s author archive, opens in a new tab)' ), $author_name ) ) . '"';
			}
			// translators: 1: Author archive link. 2: Link target. %3$s Aria label. %4$s Avatar image.
			$avatar_block = sprintf( '<a href="%1$s" target="%2$s" %3$s class="wp-block-avatar__link">%4$s</a>', esc_url( get_author_posts_url( $author_id ) ), esc_attr( $attributes['linkTarget'] ), $label, $avatar_block );
		}
		return sprintf( '<div %1s>%2s</div>', $wrapper_attributes, $avatar_block );
	}
	$comment = get_comment( $block->context['commentId'] );
	if ( ! $comment ) {
		return '';
	}
	/* translators: %s: Author name. */
	$alt          = sprintf( __( '%s Avatar' ), $comment->comment_author );
	$avatar_block = get_avatar(
		$comment,
		$size,
		'',
		$alt,
		array(
			'extra_attr' => $image_styles,
			'class'      => $image_classes,
		)
	);
	if ( isset( $attributes['isLink'] ) && $attributes['isLink'] && isset( $comment->comment_author_url ) && '' !== $comment->comment_author_url ) {
		$label = '';
		if ( '_blank' === $attributes['linkTarget'] ) {
			// translators: %s: Comment author name.
			$label = 'aria-label="' . esc_attr( sprintf( __( '(%s website link, opens in a new tab)' ), $comment->comment_author ) ) . '"';
		}
		$avatar_block = sprintf( '<a href="%1$s" target="%2$s" %3$s class="wp-block-avatar__link">%4$s</a>', esc_url( $comment->comment_author_url ), esc_attr( $attributes['linkTarget'] ), $label, $avatar_block );
	}
	return sprintf( '<div %1s>%2s</div>', $wrapper_attributes, $avatar_block );
}

/**
 * Generates class names and styles to apply the border support styles for
 * the Avatar block.
 *
 * @since 6.3.0
 *
 * @param array $attributes The block attributes.
 * @return array The border-related classnames and styles for the block.
 */
function get_block_core_avatar_border_attributes( $attributes ) {
	$border_styles = array();
	$sides         = array( 'top', 'right', 'bottom', 'left' );

	// Border radius.
	if ( isset( $attributes['style']['border']['radius'] ) ) {
		$border_styles['radius'] = $attributes['style']['border']['radius'];
	}

	// Border style.
	if ( isset( $attributes['style']['border']['style'] ) ) {
		$border_styles['style'] = $attributes['style']['border']['style'];
	}

	// Border width.
	if ( isset( $attributes['style']['border']['width'] ) ) {
		$border_styles['width'] = $attributes['style']['border']['width'];
	}

	// Border color.
	$preset_color           = array_key_exists( 'borderColor', $attributes ) ? "var:preset|color|{$attributes['borderColor']}" : null;
	$custom_color           = $attributes['style']['border']['color'] ?? null;
	$border_styles['color'] = $preset_color ? $preset_color : $custom_color;

	// Individual border styles e.g. top, left etc.
	foreach ( $sides as $side ) {
		$border                 = $attributes['style']['border'][ $side ] ?? null;
		$border_styles[ $side ] = array(
			'color' => isset( $border['color'] ) ? $border['color'] : null,
			'style' => isset( $border['style'] ) ? $border['style'] : null,
			'width' => isset( $border['width'] ) ? $border['width'] : null,
		);
	}

	$styles     = wp_style_engine_get_styles( array( 'border' => $border_styles ) );
	$attributes = array();
	if ( ! empty( $styles['classnames'] ) ) {
		$attributes['class'] = $styles['classnames'];
	}
	if ( ! empty( $styles['css'] ) ) {
		$attributes['style'] = $styles['css'];
	}
	return $attributes;
}

/**
 * Registers the `core/avatar` block on the server.
 *
 * @since 6.0.0
 */
function register_block_core_avatar() {
	register_block_type_from_metadata(
		__DIR__ . '/avatar',
		array(
			'render_callback' => 'render_block_core_avatar',
		)
	);
}
add_action( 'init', 'register_block_core_avatar' );

[ Back ]
Name
Size
Last Modified
Owner / Group
Permissions
Options
..
--
May 20 2025 03:29:06
1032 / wheelch2
0755
archives
--
October 16 2024 01:01:17
1032 / wheelch2
0755
audio
--
October 16 2024 01:01:17
1032 / wheelch2
0755
avatar
--
October 16 2024 01:01:17
1032 / wheelch2
0755
block
--
October 16 2024 01:01:17
1032 / wheelch2
0755
button
--
October 16 2024 01:01:17
1032 / wheelch2
0755
buttons
--
October 16 2024 01:01:17
1032 / wheelch2
0755
calendar
--
October 16 2024 01:01:17
1032 / wheelch2
0755
categories
--
October 16 2024 01:01:17
1032 / wheelch2
0755
code
--
October 16 2024 01:01:17
1032 / wheelch2
0755
column
--
October 16 2024 01:01:17
1032 / wheelch2
0755
columns
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comment-author-name
--
November 13 2024 04:42:28
1032 / wheelch2
0755
comment-content
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comment-date
--
November 13 2024 04:42:28
1032 / wheelch2
0755
comment-edit-link
--
November 13 2024 04:42:28
1032 / wheelch2
0755
comment-reply-link
--
November 13 2024 04:42:28
1032 / wheelch2
0755
comment-template
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comments
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comments-pagination
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comments-pagination-next
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comments-pagination-numbers
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comments-pagination-previous
--
October 16 2024 01:01:17
1032 / wheelch2
0755
comments-title
--
October 16 2024 01:01:17
1032 / wheelch2
0755
cover
--
October 16 2024 01:01:17
1032 / wheelch2
0755
details
--
October 16 2024 01:01:17
1032 / wheelch2
0755
embed
--
October 16 2024 01:01:17
1032 / wheelch2
0755
file
--
October 16 2024 01:01:17
1032 / wheelch2
0755
footnotes
--
October 16 2024 01:01:17
1032 / wheelch2
0755
freeform
--
October 16 2024 01:01:17
1032 / wheelch2
0755
gallery
--
October 16 2024 01:01:17
1032 / wheelch2
0755
group
--
October 16 2024 01:01:17
1032 / wheelch2
0755
heading
--
October 16 2024 01:01:17
1032 / wheelch2
0755
home-link
--
October 16 2024 01:01:17
1032 / wheelch2
0755
html
--
October 16 2024 01:01:17
1032 / wheelch2
0755
image
--
October 16 2024 01:01:17
1032 / wheelch2
0755
latest-comments
--
October 16 2024 01:01:17
1032 / wheelch2
0755
latest-posts
--
October 16 2024 01:01:17
1032 / wheelch2
0755
legacy-widget
--
October 16 2024 01:01:17
1032 / wheelch2
0755
list
--
October 16 2024 01:01:17
1032 / wheelch2
0755
list-item
--
October 16 2024 01:01:17
1032 / wheelch2
0755
loginout
--
November 13 2024 04:42:28
1032 / wheelch2
0755
media-text
--
October 16 2024 01:01:17
1032 / wheelch2
0755
missing
--
October 16 2024 01:01:17
1032 / wheelch2
0755
more
--
October 16 2024 01:01:17
1032 / wheelch2
0755
navigation
--
October 16 2024 01:01:17
1032 / wheelch2
0755
navigation-link
--
October 16 2024 01:01:17
1032 / wheelch2
0755
navigation-submenu
--
October 16 2024 01:01:17
1032 / wheelch2
0755
nextpage
--
October 16 2024 01:01:17
1032 / wheelch2
0755
page-list
--
October 16 2024 01:01:17
1032 / wheelch2
0755
page-list-item
--
October 16 2024 01:01:17
1032 / wheelch2
0755
paragraph
--
October 16 2024 01:01:17
1032 / wheelch2
0755
pattern
--
October 16 2024 01:01:17
1032 / wheelch2
0755
post-author
--
November 13 2024 04:42:28
1032 / wheelch2
0755
post-author-biography
--
November 13 2024 04:42:28
1032 / wheelch2
0755
post-author-name
--
November 13 2024 04:42:28
1032 / wheelch2
0755
post-comments-form
--
October 16 2024 01:01:17
1032 / wheelch2
0755
post-content
--
April 16 2025 03:36:53
1032 / wheelch2
0755
post-date
--
October 16 2024 01:01:17
1032 / wheelch2
0755
post-excerpt
--
October 16 2024 01:01:17
1032 / wheelch2
0755
post-featured-image
--
October 16 2024 01:01:17
1032 / wheelch2
0755
post-navigation-link
--
October 16 2024 01:01:17
1032 / wheelch2
0755
post-template
--
April 16 2025 03:36:53
1032 / wheelch2
0755
post-terms
--
October 16 2024 01:01:17
1032 / wheelch2
0755
post-title
--
October 16 2024 01:01:17
1032 / wheelch2
0755
preformatted
--
October 16 2024 01:01:17
1032 / wheelch2
0755
pullquote
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query-no-results
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query-pagination
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query-pagination-next
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query-pagination-numbers
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query-pagination-previous
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query-title
--
October 16 2024 01:01:17
1032 / wheelch2
0755
query-total
--
April 16 2025 03:36:53
1032 / wheelch2
0755
quote
--
October 16 2024 01:01:17
1032 / wheelch2
0755
read-more
--
October 16 2024 01:01:17
1032 / wheelch2
0755
rss
--
October 16 2024 01:01:17
1032 / wheelch2
0755
search
--
October 16 2024 01:01:17
1032 / wheelch2
0755
separator
--
October 16 2024 01:01:17
1032 / wheelch2
0755
shortcode
--
October 16 2024 01:01:17
1032 / wheelch2
0755
site-logo
--
October 16 2024 01:01:17
1032 / wheelch2
0755
site-tagline
--
November 13 2024 04:42:28
1032 / wheelch2
0755
site-title
--
October 16 2024 01:01:17
1032 / wheelch2
0755
social-link
--
October 16 2024 01:01:17
1032 / wheelch2
0755
social-links
--
October 16 2024 01:01:17
1032 / wheelch2
0755
spacer
--
October 16 2024 01:01:17
1032 / wheelch2
0755
table
--
October 16 2024 01:01:17
1032 / wheelch2
0755
tag-cloud
--
November 13 2024 04:42:28
1032 / wheelch2
0755
template-part
--
October 16 2024 01:01:17
1032 / wheelch2
0755
term-description
--
October 16 2024 01:01:17
1032 / wheelch2
0755
text-columns
--
October 16 2024 01:01:17
1032 / wheelch2
0755
verse
--
October 16 2024 01:01:17
1032 / wheelch2
0755
video
--
October 16 2024 01:01:17
1032 / wheelch2
0755
widget-group
--
October 16 2024 01:01:17
1032 / wheelch2
0755
.htaccess
0 KB
March 26 2025 13:44:20
1032 / wheelch2
0444
archives.php
2.924 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
avatar.php
5.61 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
block.php
3.236 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
blocks-json.php
189.399 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
button.php
1.763 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
calendar.php
5.933 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
categories.php
3.916 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
comment-author-name.php
2.083 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comment-content.php
2.401 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comment-date.php
1.819 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
comment-edit-link.php
1.673 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comment-reply-link.php
2.026 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comment-template.php
4.389 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comments-pagination-next.php
1.879 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
comments-pagination-numbers.php
1.594 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comments-pagination-previous.php
1.748 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
comments-pagination.php
1.171 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comments-title.php
2.707 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
comments.php
6.608 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
cover.php
3.101 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
error_log
2.291 KB
October 11 2024 21:54:19
1032 / wheelch2
0644
file.php
1.751 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
footnotes.php
3.683 KB
April 03 2024 05:39:18
1032 / wheelch2
0644
gallery.php
6.287 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
heading.php
1.271 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
home-link.php
5.311 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
image.php
11.741 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
index.php
4.991 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
latest-comments.php
4.922 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
latest-posts.php
8.342 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
legacy-widget.php
3.903 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
list.php
1.243 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
loginout.php
1.385 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
media-text.php
4.28 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
navigation-link.php
13.587 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
navigation-submenu.php
9.71 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
navigation.php
48.457 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
page-list-item.php
0.353 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
page-list.php
13.292 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
pattern.php
1.746 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
post-author-biography.php
1.488 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
post-author-name.php
1.905 KB
May 01 2025 03:35:17
1032 / wheelch2
0644
post-author.php
2.67 KB
May 01 2025 03:35:17
1032 / wheelch2
0644
post-comments-form.php
2.739 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
post-content.php
2.105 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
post-date.php
3.051 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
post-excerpt.php
3.366 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
post-featured-image.php
9.144 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
post-navigation-link.php
4.724 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
post-template.php
5.614 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
post-terms.php
3.555 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
post-title.php
2.088 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
query-no-results.php
1.804 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
query-pagination-next.php
3.698 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
query-pagination-numbers.php
4.658 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
query-pagination-previous.php
3.5 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
query-pagination.php
1.148 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
query-title.php
2.049 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
query-total.php
2.476 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
query.php
5.557 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
read-more.php
1.787 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
require-dynamic-blocks.php
4.065 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
require-static-blocks.php
0.489 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
rss.php
3.978 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
search.php
22.477 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
shortcode.php
0.718 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
site-logo.php
6.186 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
site-tagline.php
1.175 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
site-title.php
1.81 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
social-link.php
63.646 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
tag-cloud.php
1.553 KB
November 13 2024 04:42:28
1032 / wheelch2
0644
template-part.php
9.916 KB
April 16 2025 03:36:53
1032 / wheelch2
0644
term-description.php
1.305 KB
July 16 2024 18:02:44
1032 / wheelch2
0644
widget-group.php
2.381 KB
July 16 2024 18:02:44
1032 / wheelch2
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025
CONTACT ME
Static GIF