Answered step by step
Verified Expert Solution
Question
1 Approved Answer
1 2 . 9 . 3 Hands on Practice Project 1 : Arrays DIFFICULTY LEVEL: Beginner Overview Demonstrate your ability to create a data -
Hands on Practice Project : Arrays DIFFICULTY LEVEL: Beginner Overview Demonstrate your ability to create a datadriven PHP page by creating PHP functions and include files so that Chprojphp looks similar to that shown in Figure The data needed for this page are in a file named data.inc.php Instructions Examine the provided HTML file chprojhtml that demonstrates what markup your PHP must eventually generate. Examine also the provided data file datainc.php that contains three arrays. You will be modifying chprojphp initially it is a copy of chprojhtml for this project. Move the header and left mavigation markup in chprojphp into two separate include files. Use the PHP include function to include each of these files back into the original file. Chapter Summai In the left navigation area, replace the static list of e elements containing the continent names, with a loop that displays the same elements but using the data in the scontiments array. ard solass, which will echo a properly fornsed hyperlink in the following form; In the left navigation area, replace the static list of elements containing ghe continent names, with a loop that displays the same elements but using the dara in the teountries array. Notice that this array is an associative array, so it will require a different type of loop. Use the generatetink function for the country link. Notice that this link contains a query string making use of the key value of the soountries array. Create a fanction called outputrostmow that takes as a single argument a post clement Lex a single element from the tpose twodimensional arfay This function will echo the necessary markup for a single post. Be sure to also use your geseratet.ink function for the three links image user name, read more in each post. Notice that these links contain query strings making use of the userld or postld. Create a function that takes one parameter. This parameter will contain a number between and including and Your function will output that number of gold star image elements; after that it will also output, however, many white star images so that five stars in total are displayed. Modify your output Post voou function so that it calls your starmaking function. Remove the existing post markup and replace with a loop that calls output Postrou Guldance and Testing Remember that you cannot simply open a local PHP page in the browser using its open command. Instead you must have the browser request the page from a server. If you are using a local server such as XAMPP, the file must exist within the htdoes folder of the server, and then the request will be localhost somepathchprojphp Break this problem into smaller steps. After each step, test the page in the bforwser. Verify that your page works correctly by altering the data in data.inc. php i have html file and running this we get output but i want this output using avobe instruction. and also i have data.inc in which i have array data. html code here:
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started