Home › Forums › Calendar Products › Events Calendar PRO › Updated to 4.0, excerpt problem
- This topic has 14 replies, 8 voices, and was last updated 10 years, 4 months ago by
Josh.
-
AuthorPosts
-
December 3, 2015 at 7:26 am #1034656
Ching Hong
ParticipantWhen I updated to 4.0, at the photo view, it is now showing full Description, not excerpt of description. How can solved this problem? Please advice.
My web site become this…..
http://locuslearning.com/events/photo/
Thank you.
Chris Man
December 3, 2015 at 9:05 am #1034779Josh
ParticipantHey,
Thanks for reaching out to us and bringing this issue to our attention!
We’ve got this bug logged in our internal tracking system and will notify you here as we make progress on this issue. I apologize for any inconvenience that this issue has caused.
In the meantime, you can fix this issue by making some quick modifications to the core plugin. These changes will get overridden with the next update which will include an official fix to this issue.
Within the main Events Calendar plugin, navigate to the src > functions > template-tags > general.php file and open it within your preferred text editor.
Navigate to line #1320 within that file. It should look like:
$excerpt = wp_trim_excerpt( $excerpt );You can change that line to be:
$excerpt = wp_trim_words( $excerpt, '55' );Where “55” is the number of words that you would like the excerpt to be there.
Let me know if you have any further questions or concerns here.
Thanks!
December 3, 2015 at 5:34 pm #1035170Ching Hong
ParticipantNo, it’s still can’t fix the problem. Probably is it because we are using Chinese? Or any reason? Thank you.
Chris Man
December 4, 2015 at 12:14 am #1035259Konrad
ParticipantIn german it does not work also.
December 4, 2015 at 2:56 am #1035286Jonathan Sanderson
ParticipantThe suggested fix is working here (in English).
December 4, 2015 at 7:41 am #1035519Jan
ParticipantIt doesn´t work for the german version.
December 4, 2015 at 8:18 am #1035558Krisztián
ParticipantHello,
It didnt fix the problem in photo view on my site too
Josh, Do you have another code for the photo view please?
Thank you
December 4, 2015 at 9:23 pm #1035850Barbara
ParticipantI have this issue as well in the Dutch version. Haven’t tried the code change yet.
Be advised that when you actually use the ‘excerpt’ function on the ‘Edit Event’ page, that excerpt will be used on the list/month view.
It will take some effort to add those excerpts to all events obviously, but now that I have ‘discovered’ this, I actually think it might be better to be forced this way to start using the manual excerpts.
It will be tricky though when changing things in the future about the event, you’ll need to be very sure about changing it in the excerpt also!
December 5, 2015 at 1:32 pm #1036138Marian
Participantsame problem in the list “it is now showing full Description”
update Please
Thank you
December 7, 2015 at 5:15 pm #1037253Josh
ParticipantHey,
Thanks for following up here.
I’m not sure what’s going on with the different translations. Reviewing the documentation for the function used here, it sounds like it should work with localization however the majority of feedback here is that it isn’t.
We do have the bug logged a more complete solution should be released in an upcoming update to the plugin, however another “quick” fix until then is to do as Hans has suggested here and use the excerpt field for the events. The function used to populate this content will first check the excerpt field and if it’s empty will use wp_trim_words (based on suggested update above) to shorten the content.
Thanks!
December 7, 2015 at 11:37 pm #1037324Jan
ParticipantHey Josh,
i´ve already tried your suggested solution, but it doesn´t work. It just appears an error message. I am using the german translation.
December 8, 2015 at 1:54 am #1037356Konrad
Participant@Jan: there must be a typo somewhere!
@all: it is working in German too. T I did not read and follow your solution carefully enough.I changed the original line
$excerpt = wp_trim_excerpt( $excerpt );
to
$excerpt = wp_trim_excerpt( $excerpt, '55' );
but should have changed to
$excerpt = wp_trim_words( $excerpt, '55' );
(It is not just adding the numbers – note the difference in the function name)December 8, 2015 at 2:04 am #1037358Jan
ParticipantWTF!? It´s working now – without any error message. Great. THX!
December 8, 2015 at 5:51 pm #1037903Ching Hong
ParticipantIt works finally (Chinese)! Thanks so much! Thank you all!
Chris Man
December 10, 2015 at 8:06 am #1038897Josh
ParticipantHey Everyone!
Awesome! I’m glad that the solution is working for you now!
I’ll go ahead and close this thread for now. If you have any further questions, please don’t hesitate to open a new thread.
Thanks!
-
AuthorPosts
- The topic ‘Updated to 4.0, excerpt problem’ is closed to new replies.
