JabbaTheHutt
Regular Member
- May 3, 2016
- 206
- 47
Quick and easy to do...
Add a simple css text box to a post
This is a simple css text box that is good for advertising or alerting your readers to a promotion or a particular point you want to make, you could have a product or service you are selling for example.
You can position a simple css text box anywhere in a post or page, just add the class to the text and it will highlight it in a styled box.
In your child theme style sheet add the code below
.textbox{padding:2px 6px 4px 6px; color: #000; background-color: #fff; border: 1px solid #000;border-bottom:3px solid #000; border-radius:5px;}
Then in your post or page add this <p class="textbox">ADD YOUR TEXT HERE</p> Change the " ADD YOUR TEXT HERE " to whatever text you want. If you want to add a simple css text box to some existing text then just put <p class="textbox"> before the first word and </p> after the last word of the text you want in the box.
That works great too thank you. How do I add an image along with the text but to stay side by side ?
Try the "shortcodes ultimate" free plugin
Yeah, but it will useful for someone who don't have any idea about child theme or don't have theme which doesn't have option to include custom cssWell as outlined above this can be done easily without yet another plugin
Yeah, but it will useful for someone who don't have any idea about child theme or don't have theme which doesn't have option to include custom cssand even it has a lot of features not just limited to a red text box.
it's funny how most of us have zero clue how to use html/css or whatever crap it is required to make that possible including myself, we just rely on plugins and quick-fixes lol so jokes
Actually that plugin also done that via pre coded css but it gives UI to use all the required function on a single click. The suggestion i made is just for people who don't know css, i hope you understand what i'm trying to sayusing css you are not limited to a red text box, you can change the background colour, use dotted lines as border etc
Actually that plugin also done that via pre coded css but it gives UI to use all the required function on a single click. The suggestion i made is just for people who don't know css, i hope you understand what i'm trying to sayi don't want to continue this discussion
![]()
Could someone tell me how to do this red square inside a Wordpress post or page ? or any free plugins which can do it.
Could someone tell me how to do this red square inside a Wordpress post or page ? or any free plugins which can do it.
Sorry, I actually misunderstood. I thought you were trying to get rid of the box. Okay, so if you want to do a similar box you can do so with code for sure. Google "How to make a colored box html css" in Google. You should find the answer. I would like to post the code here in the comment but somehow I don't like moderators would like it, and may see it as me trying to manipulate the code. You can also just use a theme that does this.