zoukankan      html  css  js  c++  java
  • [总结]工作中常用的正则表达式,有了它事半功倍!

    1.给现有的DropDownList添加项目!

    例如:
    <asp:DropDownList id="ddlF1127" runat="server">
    </asp:DropDownList>

    文档中有如下信息

    1 Own Home Outright
    2 Buying Home
    3 Living with Relatives or Friends
    4 Leasing/Rent
    5 Departement housing
    6 Aboriginal housing

    那么用正则表达式
    {:z} {[a-zA-Z:Zs\/]+}

    <asp:ListItem Value =\1>\2</asp:ListItem>
    可以替换为
    <asp:DropDownList id="ddlF1127" runat="server">
                                
    <asp:ListItem Value="1">Own Home Outright </asp:ListItem>
                                
    <asp:ListItem Value="2">Buying Home </asp:ListItem>
                                
    <asp:ListItem Value="3">Living with Relatives or Friends</asp:ListItem>
                                
    <asp:ListItem Value="4">Leasing/Rent</asp:ListItem>
                                
    <asp:ListItem Value="5">Departement housing</asp:ListItem>
                                
    <asp:ListItem Value="6">Aboriginal housing</asp:ListItem>
                            
    </asp:DropDownList>
  • 相关阅读:
    yum puppet dashboard
    puppet常用调试命令
    mysql oracle静默 一键安装脚本
    libvirt 基于C API基本使用案例
    mysql二进制
    mysql启动停止,一台服务器跑 多个mysql数据库
    mysql binaryVInstall
    Centos6.x/Oracle11G 自动化静默安装配置脚本
    最受欢迎linux命令
    xpages很不错的demo
  • 原文地址:https://www.cnblogs.com/goody9807/p/263277.html
Copyright © 2011-2022 走看看