0
0
Nginxdevops~10 mins

Index directive in Nginx - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to set the default index file to index.html.

Nginx
index [1];
Drag options to blanks, or click blank then click option'
Adefault.html
Bindex.html
Chome.html
Dmain.html
Attempts:
3 left
💡 Hint
Common Mistakes
Using a file name that is not commonly used as an index file.
Forgetting the semicolon at the end.
2fill in blank
medium

Complete the code to set multiple index files: index.php and index.html.

Nginx
index [1] [2];
Drag options to blanks, or click blank then click option'
Aindex.php
Bindex.html
Cdefault.php
Dhome.html
Attempts:
3 left
💡 Hint
Common Mistakes
Using incorrect file names.
Not separating file names with spaces.
3fill in blank
hard

Fix the error in the code to correctly set the index file to home.html.

Nginx
index [1];
Drag options to blanks, or click blank then click option'
Ahome.htm
Bhome.html
Chome.htm;
Dhome.html;
Attempts:
3 left
💡 Hint
Common Mistakes
Omitting the semicolon at the end.
Using wrong file extension.
4fill in blank
hard

Fill both blanks to set the index files to default.html and index.htm.

Nginx
index [1] [2];
Drag options to blanks, or click blank then click option'
Adefault.html
Bindex.html
Cindex.htm
Dhome.html
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up file names or extensions.
Forgetting the semicolon at the end.
5fill in blank
hard

Fill all three blanks to set the index files to main.php, index.html, and default.htm.

Nginx
index [1] [2] [3];
Drag options to blanks, or click blank then click option'
Amain.php
Bindex.html
Cdefault.htm
Dhome.html
Attempts:
3 left
💡 Hint
Common Mistakes
Incorrect file order.
Using wrong file extensions.
Missing semicolon.