Display PDFs with category selector in columns

Here describes how to use shortcodes to display PDFs in columns with category selector.
With category selector, it allows user/visitor to select the category and have all pdfs associated with the category be shown.

Shortcodes

[bsk-pdfm-selector-columns]

Common usage

All categories( exclude specific categories ) in selector, PDFs shown in two columns with featured image.

[bsk-pdfm-selector-columns columns="2" hierarchical="yes" cat_order_by="title" cat_order="ASC"]Show all categories hierarchy as selector, load PDFs under chosen category by Ajax. Order categories by title in ascending when show selector. Order by title with ASC is default.

[bsk-pdfm-selector-columns columns="2" hierarchical="yes" cat_order_by="date" cat_order="DESC"]Show all categories hierarchy as selector, load PDFs under chosen category by Ajax. Order categories by category date in descending order when show selector.

*cat_order_by can only be title or date*cat_order can only be ASC or DESC

[bsk-pdfm-selector-columns columns="2" id="1" password_required="yes"]Require password to show PDFs in the category.

*Works when password has been set to category.

order_byorder

[bsk-pdfm-selector-columns columns="2" id="1,2,3" cat_order_by="title" cat_order="ASC" order_by="date" order="DESC"]Show categories of id in ( 1, 2, 3 ) in selector, order categories by title in ascending, order PDFs by date in descending.

[bsk-pdfm-selector-columns columns="2" id="ALL" cat_order_by="date" cat_order="DESC" exclude_pdf_id="2,3,4,5" order_by="custom" order="ASC"]Show all categories in selector order by date in descending, exclude PDFs with id in( 2,3,4,5 ) in custom ascending order. Check how to set custom order for more.

[bsk-pdfm-selector-columns columns="2" id="7,8,9,1,2,3,4,5,6" cat_order_by="title" cat_order="ASC" order_by="id"]Show categories of id in ( 7,8,9,1,2,3,4,5,6 ) in selector, order catgories by title in ascending, order PDFs by PDF id. Check how to set custom order for more.

*order_by can only be title or date or custom or id*order can only be ASC or DESC

target

[bsk-pdfm-selector-columns columns="2" id="ALL" hierarchical="yes" order_by="custom" order="ASC" target="_blank"] Display all categores with hierarchy in selector, order PDFs in customer ascending order, set PDFs link with target="_blank" attribute, it lets visitor open / view PDF in new window/tab *Only can be set to _blank

most_top

[bsk-pdfm-selector-columns columns="2" id="1,2,3,5" cat_order_by="title" cat_order="ASC" order_by="date" order="DESC" nofollow_tag="yes" most_top="10"] Display categores of id="1,2,3,5" in selector, only show the most top 10 PDFs ( in date descending ) when selector changed. *If this attribute used then search feature(search_bar), pagination(pdfs_per_page) would be disabled.

year_of

month_of

day_of

weekday_of

[bsk-pdfm-selector-columns columns="2" id="ALL" cat_order_by="title" cat_order="ASC" order_by="date" order="DESC" year_of="2017"]Display all categories in selector, only show PDFs which date in year 2017 when selector changed, 9999 means the most recent year( not current year, the year of your last pdf date)

[bsk-pdfm-selector-columns columns="2" id="ALL" cat_order_by="title" cat_order="ASC" order_by="date" order="DESC" month_of="05"]Display all categories in selector, only show PDFs which date in month of May( any year ) when selector changed, 99 means the most recent month( not current month, the month of your last pdf date)

[bsk-pdfm-selector-columns columns="2" id="ALL" cat_order_by="title" cat_order="ASC" order_by="date" order="DESC" year_of="2017" month_of="06"]Only show PDFs which date in month of June & year of 2017 when selector changed

[bsk-pdfm-category-columns columns="2" id="ALL" day_of="11"]Only show PDFs which date in day of 11( any year, any month ) when selector changed, 99 means the most recent day( not current day, the day of your last pdf date)

[bsk-pdfm-selector-columns columns="2" id="ALL" year_of="9999" month_of="99" day_of="99"]Only show PDFs which of the most recent date when selector changed

[bsk-pdfm-selector-columns columns="2" id="ALL" weekday_of="MON"]Only show PDFs which date is Monday( any year, any month any day ), the value can only be MON OR TUE OR WED OR THU OR FRI OR SAT OR SUN

[bsk-pdfm-selector-columns columns="2" id="61,62,63,64,65" pdfs_per_page="10" search_bar="KEYWORDS"] Display categories of id in ( 61,62,63,64,65 ) in selector, show search bar only have keywords field when selector changed

[bsk-pdfm-selector-columns columns="2" id="61,62,63,64,65" pdfs_per_page="10" search_bar="YEAR_KEYWORDS"] Search bar has both year and keywords fields

search_bar_year_rangesearch_bar_year_order

[bsk-pdfm-selector-columns columns="6" id="ALL" pdfs_per_page="10" search_bar="YEAR_KEYWORDS" search_bar_year_range="2015-2018" search_bar_year_order="DESC"] Define the year range of year field in serch bar, show years in descending order.

The default image sizes of WordPress are "thumbnail" (and its "thumb" alias), "medium", "medium_large", "large" and "full" (the image you uploaded).

[bsk-pdfm-selector-columns columns="6" id="7,9,10,12,14,1,2,3" show_pdf_title="yes" featured_image="yes" featured_image_size="medium" title_position="below"]Title won't be shown out if featured image shown, use this parameter to show PDF title with featured image together.

[bsk-pdfm-selector-columns columns="6" id="7,9,10,12,14,1,2,3" cat_order_by="date" cat_order="ASC" order_by="date" order="DESC" show_cat_title="yes" show_cat_description="yes" show_pdf_title="yes" show_description="yes" featured_image="yes" featured_image_size="medium" title_position="above"]If PDF's description or title is shown, then featured image will be placed below title in default. Use title_position="above"may overwtie to place image above title

Advanced Usage

Output container class

Use shortcode parameter of output_container_class to add your own class name to the shortcode output container if you'd like to do custom CSS. Example: [bsk-pdfm-selector-columns output_container_class="my_idenfity_PDFs_container_class"]