-
AuthorPosts
-
September 25, 2023 at 7:32 pm #1420324
Hi
We use your upcoming events content element but now we see that the ordering is wrong. See private content.
When we wre in the administration of the events, the ordering is correct.
Also when we use the original events URL, the ordering is correc.t
Thans for help/fixing.
Best regards
MikeSeptember 26, 2023 at 5:20 am #1420353Hey Michael,
Thank you for the inquiry.
We may need to access the site in order to properly check the issue. Please provide the WP and S/FTP details in the private field. In the meantime, please try to edit the enfold/config-templatebuilder/avia-shortcodes/events_upcoming/events_upcoming.php file around line 483.
$query = array( 'paged' => $this->current_page, 'posts_per_page' => $params['items'], 'start_date' => 'now', 'eventDisplay' => 'list' );
Replace it with:
$query = array( 'paged' => $this->current_page, 'posts_per_page' => $params['items'], 'start_date' => 'now', 'eventDisplay' => 'list' );
We just replaced start_date with “now”. Let us know if this changes anything.
Best regards,
IsmaelSeptember 26, 2023 at 7:44 am #1420375Hi Ismael
We changed the code in enfold/config-templatebuilder/avia-shortcodes/events_upcoming/events_upcoming.php from $start_date to ‘now’ but this changed nothing.
See the login data in the private content section.
Best regards
MikeSeptember 27, 2023 at 7:12 am #1420660Hi,
Thank you for the info.
We can’t access the server using the FTP account above. We have tried both FTP and SFTP. Please check the info carefully, or provide another account.
We have modified the query it a bit. Please try it again.
$query = array( 'paged' => $this->current_page, 'posts_per_page' => $params['items'], 'start_date' => 'now', 'eventDisplay' => 'list', 'orderby' => 'meta_value', 'meta_key' => '_EventStartDate', 'order' => 'ASC', 'tribeHideRecurrence' => false );
Best regards,
IsmaelSeptember 27, 2023 at 7:25 am #1420663Hi Ismael
The FTP should work.
See all details of our connection we do over Filezilla.
By the way, with your new code, the ordering is still false.
Best regards
MikeSeptember 27, 2023 at 9:38 am #1420672Hi,
We are still not able to establish an FTP connection, so it is possible that the access may be restricted to specific countries. Please make sure that the server allows access from the following countries (see private field).
Best regards,
IsmaelSeptember 27, 2023 at 9:47 am #1420673Hi
We have no country restriction.
We have made you a new FTP account, please try with this.
Best regards
MikeSeptember 28, 2023 at 8:42 am #1420773Hi,
Thank you for the update.
Looks like the events get mixed up when the tax_query is set. To fix the issue temporarily, we reverted the events_upcoming.php file back to default, then added this code in the functions.php file.
add_filter('avia_tribe_events_upcoming', function($query, $params) { unset($query['tax_query']); return $query; }, 10, 2);
Best regards,
IsmaelOctober 2, 2023 at 2:04 pm #1421138Hi Ismael
We added the code and the ordering is still the same.
Best regards
MikeOctober 2, 2023 at 3:48 pm #1421161Hi,
We edited the events_upcoming.php file again and adjusted the query. This seems to have corrected the ordering of the events.
$query = array( 'posts_per_page' => $params['items'], 'start_date' => 'now', 'eventDisplay' => 'custom', 'tribeHideRecurrence' => true );
Best regards,
IsmaelOctober 2, 2023 at 4:04 pm #1421168Hi Ismael
Unfortunately the ordering ist still wrong, see URL in the private section.
Seems to be a cracknut ;-)
Best regards
MikeOctober 3, 2023 at 5:26 am #1421231Hi,
The items are sorted correctly on our end aside from the “Carnaval de Romont” event, which should start on February 2024 but is positioned between March and April 2024. We are not yet sure why this is happening.
Best regards,
IsmaelOctober 3, 2023 at 9:53 am #1421259Hi Ismael
Yes, that’s exactly the point.
The ordering also was correct before chaning the events_upcoming.php and before adding the code into functions.php.
All is correct except the “Carnaval de Romont” event.
But it should be a problem of your element “Upcoming Events” because in the default The Events Calendar List, the ordering was correct before changing the code.
Best regards
MikeOctober 3, 2023 at 11:47 am #1421274Hi,
We’ve been adjusting the query for a while, but we can’t get the “Carnaval de Romont” to display where it should. We’ll forward the thread to other mods for further investigation.
Best regards,
IsmaelOctober 10, 2023 at 9:35 am #1421981Hi Ismael
Ok, thanks very much.
Hope there will be a solution as soon as possible.
Best regards
MikeOctober 24, 2023 at 12:55 pm #1423563Hi,
Apologies for the delay. We’ve recreated Carnaval de Romont B, and it appears to be correctly positioned in the right place. Could you please remove the older event and replace it with the one in the private field?
Best regards,
IsmaelOctober 24, 2023 at 1:20 pm #1423571Hi Ismael
Thanks. We replaced the event with the new one and it works.
But you do not know, what was the problem?
Best regards
MikeOctober 24, 2023 at 3:38 pm #1423593Sorry to jump on the thread, but I can’t find the “upcoming events content element” in ALB. I can see the code under avia-shortcodes but there’s nothing about events in Enfold documentation either. What is this element and how do I see/try/use it?
October 24, 2023 at 3:53 pm #1423594Hi @jacksgallery,
You can find this element in the Plugin Additions tab of Advanced Layout Builder after installing The Events Calendar ( https://wordpress.org/plugins/the-events-calendar/ ) plugin.
Best regards,
YigitOctober 26, 2023 at 6:48 pm #1423829Hi YourChoice Informatik GmbH,
It must have been a problem in database – no idea if related to WP or Tribe not updateing a database field that is responsible for ordering.
If such strange things occur it is always a good idea to create a new post/event/entry and delete the old one.
Best regards,
GünterOctober 27, 2023 at 8:34 am #1423879Hi Günter
Thanks for your response.
Yes, I think it’s the best way to recreate a post in this case.
I think this task can be closed.
Best regards
MikeOctober 27, 2023 at 1:48 pm #1423911to this topic possibly one more. I have made the experience that plugins like : Post Types Order could interfere here.
October 27, 2023 at 2:00 pm #1423912okey, thanks for information.
October 29, 2023 at 12:42 pm #1424005Hi,
Glad Günter could help, we will go ahead and close this thread as you requested, if you have any further questions please create a new thread and we will gladly try to help you. Thank you for using Enfold.Best regards,
Mike -
AuthorPosts
- The topic ‘Wrong order of upcoming events’ is closed to new replies.