| Server IP : 127.0.0.1 / Your IP : 216.73.216.109 Web Server : Apache/2.4.54 (Win64) OpenSSL/1.1.1q PHP/8.1.10 System : Windows NT DESKTOP-E5T4RUN 10.0 build 19045 (Windows 10) AMD64 User : SERVERWEB ( 0) PHP Version : 8.1.10 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : C:/laragon/backup/www/ |
Upload File : |
<?php
include('php/prensa.php');
$url = "https://prensa.quillacollo.gob.bo/wp-json/wp/v2/posts?per_page=2";
$catList = getList("categories");
$userList =getList("users");
if (!empty($category)) {
$url = "https://prensa.quillacollo.gob.bo/wp-json/wp/v2/posts?per_page=2&categories={$category}";
}
if(!empty($author)){
$url = "https://prensa.quillacollo.gob.bo/wp-json/wp/v2/posts?per_page=2&author={$author}";
}
$noticias = decode_api($url);
?>
<footer id="Footer" class="clearfix">
<div class="widgets_wrapper">
<div class="container">
<div class=" one-third column">
<aside id="text-8" class="widget widget_text">
<div class="textwidget"><img src="images/Logos GAMQ whiteText.png" width="180">
<h4>Acerca de Nosotros</h4>
<p>
Direccion: Plaza 06 de Agosto Acera Este <br>
Telefonos:(591) + 4 + 4362771-72-73 <br>
<!-- email: admin@quillacollo.gob.bo -->
email: admin@quillacollo.gob.bo
</p>
<a href="https://www.facebook.com/people/Gobierno-Aut%C3%B3nomo-Municipal-de-Quillacollo/100069003586474/" class="icon_bar icon_bar_facebook icon_bar_small">
<span class="t"><i class="icon-facebook "></i></span>
<span class="b"><i class="icon-facebook"></i></span></a>
<a href="https://quillacollo.gob.bo/" class="icon_bar icon_bar_google icon_bar_small">
<span class="t"><i class="icon-gplus"></i></span>
<span class="b"><i class="icon-gplus"></i></span></a>
<a href="https://www.youtube.com/@alcaldiaquillacollo6225" class="icon_bar icon_bar_youtube icon_bar_small">
<span class="t"><i class="icon-play"></i></span>
<span class="b"><i class="icon-play"></i></span></a>
</div>
</aside>
<!-- <aside class="widget_text widget widget_custom_html">
<div class="textwidget custom-html-widget">
<p style="font-size: 35px; text-align: right;">
<a href="#"><i class="icon-twitter-circled"></i></a>
<a href="#"><i class="icon-facebook-circled"></i></a>
<a href="#"><i class="icon-skype-circled"></i></a>
</p>
</div>
</aside> -->
</div>
<div class="one-third column">
<aside class="widget widget_mfn_recent_posts">
<h4>Mapa de Quillacollo </h4>
<iframe src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d84208.16386594198!2d-66.33908756997607!3d-17.339826766930575!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x93e30b7bf247bc8b%3A0xbb3549689b244b2d!2sQuillacollo!5e0!3m2!1ses-419!2sbo!4v1693588554870!5m2!1ses-419!2sbo"
width="330" height="230" style="border-radius: 5%; " allowfullscreen="" loading="lazy" referrerpolicy="no-referrer-when-downgrade"></iframe>
</aside>
</div>
<div class="one-third column">
<!-- Recent posts -->
<aside class="widget widget_mfn_recent_posts">
<h4>Ultimas Noticias</h4>
<div class="Recent_posts">
<ul>
<?php
foreach ($noticias as $post){
$content = $post['content']['rendered'];
if (preg_match('/<img[^>]+src="([^"]+)"/', $content, $matches)) {
$firstImageURL = $matches[1];// echo $firstImageURL;
}
if(!empty($category)){
$categories = [];//null;
foreach ($catList as $category) {
foreach ($post['categories'] as $catPost) {
if ($category['id'] == $catPost) {
$categories[] = $category;
}
}
}
}
?>
<li class="post format-image has-post-thumbnail category-mobile category-photography tag-design tag-html5">
<a href="<?= $post['link']?>">
<div class="photo">
<?php if(!empty($firstImageURL)){?>
<img width="80" height="80" src="<?php echo $firstImageURL ?>">
<?php }?>
</div>
<div class="desc">
<h6><?= $post['title']['rendered'] ?></h6>
<span class="date"><i class="icon-clock"></i>
<!-- {{ \Carbon\Carbon::parse($post['date_gmt'])->format('d-m-Y') }} -->
<?php echo date("d-m-Y", strtotime($post['date_gmt']));?>
</span>
<?php if (!empty($categories)){
foreach($categories as $cat){ ?>
<a href="<?= $cat['link']?>" rel="category tag"><?= $cat['name']?></a>
<?php }
}?>
</div>
</a>
</li>
<?php }?>
</ul>
</div>
</aside>
</div>
</div>
</div>
<!-- Footer copyright-->
<div class="footer_copy">
<div class="container">
<div class="column one">
<a id="back_to_top" href="#" class="button button_left button_js"> <span class="button_icon"> <i class="icon-up-open-big"></i> </span> </a>
<div class="copyright">
© 2023 Jefatura de Tecnologia de Informacion - Gobierno Autonomo Municipal de Quillacollo. Todos los derechos reservados.
</div>
</div>
</div>
</div>
</footer>