zulok
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: New Privacy Page Notification Wont Go AwayHi
File wp-admin/includes/misc.php includes the following code:
/** * Output a warning when some privacy info has changed. * * @since 4.9.6 */ public static function policy_text_changed_notice() { global $post; $screen = get_current_screen()->id; if ( 'privacy' !== $screen ) { return; } ?> <div class="policy-text-updated notice notice-warning is-dismissible"> <p><?php printf( /* translators: %s: Privacy Policy Guide URL */ __( 'The suggested privacy policy text has changed. Please <a href="%s">review the guide</a> and update your privacy policy.' ), esc_url( admin_url( 'tools.php?wp-privacy-policy-guide=1' ) ) ); ?></p> </div> <?php }I think this is a bug as the ID cannot be a text:
if ( ‘privacy’ !== $screen )Regards
Zulok
Forum: Themes and Templates
In reply to: [evolve] archive.php not loading?.
Forum: Themes and Templates
In reply to: [evolve] archive.php not loading?Hi Romik
I do not know about the possibility of infinite scroll loading. I tried the one column layout but I do not like it much.
The number of items is not a priority. I just would like to remove the flickr. In my humble opinion it does not only depend on the number of items but on the weight / size of the images. So, if I reduce the number of items I will not be sure of having removed the flickering…
I am considering to modify the code not to use Bootstrap Card and get back the archive functionality of 3.8.4 through the Child Them… but I have not even analysed how hard this would be.
Without being sure that flickr is removed I will not put this version live. This upgrade has taken a lot more of time for fixing and I do not still know what I still have to face to solve everything…
Thanks
Zulok
Forum: Themes and Templates
In reply to: [evolve] archive.php not loading?Hi Romik
V3.8.4 did not flickr with that much items…
Can be Bootstrap Card be skipped?
Thanks
Zulok
Forum: Themes and Templates
In reply to: [evolve] archive.php not loading?Hi Romik
The example is in an archive pages; not something user access frequently so the load time is a little bit less relevant, and I will reduce the number of posts indeed.
What about the flickering?
Thanks
Zulok
Forum: Themes and Templates
In reply to: [evolve] archive.php not loading?Hi Romik
I usually work in a local stage and I am still making the child theme adjustements, but have cloned the site here
You can try this
http://test.mestresdevida.cat/2016/
http://test.mestresdevida.cat/2017/
http://test.mestresdevida.cat/2018/Forget about this issue “It does not seem to load archive.php from the template.” It was my fault debugging
Child Thema and all plugins are disabled. Version 3.8.4 is still live @ mestresdevida.cat
Thanks
Zulok
- This reply was modified 7 years, 8 months ago by zulok.
Forum: Themes and Templates
In reply to: [evolve] Custom Post typeOK. Thanks
Forum: Themes and Templates
In reply to: [evolve] Fatal errorHi Purnendu
evolve_get_option() has changed to evolve_theme_mod().
Are you using a <3.8.4 copy of header.php in your child theme with an evolve version >=3.9.3?
Regards
Zulok
Forum: Themes and Templates
In reply to: [evolve] Custom Post typeHello Romik
Thanks for your quick answer and for keeping this theme updated frequently.
I have been using evolve with a few custom types since 2015 and gone through updates several times with small adjustments. With versions up to 3.8.4 I copied evolve single.php and archive.php into single-{cpt}.php and archive-{cpt}.php where I inserted my own code to display additional fields. I choose this implementation instead of building both files from scratch so that all the website shares the common customizations of evolve, and to keep code modular. This is the recommended way as I have read in the WP Codex.
Actually my question was to locate the PHP where the actual HTML code is generated for the post content, and secondly which files had I to copy and modify as the code has been restructured/wrapped.
With a little debugging I think I have found a solution that I post for other users.
.- Copy evolve\archive.php into evolve-child\archive-cpt.php
.- Replace the custom post type (:46) get_template_part( ‘template-parts/post/content’, ‘cpt‘ );
.- Copy evolve\template-parts\post\content-post.php into \template-parts\post\content-cpt.php
.- Make any changes in the latter fileDoes it make sense?
Thank you
Zulok
Forum: Themes and Templates
In reply to: [evolve] Custom Post typeHi Romik
That’s what I am trying to do. I have a couple of local intances one with version 3.8.4 as the public one, and the other in 3.9.3 where I want to replicate the modifications for the CPT.
The problem is that I don’t know where the actual HTML is generated for single.php and archive.php, and it is not clear to me how many files should I duplicate for the CPT with the new wrappings. 🙁
Thanks
David
Forum: Themes and Templates
In reply to: [evolve] Custom Post typeHi Romik
I am using 3.8.4. Only this part of the code belongs to evolve,
<div class="entry-content article"> <?php the_content(__('Read More »', 'evolve')); ?> <?php wp_link_pages(array('before' => '<div id="page-links"><p>' . __('<strong>Pages:</strong>', 'evolve'), 'after' => '</p></div>')); ?> <div class="clearfix"></div>Below the code is the one to display custom meta fields.
Thanks for pointing out the bugs in the code I added
Zulok
- This reply was modified 7 years, 8 months ago by zulok.
Forum: Themes and Templates
In reply to: [evolve] Custom Post typeHi Romike
Here is a short example of single-taller.php based on a modification of single.php
Basically, some custom fields are displayed as part of the post.
Thx
Zulok
<div class="entry-content article"> <?php the_content(__('Read More »', 'evolve')); ?> <?php wp_link_pages(array('before' => '<div id="page-links"><p>' . __('<strong>Pages:</strong>', 'evolve'), 'after' => '</p></div>')); ?> <div class="clearfix"></div> </div><!--END .entry-content .article--> <!-- Display our fields --> <?php if (get_field("escola")){?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Escola: </strong></span><?php the_field("escola") ; ?></p> <?php };?> <?php if (get_field("ponent")){?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Mestre: </strong></span><?php the_field("ponent") ; ?></p> <?php };?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Data Inici: </strong></span><?php $ed = get_field( "data_ini", $post_id, false); //get_the_ID echo substr($ed,8,2) . '/' . substr($ed,5,2) . '/' . substr($ed,0,4);?></p> <?php if (get_field("data_fi")){?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Data Fi: </strong></span><?php $ed = get_field( "data_fi", $post_id, false); //get_the_ID echo substr($ed,8,2) . '/' . substr($ed,5,2) . '/' . substr($ed,0,4);?></p> <?php };?> <?php if (get_field("hora")){?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Hora: </strong></span><?php the_field("hora") ; ?></p> <?php };?> <?php if (get_field("lloc")){?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Lloc: </strong></span><?php the_field("lloc")?></p> <?php };?> <?php if (get_field("preu")){?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Preu: </strong></span><?php the_field("preu") ; ?> €</p> <?php };?> <?php if (get_field("mail_informatiu")){?> <p class="parrafo-pequeño-gris-oscuro"> <span class="camps-event"><strong>Sol.licitar Informació: </strong> <a href="mailto:<?php the_field("mail_informatiu") ; ?>?subject=Sol.licitud d'informació sobre: <?php if ( get_the_title() ){ the_title();} ?>&body=Desitjaria rebre més informació sobre l'event <?php if ( get_the_title() ){ the_title();} ?>."><?php the_field("mail_informatiu") ; ?> </a> </span> </p> <?php };?> <div id="view1"> <?php $location = get_field('mapa'); if( ! empty($location) ):?> <p class="parrafo-pequeño-gris-oscuro"><span class="camps-event"><strong>Mapa: </strong></span><?php echo $location['address']; ?></p> <div id="map" class="acf-map"></div> <script type="text/javascript"> function load() { var lat = <?php echo $location['lat']; ?>; var lng = <?php echo $location['lng']; ?>; var latlng = new google.maps.LatLng(lat, lng); var myOptions = { zoom: 16, mapTypeControl: true, zoomControl: true, center: latlng, mapTypeId: google.maps.MapTypeId.ROADMAP }; var map = new google.maps.Map(document.getElementById("map"), myOptions); var marker = new google.maps.Marker({ position: map.getCenter(), map: map }); } load(); </script> <?php endif; ?> </div> // etc... </div>- This reply was modified 7 years, 8 months ago by zulok.
Forum: Plugins
In reply to: [MailPoet Newsletters (Previous)] Not sending every hourHi Mailpoet
No, it has not changed. Now it is sendind 10 emails every 10 minutes.
Zulok
Forum: Plugins
In reply to: [MailPoet Newsletters (Previous)] Not sending every hourHi
If I select 20 emails every 15 minutes, and set a cron task to trigger the newsletter, mails are sent every half an hour actually. It seems the same problem as reported initially with different time frames
Thanks
Zulok
Forum: Plugins
In reply to: [MailPoet Newsletters (Previous)] Not sending every hourHi MailPoet,
Thanks for your answer.
However I am not sending 80 newsletters per hour, but one newsletter with a limit of 80 emails per hour. The limit of my hosting is 100 emails per hour. Perhaps it is a different scenario.
If what you suggest is to send the newsletter 4 times per hour and 20 emails each time, then I do not know how to customize it with MailPoet admin options to do so.
Thanks
Zulok