Browse Source

replace highlight div with p

main
yggverse 8 months ago
parent
commit
28cdd0acfe
  1. 44
      src/webui/search.php

44
src/webui/search.php

@ -358,10 +358,6 @@ $results = $query->offset($p * $config->webui->pagination->limit - $config->webu
margin: 8px 0; margin: 8px 0;
} }
p {
font-size: 11px;
}
.text-warning { .text-warning {
color: #db6161; color: #db6161;
fill: #db6161; fill: #db6161;
@ -449,36 +445,46 @@ $results = $query->offset($p * $config->webui->pagination->limit - $config->webu
?> ?>
<img src="<?php echo $icon ?>" title="<?php echo $hostname ?>" alt="identicon" /> <img src="<?php echo $icon ?>" title="<?php echo $hostname ?>" alt="identicon" />
<?php if (!empty($result->getHighlight()['title'])) { ?> <?php if (!empty($result->getHighlight()['title'])) { ?>
<?php foreach ($result->getHighlight()['title'] as $title) { ?> <div>
<div> <h2>
<h2><?php echo $title ?></h2> <?php foreach ($result->getHighlight()['title'] as $title) { ?>
</div> <p><?php echo $title ?></p>
<?php } ?> <?php } ?>
</h2>
</div>
<?php } else if (!empty($result->title)) { ?> <?php } else if (!empty($result->title)) { ?>
<div> <div>
<h2><?php echo $result->title ?></h2> <h2><?php echo $result->title ?></h2>
</div> </div>
<?php } ?> <?php } ?>
<?php if (!empty($result->getHighlight()['description'])) { ?> <?php if (!empty($result->getHighlight()['description'])) { ?>
<?php foreach ($result->getHighlight()['description'] as $description) { ?> <div>
<div><?php echo $description ?></div> <?php foreach ($result->getHighlight()['description'] as $description) { ?>
<?php } ?> <p><?php echo $description ?></p>
<?php } ?>
</div>
<?php } else if (!empty($result->description)) { ?> <?php } else if (!empty($result->description)) { ?>
<div><?php echo $result->description ?></div> <div>
<?php echo $result->description ?>
</div>
<?php } ?> <?php } ?>
<?php if (!empty($result->getHighlight()['keywords'])) { ?> <?php if (!empty($result->getHighlight()['keywords'])) { ?>
<?php foreach ($result->getHighlight()['keywords'] as $keywords) { ?> <div>
<div><?php echo $keywords ?></div> <?php foreach ($result->getHighlight()['keywords'] as $keywords) { ?>
<?php } ?> <p><?php echo $keywords ?></p>
<?php } ?>
</div>
<?php } else if (!empty($result->keywords)) { ?> <?php } else if (!empty($result->keywords)) { ?>
<div> <div>
<?php echo $result->keywords ?> <?php echo $result->keywords ?>
</div> </div>
<?php } ?> <?php } ?>
<?php if (!empty($result->getHighlight()['body'])) { ?> <?php if (!empty($result->getHighlight()['body'])) { ?>
<?php foreach ($result->getHighlight()['body'] as $body) { ?> <div>
<div><?php echo $body ?></div> <?php foreach ($result->getHighlight()['body'] as $body) { ?>
<?php } ?> <p><?php echo $body ?></p>
<?php } ?>
</div>
<?php } ?> <?php } ?>
<div> <div>
<a href="<?php echo $result->url ?>"><?php echo htmlentities(urldecode($result->url)) ?></a> <a href="<?php echo $result->url ?>"><?php echo htmlentities(urldecode($result->url)) ?></a>

Loading…
Cancel
Save