尝试从已使用表单存储的文件夹中显示头像(图像)。
错误: 图像未显示。 我在inspect元素中发现URL加倍:
---------- inspect element --------------------------
background-image:url(http://phpstack-130512-487107.cloudwaysapps.com/site/http%3A//phpstack-130502-487107.cloudwaysapps.com/site/components/com_jux_testimonial/uploads/5ad865a54354a-seyaligal-LOGO.jpg);
---------- inspect element --------------------------
编辑了检查元素代码并进行了检查。
----------检查元素编辑--------------------------
background-image:url(http://phpstack-130502-487107.cloudwaysapps.com/site/components/com_jux_testimonial/uploads/5ad865a54354a-seyaligal-LOGO.jpg);
----------检查元素编辑--------------------------
现在显示图像。
附加屏幕截图。
请就如何调试此问题提出建议。
提前致谢。
热烈的问候, Venkat Chinniah
[三张截图合并并附在一张图片上] [1]
代码第1部分:
<div class="avatar-testimonial">
<?php
if ($userNameEffects == 1) {
if ($useGravatar && $item->jux_gravatar) {
echo '<div class="user_avatar_rotate avatar' . $column . '" style="background-image: url(' . $item->jux_gravatar . '); "></div>';
} else if ($item->jux_avatar) {
$jux_avatar = $item->jux_avatar;
echo '<div class="user_avatar_rotate avatar' . $column . '" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $jux_avatar))) . '); "></div>';
} else {
echo '<div class="user_avatar_rotate avatar' . $column . '" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $juxAvatarDefault))) . '); "></div>';
}
?>
<?php
} else {
if ($useGravatar && $item->jux_gravatar) {
echo '<div class="user_avatar" style="background-image: url(' . $item->jux_gravatar . '); "></div>';
} else if ($item->jux_avatar) {
$jux_avatar = $item->jux_avatar;
echo '<div class="user_avatar" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $jux_avatar))) . '); "></div>';
} else {
echo '<div class="user_avatar" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $juxAvatarDefault))) . '); "></div>';
}
?>
<?php }
?>
代码第2部分:
<div class="avatar-testimonial avatartes<?php echo $column; ?>">
<?php
if ($userNameEffects == 1) {
if ($useGravatar && $item->jux_gravatar) {
echo '<div class="user_avatar_rotate avatar' . $column . '" style="background-image: url(' . $item->jux_gravatar . '); "></div>';
} else if ($item->jux_avatar) {
$jux_avatar = $item->jux_avatar;
echo '<div class="user_avatar_rotate avatar' . $column . '" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $jux_avatar))) . '); "></div>';
} else {
echo '<div class="user_avatar_rotate avatar' . $column . '" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $juxAvatarDefault))) . '); "></div>';
}
?>
<?php
} else {
if ($useGravatar && $item->jux_gravatar) {
echo '<div class="user_avatar" style="background-image: url(' . $item->jux_gravatar . '); "></div>';
} else if ($item->jux_avatar) {
$jux_avatar = $item->jux_avatar;
echo '<div class="user_avatar" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $jux_avatar))) . '); "></div>';
} else {
echo '<div class="user_avatar" style="background-image: url(' . $linkAvatar = JUri::base() . implode('/', array_map('rawurlencode', explode('/', $juxAvatarDefault))) . '); "></div>';
}
?>
<?php }
?>