I see you haven’t read the documentation so I’ll drop you a link 😉
https://github.com/picandocodigo/List-Category-Posts/wiki/HTML-&-CSS-Customization
TL;DR
morelink_class and/or morelink_tag
Ah thanks, I didn’t see that part of the documentation, I was looking under More parameters you can use
But I have tried this and does not seem to be working, what am I doing wrong:
[catlist id=8 excerpt_size=60 excerpt=yes orderby=date posts_morelink="Read more…" morelink_tag=p morelink_class=morebutton title_class=lcp_title title_tag=h3 numberposts=-1 order=DESC thumbnail=yes]
The tag and class are not there when I view page source in inspect elements.
Thanks.
posts_morelink is not morelink, if you use posts_morelink you need to use posts_morelink_tag etc.
Thank you of course.
posts_morelink_class is working fine but posts_morelink_tag=p is not inserting a p tag (I have tried p, span, div)
This is because this parameter is not supported, if you go back to the docs you’ll see posts_morelink_tag is not listed there. (I somehow missed that in my previous post) In the current implementation you can only specify posts_morelink_class and it will be applied on the anchor element.
There is a pull request on Github that fixes this but it hasn’t been merged yet.
If the only thing you need is a <p> like functionality you can specify display: block; for the class set in posts_morelink_class and then apply any other CSS you want.
-
This reply was modified 7 years, 9 months ago by
zymeth25.
If the only thing you need is a <p> like functionality you can specify display: block; for the class set in posts_morelink_class and then apply any other CSS you want.
Yes, that is what I did to get round it, but I wanted to be able to make it like an inline button on a separate line.display:block causes it to be full width or specific width, rather than stretching to accommodate the text.
You can try display: table which should achieve what you need. No other workarounds I can think of. You can also check out custom templates.
You can try display: table which should achieve what you need.
Thanks that works perfectly