Compare commits

...

2 Commits

Author SHA1 Message Date
Sergiotarxz 61856561cc Allowing google translate to serve ads. 2023-12-04 15:00:11 +01:00
Sergiotarxz 9fed48a9a3 Adding initial afiliados support. 2023-12-04 14:58:10 +01:00
6 changed files with 227 additions and 178 deletions

View File

@ -0,0 +1,46 @@
<post>
<author>Burguillos.info</author>
<date>2023-09-07T16:11:00+00:00</date>
<title>Compra online y ayudanos a financiar Burguillos.info.</title>
<ogdesc>Compra online y ayudanos a financiar Burguillos.info.</ogdesc>
<img src="/img/amazon.webp"/>
<category>index</category>
<slug>afiliados</slug>
<pinned>101</pinned>
<content>
<h2>PROMOCIONADO</h2>
<p>Burguillos Info ya genera algunos ingresos que cubren el precio de su infraestructura; no obstante para seguir expandiendonos y daros cada día más
se hace necesario aumentar nuestras vías de financiación, es por ello que damos comienzo a un programa de afiliados.</p>
<p>¿En que consiste? Os preguntaréis. Es muy simple, compartiremos enlaces a lo largo de la web a
productos (Por ejemplo libros) que podéis comprar online en distintas
webs de confianza como Amazon, si decidís comprarlos y lo haceis a través del enlace un pequeño porcentaje
llegará a Burguillos Info y de ese modo podremos financiar desarrollos futuros.</p>
<p>Todas esas recomendaciones de venta irán siempre acompañadas de indicativos de que se trata de publicidad tal y como requiere la ley.</p>
<h2>Lista completa de artículos que desde Burguillos Info recomendamos:</h2>
<div class="articles">
<a target="_blank" href="https://www.amazon.es/Libro-Portales-Biblioteca-Laura-Gallego/dp/8445009745/ref=sr_1_1?__mk_es_ES=%25C3%2585M%25C3%2585%25C5%25BD%25C3%2595%25C3%2591&amp;crid=1SBU2V7A4V84G&amp;keywords=laura+gallego+libro+de+los+portales&amp;qid=1701629603&amp;sprefix=laura+gallego+libro+de+los+portales%252Caps%252C107&amp;sr=8-1&_encoding=UTF8&tag=burguillosinf-21&linkCode=ur2&linkId=2358afd053f3f48c98808c881d0755a0&camp=3638&creative=24630">
<article>
<div class="article-up-part">
<div class="image-container">
<img alt="" src="/img/libro-de-los-portales.webp"/>
</div>
</div>
<div class="article-down-part">
<div>
<h3>Libro de los Portales - Laura Gallego 15.15€ (A través de Amazon)</h3>
<p>PROMOCIONADO (Libro indicado para interesar a los niños/adolescentes en la lectura)
Los pintores de la Academia de los Portales...</p>
</div>
</div>
</article>
</a>
</div>
<p>¿Deseas proveer de enlaces de afiliado a Burguillos Info para potenciar tu negocio? Contacta con <a href="mailto:contact@owlcode.tech">contact@owlcode.tech</a>.</p>
</content>
</post>

View File

@ -13,6 +13,7 @@ sub next_ad {
my $self = shift;
my $ads_factory = BurguillosInfo::Ads->new;
my $current_ad_number = $self->param('n');
$self->res->headers->access_control_allow_origin('*');
$self->render( json => $ads_factory->get_next($current_ad_number) );
}
1;

View File

@ -9,6 +9,65 @@ body {
min-height: 100%;
width: 100%;
height: 100%; }
body div.articles {
display: flex;
flex-direction: row;
flex-wrap: wrap;
font-size: 0.7rem; }
body div.articles a {
width: 45%;
margin-left: 5%; }
body div.articles a:nth-child(2n+1) {
margin-left: 0%; }
body div.articles div.image-container {
margin-left: 2.5%;
margin-top: 10px;
height: 95%;
width: 95%;
display: flex;
min-height: 130px;
justify-content: center;
align-items: center; }
body div.articles div.image-container img {
background: white;
max-height: 100%;
max-width: 100%;
border: solid 1px black; }
body div.articles a {
min-height: 90%;
display: block;
text-decoration: none;
text-overflow: ellipsis;
margin-bottom: 30px; }
body div.articles a:focus article, body div.articles a:hover article {
background: blueviolet;
color: #f2eb8c; }
body div.articles a article {
word-wrap: break-word;
width: 90%;
height: 90%;
padding: 5%;
padding-top: 1%;
color: blueviolet;
box-shadow: 8px 8px 1px 0px #8ddfd6;
border: 3px solid black; }
body div.articles a article p, body div.articles a article h4, body div.articles a article h3, body div.articles a article h2 {
margin: 0px; }
body div.articles a article div.article-up-part {
height: 12em; }
body div.articles a article div.article-down-part {
margin-top: 2em;
height: 9em;
display: flex;
align-items: end;
padding-bottom: 2em; }
body div.articles a article:hover {
background: blueviolet;
color: #f2eb8c; }
body div.articles a article p.date {
text-align: right; }
body div.articles a article p.author {
text-align: right; }
body summary h2, body summary h3, body summary h4, body summary h5 {
display: inline; }
body span.round-center {
@ -369,65 +428,6 @@ body {
display: block; }
body div.page-contents div.description div.suscribirse-rss img {
max-height: 300px; }
body div.page-contents div.description div.articles {
display: flex;
flex-direction: row;
flex-wrap: wrap;
font-size: 0.7rem; }
body div.page-contents div.description div.articles a {
width: 45%;
margin-left: 5%; }
body div.page-contents div.description div.articles a:nth-child(2n+1) {
margin-left: 0%; }
body div.page-contents div.description div.articles div.image-container {
margin-left: 2.5%;
margin-top: 10px;
height: 95%;
width: 95%;
display: flex;
min-height: 130px;
justify-content: center;
align-items: center; }
body div.page-contents div.description div.articles div.image-container img {
background: white;
max-height: 100%;
max-width: 100%;
border: solid 1px black; }
body div.page-contents div.description div.articles a {
min-height: 90%;
display: block;
text-decoration: none;
text-overflow: ellipsis;
margin-bottom: 30px; }
body div.page-contents div.description div.articles a:focus article, body div.page-contents div.description div.articles a:hover article {
background: blueviolet;
color: #f2eb8c; }
body div.page-contents div.description div.articles a article {
word-wrap: break-word;
width: 90%;
height: 90%;
padding: 5%;
padding-top: 1%;
color: blueviolet;
box-shadow: 8px 8px 1px 0px #8ddfd6;
border: 3px solid black; }
body div.page-contents div.description div.articles a article p, body div.page-contents div.description div.articles a article h4, body div.page-contents div.description div.articles a article h3, body div.page-contents div.description div.articles a article h2 {
margin: 0px; }
body div.page-contents div.description div.articles a article div.article-up-part {
height: 12em; }
body div.page-contents div.description div.articles a article div.article-down-part {
margin-top: 2em;
height: 9em;
display: flex;
align-items: end;
padding-bottom: 2em; }
body div.page-contents div.description div.articles a article:hover {
background: blueviolet;
color: #f2eb8c; }
body div.page-contents div.description div.articles a article p.date {
text-align: right; }
body div.page-contents div.description div.articles a article p.author {
text-align: right; }
body div.page-contents div.description a.suscribe-category-rss {
background: blueviolet;
width: 40px;
@ -491,15 +491,15 @@ body {
font-size: 20px; } }
@media (min-width: 694px) {
body div.articles a {
width: 45%;
margin-left: 5%; }
body div.articles a:nth-child(2n+1) {
margin-left: 0%; }
body div.carousel a {
font-size: 20px; }
body div.carousel h3 {
font-size: 25px; }
body div.page-contents div.description div.articles a {
width: 45%;
margin-left: 5%; }
body div.page-contents div.description div.articles a:nth-child(2n+1) {
margin-left: 0%; }
body div.page-contents img {
max-width: 694px; } }
@ -536,12 +536,12 @@ body {
height: 100%; } }
@media (min-width: 1333px) {
body div.page-contents div.description div.articles a {
width: 30%;
body div.articles a {
width: 21%;
margin-left: 3%; }
body div.page-contents div.description div.articles a:nth-child(2n+1) {
body div.articles a:nth-child(2n+1) {
margin-left: 3%; }
body div.page-contents div.description div.articles a:nth-child(3n+1) {
body div.articles a:nth-child(4n+1) {
margin-left: 0%; } }
@media (max-width: 200px) {

View File

@ -17,6 +17,95 @@ html {
}
body {
div.articles {
display: flex;
flex-direction: row;
flex-wrap: wrap;
font-size: 0.7rem;
a {
&:nth-child(2n+1) {
margin-left: 0%;
}
width: 45%;
margin-left: 5%;
}
div.image-container {
margin-left: 2.5%;
margin-top: 10px;
height: 95%;
width: 95%;
display: flex;
min-height: 130px;
justify-content: center;
align-items: center;
img {
background: white;
max-height: 100%;
max-width: 100%;
border: solid 1px black;
}
}
a {
min-height: 90%;
display: block;
text-decoration: none;
text-overflow: ellipsis;
margin-bottom: 30px;
&:focus, &:hover {
//outline: red solid 3px;
article {
background: $background_div;
color: $color_div;
}
}
article {
word-wrap: break-word;
width: 90%;
height: 90%;
p, h4, h3, h2 {
margin: 0px;
}
div.article-up-part {
height: 12em;
}
div.article-down-part {
margin-top: 2em;
height: 9em;
display: flex;
align-items: end;
padding-bottom: 2em;
}
padding: 5%;
padding-top: 1%;
color: $background_div;
box-shadow: 8px 8px 1px 0px #8ddfd6;
border: 3px solid black;
&:hover {
background: $background_div;
color: $color_div;
}
p.date {
text-align: right;
}
p.author {
text-align: right;
}
}
}
}
summary {
h2, h3, h4, h5 {
display: inline;
@ -547,95 +636,7 @@ body {
margin-right: 3%;
margin-bottom: 1%;
div.articles {
display: flex;
flex-direction: row;
flex-wrap: wrap;
font-size: 0.7rem;
a {
&:nth-child(2n+1) {
margin-left: 0%;
}
width: 45%;
margin-left: 5%;
}
div.image-container {
margin-left: 2.5%;
margin-top: 10px;
height: 95%;
width: 95%;
display: flex;
min-height: 130px;
justify-content: center;
align-items: center;
img {
background: white;
max-height: 100%;
max-width: 100%;
border: solid 1px black;
}
}
a {
min-height: 90%;
display: block;
text-decoration: none;
text-overflow: ellipsis;
margin-bottom: 30px;
&:focus, &:hover {
//outline: red solid 3px;
article {
background: $background_div;
color: $color_div;
}
}
article {
word-wrap: break-word;
width: 90%;
height: 90%;
p, h4, h3, h2 {
margin: 0px;
}
div.article-up-part {
height: 12em;
}
div.article-down-part {
margin-top: 2em;
height: 9em;
display: flex;
align-items: end;
padding-bottom: 2em;
}
padding: 5%;
padding-top: 1%;
color: $background_div;
box-shadow: 8px 8px 1px 0px #8ddfd6;
border: 3px solid black;
&:hover {
background: $background_div;
color: $color_div;
}
p.date {
text-align: right;
}
p.author {
text-align: right;
}
}
}
}
a.suscribe-category-rss {
background: $background_div;
@ -743,6 +744,16 @@ body {
@media (min-width: 694px) {
body {
div.articles {
a {
&:nth-child(2n+1) {
margin-left: 0%;
}
width: 45%;
margin-left: 5%;
}
}
div.carousel {
a {
font-size: 20px;
@ -755,16 +766,7 @@ body {
div.page-contents {
div.description {
div.articles {
a {
&:nth-child(2n+1) {
margin-left: 0%;
}
width: 45%;
margin-left: 5%;
}
}
}
img {
@ -830,22 +832,22 @@ body {
@media (min-width: 1333px) {
body {
div.articles {
a {
&:nth-child(2n+1) {
margin-left: 3%;
}
&:nth-child(4n+1) {
margin-left: 0%;
}
width: 21%;
margin-left: 3%;
}
}
div.page-contents {
div.description {
div.articles {
a {
&:nth-child(2n+1) {
margin-left: 3%;
}
&:nth-child(3n+1) {
margin-left: 0%;
}
width: 30%;
margin-left: 3%;
}
}
}
}
}

BIN
public/img/amazon.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 113 KiB