Christian Rodríguez
Forum Replies Created
-
Forum: Developing with WordPress
In reply to: How to display the last update time on THE SITE?I found my own solution!
Thanks @bcworkz. As I’m not a backend developer, this explanation sounds complicated to me.
But some minutes ago, my brain lightened an idea to solve this issue. This is the way that worked for me, step by step:
- Install the plugin Shortcodes Ultimate (which I use for a lot of things).
- Note: I’m using “Disable Gutenberg” plugin and using the classic editor (Gutenberg blocks are a horror nightmare).
- In our theme (preferably a child theme) we need to create a new folder and file that I will name “lastupdate-loop.php” here: /wp-content/themes/OURTHEME/templates/lastupdate-loop.php
- This file would be used by Shortcodes Ultimate. Edit that new file and paste the following code:
<?php defined( 'ABSPATH' ) || exit; if ( $posts->have_posts() ) : while ( $posts->have_posts() ) : $posts->the_post(); ?> <?php echo get_post_modified_time('G:i T, l j F Y'); ?> <?php endwhile; else : ?> <p class="su-posts-not-found"><?php esc_html_e( 'Posts not found', 'shortcodes-ultimate' ); ?></p> <?php endif; ?>
- In any widget or post/page (I’m showing this info using a widget in a dynamic sidebar), paste the following shortcode:
Last update time: [su_posts template="templates/lastupdate-loop.php" posts_per_page="1" post_type="post,page" order="desc" orderby="modified" post_status="any"]
What this shortcode exactly does?
This shortcode is showing the content for all the post and pages (post_type=”post,page”), with any post status (draft or published), and I’m calling only one item (posts_per_page=”1″), sort by modified date (order=”desc” orderby=”modified”).
It would return the last post or page I modified and, as you can see in the template I made, I’m showing only the_modified_time, which is the only data I need.
In the template code I used the following date format:
<?php echo get_post_modified_time('G:i T, l j F Y'); ?>
To show the date in the format you want, read Customize date and time format.
Complicated… And tricky!
I know.
But, as I’m not a backend, I really needed to find a shortcode solution that helps me to tell the users when whas the last time I made some changes in the website.
Cheers!
Forum: Developing with WordPress
In reply to: How to display the last update time on THE SITE?Am I asking the most complicated simple question in the WordPress knowledge? : )
It doesn’t seem clear what you are trying to ask. I assume you want to show these links in black colour, and then turning them to underline and light blue coloured when hovering them. Is that correct?
This is just a CSS issue that you can quickly solve with this code. If you aren’t familiar to CSS code, just copy and paste this code in your theme Customizer (look for some “Custom CSS” area to paste it):
#bahanKosmetikA ul li a { color: #000; } #bahanKosmetikA ul li a:hover { color: #0eb2e7; text-decoration: underline; }
But, assuming your words, you want to apply this style ONLY to that specific page (which ID is 18964):
#page-id-18964 #bahanKosmetikA ul li a { color: #000; } #page-id-18964 #bahanKosmetikA ul li a:hover { color: #0eb2e7; text-decoration: underline; }
Forum: Developing with WordPress
In reply to: parent page with child sectionHello,
The example you are showin is just a page with the content distributed with accordions that you can create with plugins like Shortcodes Ultimate (the one I use).
Even if you want to list the child pages for a parent page, that same plugin does it using the “Child pages” shortcode.
But I think you might just group your FAQ content in plain accordions. No child pages needed on your example.
Forum: Reviews
In reply to: [Custom post types, Custom Fields & more] Very Spammy Plugin100% agree.
Please remove the spam banner.
Hope to get some way to sort the search results page in a more useful design (more like a real search engine) as this feature is a big lack in 99% of WordPress themes. Just as a suggestion. Thank you one more time!
Get it in the last update. THAAAANK YOU so much guys! Congrats for such a great plugin :-)))))
Forum: Fixing WordPress
In reply to: Gravatar isn’t showing up on dashboardOuch! You’re right ?? Thank you so much!
Forum: Plugins
In reply to: [GravityExport Lite for Gravity Forms] Capabilities and user errorSame error here, but I doesn’thave the plugin “Gravity Forms Entries in Excel”. Only GF and Gravity Perks. So maybe isn’t an error related “Gravity Forms Entries in Excel”.
Forum: Reviews
In reply to: [Remove Orphan Shortcodes] UselessI read the plugin name. I made my rating based on my opinion. You must respect that ??
Forum: Reviews
In reply to: [Remove Orphan Shortcodes] UselessYou think that? I’m still reading “Remove Orphan Shortcodes” ??
Forum: Plugins
In reply to: [Stackable - Page Builder Gutenberg Blocks] Fatal error while activatingThank you so much Benjamin! :)))
Forum: Fixing WordPress
In reply to: Catchable fatal error on wp-includes/category-template.phpOk: the problem has “solved”.
I did the following:
- Switched the theme for the parent theme
- Switched again to the child theme
- Clean Siteground’s cache
Everything’s ok, but I found that all the widgets are misplaced, so I’ve to restore manually one by one.
Curious things that just happens with WordPress and bad coded templates.
Thanks anyway for helping, Giancarlo!
Saludos : )
Forum: Fixing WordPress
In reply to: Catchable fatal error on wp-includes/category-template.phpCiao Giancarlo!
I don’t have these lines on my wp-config.php (I just have set the line
define('WP_DEBUG', false);
).According the article you mentioned, it doesn’t resolve my issue, but puts me on the line about what I did wrong:
I moved the site from Siteground to another Siteground hosting (so is using the same PHP version). But what I did is the following:
- Downloading the ftp and SQL file from the old hosting
- Inside the SQL files, I replaced the following lines:
/home/acompany/public_html/marquezyabogados.es
to the following: /home/guillemm/public_html/marquezyabogados.es - Import this new SQL to the new Cpanel
I just replaced the “/acompany” path to “/guillemm”. And I think this is generating some issue with the template and the database, but I cannot find exactly the error : (
If you think you’ve some idea what’s happening, I will appreciate very much your help : )
Grazie mile per l’aiuto!
Chris.
- This reply was modified 8 years ago by Christian Rodríguez. Reason: HTML editing
Hello!
I manage a lot of WP sites and all of them are using MonsterInsights, and this is the first time I see this issue.
I read the options you mentioned but I’m not sure which one could be. I will contact you in case this issue repeats again.
Thanks for helping!
Chris.