royaltask
Forum Replies Created
-
I tested gtranslate today: Unfortunately not. It loads resources from gstatics if hovering the flags language selector (no click! just hover). This needs to be fixed! eg: https://www.gstatic.com/images/branding/googlelogo/1x/googlelogo_color_42x16dp.png
- This reply was modified 2 years ago by royaltask.
Forum: Plugins
In reply to: [Custom Widget Creator] Link JSthis would be great!
Forum: Themes and Templates
In reply to: [Qi] How to setup a side areaThank you so much! I will test.
Forum: Themes and Templates
In reply to: [Qi] Sticky menu full width on boxed width templateThank you. Looks better now 😉
You need to get this solved in your software.
I have added a solution in functions.php that removes events by end-date not expiry date field.
Thomas let me know if you need help here and get in contact.
Thank you Angelo! Worked fine!
I managed it with a hook:
$listings = get_posts( $args ); foreach($listings as $post) : setup_postdata($post); $today = date( 'Ymd' ); // get date $expire = get_field( '_event_end_date' ); // get event_end_date $expire = str_replace("-", "", $expire); // same date format if ( $expire < $today ) : // compare $status = '_event_end_date'; $post->post_status = 'draft'; // change post status wp_update_post( $post );Table looks nice, how do you change the date format into German 01.01.2020?
- This reply was modified 5 years, 11 months ago by royaltask.
I almost got the automatisation working, _event_expiry_date gets changed automatically – event status is still active and shows 01.01.1970..”get_field” is not valid? I want to compare _event_end_date < $today .Let me know how to get this done:
// Create a cron job in order to check the custom field of '_event_end_date' against today's date. If the date has passed, set the _event_expiry_date status to '_event_end_date' and hide expired events online function check_event_end_date( ) { global $post; $args = array( 'post_type' => 'event_listing', 'posts_per_page' => -1, ); $listings = get_posts( $args ); foreach($listings as $post) : setup_postdata($post); $today = date( 'Ymd' ); $expire = get_field( '_event_end_date', false, false ); //$status = get_field( '_event_expiry_date' ); if ( $expire < $today ) : $status = '_event_end_date'; update_field( '_event_expiry_date', '$status' ); endif; endforeach; } // Schedule Cron Job Event if ( ! wp_next_scheduled( 'event_listing_cron_event' ) ) { wp_schedule_event( date( 'Ymd' ), 'daily', 'event_listing_cron_event' ); } add_action( 'event_listing_cron_event', 'check_event_end_date' );- This reply was modified 5 years, 11 months ago by royaltask.
- This reply was modified 5 years, 11 months ago by royaltask.
- This reply was modified 5 years, 11 months ago by royaltask.
- This reply was modified 5 years, 11 months ago by royaltask.
- This reply was modified 5 years, 11 months ago by royaltask.
How can I achive this:
if I have set up an expiry date in admin then it will set that date. (works fine!)If I have published the end date without changing the expiry date field then it will create event end date as the event expiry date?!
I just want to hide events older that the end date!
- This reply was modified 5 years, 11 months ago by royaltask.
Can you help us with this? My events never expire, I have to set this manually for every event. I want to hide events older than _event_end_date!
- This reply was modified 5 years, 11 months ago by royaltask.
I checked “events expire on the event end date”, events in the past are still showing in my listing. This is a common feature, how come past events are still showing?
Thank you, this feature would be great to see in an Update. At the moment I cannot use the Witget of Elementor because of this missing function.
Forum: Plugins
In reply to: [Polylang] Show same post if translation doesnt exist?Plugin is great, some feature are still missing, though.
Forum: Plugins
In reply to: [Polylang] Home if no translateDid you find a solution. My only solution is to add a translated page with a redirect to HOME. Not fancy I know, but do you have a solution?