New to Telerik UI for ASP.NET AJAX? Download free 30-day trial

Right-to-Left Support

Enter the code sent to your phone

The default language input for most users of the web is left-to-right. However, the Right-to-Left (RTL) functionality enables you to properly render languages, such as Hebrew and Arabic, thus making your app a truly global one and helping your localization efforts.

The WebForms OTPInput component comes with built-in right-to-left (RTL) support and offers right-to-left rendering.

This demo shows how to set the OTP Input RTL functionality by wrapping the OTPInput element in a container div element with dir="rtl".

  • DefaultVB.aspx
  • DefaultVB.aspx.vb
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="DefaultVB.aspx.vb"  Inherits="OTPInput_Accessibility_and_Internationalization_RTL_DefaultVB" %>

<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>

<!DOCTYPE html>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head runat="server">
    <title>Telerik ASP.NET Example</title>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
    <div class="demo-container no-bg flex-center" runat="server">
        <div dir="rtl">
            <span>Enter the code sent to your phone</span>
            <telerik:RadOTPInput ID="OTPInput1" runat="server" FillMode="Outline">
                <Items>
                    <telerik:OTPInputItem GroupLength="3" />
                    <telerik:OTPInputItem GroupLength="2" />
                    <telerik:OTPInputItem GroupLength="3" />
                </Items>
            </telerik:RadOTPInput>
        </div>
    </div>
    </form>
</body>
</html>

Support & Learning Resources

Find Assistance