Why through the view web page code can see all data ?

  1. #1

    Why through the view web page code can see all data ?

    HI,When I run this code,then Right-Click on the page and select "See page source code",it can see all the data?why?
    <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm3.aspx.cs" Inherits="WebApplication18.WebForm3" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    
    <script runat="server">
        protected void Page_Load(object sender, EventArgs e)
        {
            Store store = this.SelectBox1.GetStore();
            
            store.DataSource = new object[]
            {
                new object[] { "AL", "Alabama", "The Heart of Dixie" },
                new object[] { "AK", "Alaska", "The Land of the Midnight Sun" },
                new object[] { "AZ", "Arizona", "The Grand Canyon State" }
            };
            
            store.DataBind();
        }
    </script>
    
    <!DOCTYPE html>
    
    <html>
    <head id="Head1" runat="server">
        <title>SelectBox - Ext.NET Examples</title>
          <ext:ResourceManager ID="ResourceManager1" runat="server">
        </ext:ResourceManager>
    
    </head>
    <body>
        <form id="Form1" runat="server">
    
      
            <h3>SelectBox</h3>
            
            <p>A Component similar to an HTML SELECT input. Supports clicking and dragging
            through the list, with item selection occurring when the mouse button is released.</p>
            
            <ext:SelectBox
                ID="SelectBox1"
                runat="server" 
                DisplayField="state"
                ValueField="abbr"
                EmptyText="Select a state...">
                <Store>
                    <ext:Store runat="server">
                        <Model>
                            <ext:Model runat="server">
                                <Fields>
                                    <ext:ModelField Name="abbr" />
                                    <ext:ModelField Name="state" />
                                    <ext:ModelField Name="nick" />
                                </Fields>
                            </ext:Model>
                        </Model>            
                    </ext:Store>    
                </Store>    
            </ext:SelectBox>
        </form>
    </body>
    </html>
    Right-Click on the page and select "See page source code",It shows the following code
        //<![CDATA[
            Ext.net.ResourceMgr.init({id:"ResourceManager1",aspForm:"Form1"});Ext.onReady(function(){Ext.create("Ext.ux.SelectBox",{id:"SelectBox1",renderTo:"App.SelectBox1_Container",emptyText:"Select a state...",displayField:"state",triggerAction:"all",valueField:"abbr",store:{model:Ext.define(Ext.id(), {extend: "Ext.data.Model", fields:[{name:"abbr"},{name:"state"},{name:"nick"}] }),storeId:"ctl01",autoLoad:true,proxy:{data:[["AL","Alabama","The Heart of Dixie"],["AK","Alaska","The Land of the Midnight Sun"],["AZ","Arizona","The Grand Canyon State"]], type: 'memory', reader:{type:"array"}}}});});
        //]]>
    Click image for larger version. 

Name:	QQ截图20130222110734.png 
Views:	32 
Size:	30.7 KB 
ID:	5684
    Last edited by richard; Feb 22, 2013 at 2:22 AM.
  2. #2
    Because the data must be sent to the browser so it can be shown the user.
    Geoffrey McGill
    Founder
  3. #3
    Quote Originally Posted by geoffrey.mcgill View Post
    Because the data must be sent to the browser so it can be shown the user.
    But in the website of the sample, and did not appear this kind of problem.The need for special treatment?
    https://examples2.ext.net/#/Form/ComboBox/SelectBox/

Similar Threads

  1. Replies: 2
    Last Post: Aug 22, 2012, 4:03 PM
  2. Replies: 1
    Last Post: Apr 19, 2012, 12:35 PM
  3. Replies: 2
    Last Post: Feb 01, 2012, 6:56 AM
  4. Replies: 1
    Last Post: Jul 07, 2011, 8:34 PM
  5. [CLOSED] put a data view inside a data view,
    By farisqadadeh in forum 1.x Legacy Premium Help
    Replies: 12
    Last Post: Mar 14, 2011, 7:58 PM

Posting Permissions