1

I didn't know how exactly I should form my title, so the question may be little different. I am new with WordPress developing and would need some advice. I don't need any code, I just want to hear your advice.

I have a page Books, and I'd like to allow admin to add books to that page through the admin dashboard. Basically, admin should only be able to enter 3 params (image, title, content) for every book he wants to add. Every book has the same HTML markup, only parameters are different. What would be the best way to implement this? I was thinking about creating a widget for that. Should I go with widget, plugin, or with something else?

<div id="book-wrap">
     ... every added book markup goes here
</div>

2 Answers 2

1

If you want to do it the "WordPress-way", you would create a custom post-type for books called "book" ( For this take a look at https://codex.wordpress.org/Function_Reference/register_post_type ). Then you would create an archive page for that post-type called "archive-book.php".

I hope this helps a little bit. If you need more help, let me know.

0

You should use widgets for that only if the books there will be needed temporary when you delete widget its contents are deleted too.

Otherwise, create book custom post type, then you can add metaboxes for your needed data.

Then you can create a page template with WP_Query loop to display all books.

If your admin needs to re-order books on the page I would recommend using this plugin: https://wordpress.org/plugins/post-types-order/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.