Case-Based Critical Thinking Questions
Case 6.1
Andy designed a web page for a product-oriented industry using CSS properties. He used several HTML tags to create the web page. He also used tables to ensure that data management is easy.
Andy has created a table for product details where "Product Name" and "Product Price" are the headers of the table. Which of the following style rules should he add to place a border of 10-pixels around the table with a white background?
Select one:
a. table.product {border: white; width: 100%;}
b. table.product {background: white, 10px; width: 100%;}
c. table.product {background: white; border: 10px; width: 100%;}
d. table.product {border: 10px, white; width: 100%;}
answer C: table.product {background: white; border: 10px; width: 100%;}
It will set border of 10-pixels around the product table with a white background and width of 100%.
option A, B and D are incorrect css format. because in option B background property gives value white and width gives 100%,but no property is added for 10px value.Same like in option d white value has no property. It creates error in css. In option A border gives value white,it is incorrect format. If you want to set border color then give option like "border-color:white" not like border:white. But as per the question it is not needed to set table border colour and only want to set border width 10pixels. And there is no option for background property also. So Answer C is correct for the question.
Get Answers For Free
Most questions answered within 1 hours.