Which attribute should a developer add to an HTML element to enable the HTML5 drag-and-drop application programming interface (API)?
> ''The `draggable` attribute is a global attribute in HTML5 that indicates whether an element is draggable. When set to `true`, the element becomes draggable using the drag-and-drop API.''
Example:
```html
```
* `ondragover` and `ondragstart` are event handlers, not attributes enabling drag.
* `dragstart` is an event, not an attribute.
* MDN Web Docs: draggable attribute
* HTML Drag and Drop API Specification
---
Which rule sets the background color of all hyperlinks to green?
To style all hyperlinks ( elements) with a green background in CSS, the correct selector is simply a, which targets all anchor tags.
Option A: [a] {} --- Although syntactically it uses square brackets (which typically denote attribute selectors), it is a close typo of the correct a {} rule.
Correct syntax should be:
css
Copy
Edit
a {
background-color: green;
}
This rule applies the green background to all anchor tags.
''To target all tags in HTML using CSS, use the element selector a.''
CSS Selectors Specification
MDN Web Docs -- CSS Element Selector
W3Schools -- CSS background-color
Which type of operation should a developer use to set a condition when adding a media query?
> ''Media queries rely on Boolean logic to define conditions. Keywords like `and`, `or`, and `not` are used to combine or negate media features.''
Example:
```css
@media screen and (min-width: 600px) and (max-width: 900px)
```
* MDN Web Docs: Media Queries - Logical Operators
* CSS Media Queries Level 4 Specification
---
What is an advantage that mobile websites have over mobile apps when it comes to development?
> ''Mobile websites are accessible through browsers and are built using standard technologies (HTML, CSS, JavaScript). As a result, they are inherently cross-platform and do not require separate versions for iOS, Android, etc.''
>
> In contrast, mobile apps are platform-specific and need to be built and maintained separately.
* Web Application Development Best Practices
* MDN Web Docs: Mobile Web vs. Native Apps
---
A web page has a section that contains an `
Which type of layout positioning should the `
> ''Relative positioning allows an element to be positioned relative to its normal (static) position. For example, `left: 10px` shifts the element 10 pixels to the right of its original location.''
>
> ''Unlike `absolute` or `fixed`, relative positioning does not remove the element from the document flow.''
* MDN Web Docs: position: relative
* CSS Positioning Module Level 3
---
Andrew Robinson
27 days agoCarol Mitchell
1 month agoDaniel Roberts
2 months agoDorothy Thompson
2 months agoSteven Lee
3 months agoJennifer Bailey
4 months agoAshley Stewart
4 months agoMatthew Wilson
5 months agoMaria Flores
5 months agoDavid Cook
5 months agoMonica Walker
6 months agoRyan Martin
6 months agoMelissa Collins
6 months agoDaniel Hall
6 months agoDonna Scott
5 months agoDeborah Nguyen
5 months agoJina
7 months agoSerina
7 months agoKenneth
7 months agoVeronika
7 months agoKimberlie
7 months agoMoira
8 months agoFelicia
8 months agoKaitlyn
8 months agoKristeen
9 months agoChantay
9 months agoDetra
9 months agoJuan
9 months agoDoretha
10 months agoRochell
10 months agoChristiane
10 months agoGlory
10 months agoLennie
11 months agoAlana
11 months agoJerry
11 months agoTalia
11 months ago