前面介绍了微活动《大转盘》 和 《刮刮卡》,这次介绍下微投票,微投票分二种,一种是文本投票, 一种是图片投票。

 

下面介绍文本投票的详细步骤:

 

用c#开发微信 (17) 微活动 3 投票活动 (文本投票)

 

  • 代码实现:
>
            
                <dl>
                    <dt>投票标题:</dt>
                    <dd>
                        <asp:TextBox runat="server" ID="title" CssClass="input normal" datatype="*1-100" sucmsg=" " nullmsg=" "></asp:TextBox>
                        <span class="Validform_checktip">*</span>
                    </dd>
                </dl>
          
               
 
                <dl>
                    <dt >投票图片:</dt>
                    <dd>
                        <asp:TextBox runat="server" CssClass="input normal upload-path" ID="votepic"></asp:TextBox>
                         <div class="upload-box upload-img"></div>
                   
                    </dd>
                </dl>
 
   
                <dl>
                    <dt>
                      图片显示:
                    </dt>
                    <dd>
                         <div class="rule-multi-radio">
                        <asp:RadioButtonList ID="picdisplay" runat="server" RepeatDirection="Horizontal" RepeatLayout="Flow">
                            <asp:ListItem  Value="True" Selected="True">显示在投票页面</asp:ListItem>
                            <asp:ListItem  Value="False" >不显示在投票页面</asp:ListItem>
 
                        </asp:RadioButtonList>
                    </div>
                    </dd>
                </dl>
               
                <dl>
                    <dt>投票说明:</dt>
                    <dd>
                     
                  <textarea name="txtactContent" rows="2" cols="20" id="txtactContent" class="input" runat="server"></textarea>
                    <span class="Validform_checktip"></span>
                    </dd>
                </dl>
                    
 
                  <dl>
                    <dt>单选/多选:</dt>
                    <dd>
               
                         <div class="rule-multi-radio">
                        <asp:RadioButtonList ID="Radio" runat="server" RepeatDirection="Horizontal" RepeatLayout="Flow">
                            <asp:ListItem  Value="True" Selected="True">单选</asp:ListItem>
                            <asp:ListItem  Value="False" >多选</asp:ListItem>
 
                        </asp:RadioButtonList>
                    </div>
                    </dd>
                </dl>
                <dl>
                    <dt>截止时间:</dt>
                    <dd>
                       <div class="input-date">
                      <asp:TextBox runat="server" ID="begindate" CssClass="input date" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})" datatype="*1-50" errormsg="请选择正确的日期" sucmsg=" " nullmsg=" "></asp:TextBox>
                      </div>
                      <div class="input-date">
                      <asp:TextBox runat="server" ID="enddate" CssClass="input date" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})" datatype="*1-50" errormsg="请选择正确的日期" sucmsg=" " nullmsg=" "></asp:TextBox>
                      </div>
                        <span class="Validform_checktip">*</span>
                    </dd>
                </dl>
                <dl>
                    <dt>投票结果:</dt>
                    <dd>
                        <div class="rule-multi-radio">
                        <asp:RadioButtonList ID="resultShowtype" runat="server" RepeatDirection="Horizontal" RepeatLayout="Flow">
                            <asp:ListItem  Value="1" Selected="True" >投票前可见</asp:ListItem>
                            <asp:ListItem  Value="2" >投票后可见</asp:ListItem>
                            <asp:ListItem  Value="3" >投票结束可见</asp:ListItem>
                        </asp:RadioButtonList>
                    </div>
                      
                    </dd>
                </dl>
 
              <dl style="display:none">
                    <dt>投票后参加活动:</dt>
                    <dd>
                      <asp:TextBox runat="server" CssClass="input normal upload-path" ID="actUrl"></asp:TextBox>
                      
                    </dd>
                </dl>
 
        </div>

相关文章:

  • 2022-01-20
  • 2021-12-31
  • 2021-10-27
  • 2021-05-11
  • 2022-12-23
  • 2021-08-06
  • 2021-11-27
  • 2021-05-20
猜你喜欢
  • 2021-08-25
  • 2022-12-23
  • 2021-04-03
  • 2021-10-02
  • 2021-05-07
  • 2021-12-28
相关资源
相似解决方案