This is a migrated thread and some comments may be shown as answers.

How can I center the captcha image?

1 Answer 241 Views
Captcha
This is a migrated thread and some comments may be shown as answers.
WEBSRFR
Top achievements
Rank 1
WEBSRFR asked on 05 Sep 2017, 07:48 PM
How can I center the actual captcha image with the text box and message to "Type the code from the image?"

I have enclosed a screen capture of what it looks like now and as you can see it looks awkward with the captcha image left aligned with the text box and text centered. I'd like everything to be centered.

Thanks for your help!

1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 06 Sep 2017, 11:25 AM

Hello,

I have just answered your support ticket with the same question and I am pasting my answer here for anyone else having similar issues.

The easiest way is to center the container that holds the captcha, as done in this demo: http://demos.telerik.com/aspnet-ajax/captcha/examples/overview/defaultcs.aspx.

The most likely reason for the original problem is some CSS from the page that interferes with the captcha elements: http://docs.telerik.com/devtools/aspnet-ajax/general-information/troubleshooting/skins-troubleshooting#incorrect-or-distorted-appearance.

Another option is to have the capcha render only the image and to have it validate a custom textbos so you can arrange the elements freely on the page (see the ValidatedTextBoxID and CaptchaImage.RenderImageOnly properties used in the code behind): http://demos.telerik.com/aspnet-ajax/captcha/examples/refreshimage/defaultcs.aspx.

 

 

Regards,

 

Marin Bratanov
Progress Telerik
Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Captcha
Asked by
WEBSRFR
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or