Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
How to customize the comments form
I’m having really hard time trying to customize the layout of my sites comment form. Can I apply styles to preview and send buttons? What about the form itself?
Iwant this:
http://samilaakso.viuhka.fi/my-life#cpreview (it’s a bit skrewed because of my testing right now)
To look like this:
http://samilaakso.viuhka.fi/ota-yhteytta
It would be simple if I could apply a style to codes like this:
<txp:comment_preview />
I tried to replace it with lines I copied from the source code but then it doesn’t work right.
Offline
Re: How to customize the comments form
You can style the buttons by using the IDs provided (#txpCommentSubmit
, #txpCommentPreview
).
#txpCommentSubmit {
width: 123px;
height: 25px;
border: 0;
margin: 0 0 13px 10px;
background: url(images/nappulat.png) no-repeat -459px 0;
/*
Hides Text and outline.
*/
font-size: 1px;
outline: 0;
color: #fff;
text-indent: -1000em;
float: right;
}
#txpCommentPreview {
[...]
Offline
Re: How to customize the comments form
Thanks! Vai pitäisikö sanoa kiitos?
There’s still one tiny problem. I can’t get the text (value) from the button to disappear.
Last edited by Liuhuparta (2010-04-12 21:33:53)
Offline
Re: How to customize the comments form
Liuhuparta wrote:
Thanks! Vai pitäisikö sanoa kiitos?
Ihan kumpi vaan :-)
There’s still one tiny problem. I can’t get the text (value) from the button to disappear.
As long as the text is aligned to left, the negavite text-indent should remove the text. And it should work on every modern browser except for IEs.
This thread @ Stackoverflow forum might give some helpful pointers. Actually almost every method is mentioned there.
I personally use floating and negative text-indent. 1px text-size is there as a fix for IEs.
Offline
Re: How to customize the comments form
Thanks. All problems solved.
Offline