Anonymus
Forum Replies Created
-
@deip In inc/shortcode.php this part is the key:
if ( $ismulti ) { $limit = isset( $attr['limit'] ) ? (int) $attr['limit'] : 5; $ids = array(); $books = explode( ',', $atts['books'] ); foreach ( (array) $books as $query ) { $query = trim( $query ); if ( is_numeric( $query ) ) { array_push( $ids, $query ); } else {...}Because of is_numeric( $query ) condition, we can use books=”id” to show a single book, or books=”id1, id2, id3, …” to show some books. If category slug is a number, for example a year (what I used), the plugin interpret as book id.
Suggested solution: for category shortcode change attribute books to category.
@deip Hm, there is something in the background.
Now I updated the plugin from 1.7.5.1 to 1.7.6.1, and magic happened, category shortcode works for the 4 books. Ok, there is another (empty) category, so let’s test it.
I have 4 books (with PDF source). Now 2 books (3, 4) in category A, and 2 books (1, 2) in category B. Category shortcode works with category A, but not works with category B, after category setting changed on 2 books.
For testing purpose, I disabled all plugins (except DearFlip), and changed the theme to another, but nothing happened. After that, I disabled post revision feature (via wp_config) and deleted revisions (from wp_posts table), but nothing happend. Finally I changed category settings on all books, and now book 1, 3 are in category A, and 2, 4 are in category B. Category A shortcode still working, but category B shortcode not changed, shows one empty book cover.
Is there a cache method in the background?
- This reply was modified 4 years, 12 months ago by Anonymus.