True or False? If false why? A master page can contain only one ContentPlaceHold
ID: 3821985 • Letter: T
Question
True or False? If false why?
A master page can contain only one ContentPlaceHolder in the form section. You always navigate to a content page, never a master page. Cascading style sheets can be linked to a content page only. If a master page is currently open in the editor, you can find the Add Content Page section in the Website menu. The Masterpagefile property of the Page directive in a content page identifies the filename of the master page. You can set the default master page filename in web.config. The FindControl method cannot be used by code in a content page to reference a control on its master page. The Load event for a content page occurs before the Load event for its master page. You select a GridView auto format from the View window. When you create a connection to an SQL Server Database on a Web Form, Visual Studio automatically inserts an SOLDataSource control on the form. In a connection string in web.config, the FileName property shows the path to the database file. If you place a database file in any folder belonging to your Web site, you can use the DataDirectory keyword to identify the database p in the connection string. In the Configure Data Source wizard, click the Advanced button to let Visual Studio generate insert, update and delete queries. To change the horizontal alignment of a column in a GridView, navigate to the ItemStyle property. The Details View control displays only one data source row at a time. The StartingMode property of a DetailsView control selects its starting state when it first becomes visible. The DatavalueField property of a ListControl identifies the column that will be displayed in the list.Explanation / Answer
1. False
Explanation: Master pages should not contain form tags in general because they are meant to be used only as the base layout of your content page. Remove the form tag from the Master page and the error will go away.
2. True
Explanation:
A page can derive from a Master Page by defining a MasterPageFile attribute on its Page directive. A page that is associated to a Master Page is called a Content Page. A Content Page can declare Content controls that specifically override content placeholder sections in the Master Page.
3. False
Explanation:
One of the benefits of CSS is the separation of content and presentation. CSS rules can be provided in a file that is separate to the (content) HTML. If all pages link to this centralised CSS file, then the look of a website can more easily be updated. For example, the colour or size of all level-one headings can be changed by updating a single CSS rule.
4. True
Explanation:
A master page is the template for “how your pages will look”?. In this section, first create a master page. Then use a table to layout the master page with a menu, a logo, and a footer that will appear on each page of your site. Also , work with a content placeholder can be done, which is a region in the master page that can be replaced with information in a content page.
5. True
Explanation:
As explained in MSDN , if a page shows the master page definition as "~masterurl/default.master", this does not mean that the master page is actually a file called "default.master". This is actually a tokenization used in the MasterPageFile attribute, and loads whatever value is set in the object model for SPWeb.MasterUrl or SPWeb.CustomMasterUrl depending on the page type.
MSDN rule:
Dynamic token "~masterurl/default.master"
This token references a master page from a content page by using the MasterPageFile attribute together with the value of the MasterUrl property.
6. True
Explanation:
The time you start developing your web application until you finish the application, you will more often use the Web.config file not only for securing your application but also for wide range of other purposes which it is intended for. ASP.NET Web.config file provides you a flexible way to handle all your requirements at the application level.
7. False
Explanation:
To reference a public member on the master page:
Add a @ MasterType directive in the content page. In the directive, set the VirtualPath attribute to the location of the master page
8. False
9. True
10. True
11. False
12 False
13.True
14. True
15.True
16.False
17.False
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.