Assume we have an array named $students

Assignment Help C/C++ Programming
Reference no: EM13165982

Write the PHP code needed to accomplish the requested task (you will need to utilize at least one of the PHP string functions in every question):

  1. Assume we have just read a string value from a web page form and stored that value into the string variable $username. Write the PHP code needed to check if the username that was entered is equal to "ADMIN" (upper or lower case, or combination of the two). If the admin username was entered display the string "Admin access is not allowed from your IP Address". For any other username display the string "Enter your password".

2.Assume we have an array named $passwords that contains passwords (strings) for our system. Passwords that are shorter than 6 characters are to be revoked. Write the PHP code that scans the $passwords array and displays all passwords that are less than 6 characters long.

3.Assume we have just read a string value from a web page form and stored that value into the string variable named $friends. The string stores a list of friends, each separated by a comma. We want to convert the string to an array named $friendArray - that is we want each name to be placed in one entry of the array. Write the PHP code that places the $friends names into the array $friendArray. Then write the code needed to scan the array for the name "Santa Claus" or "Easter Bunny". If any of these names appear display the message "Very Funny - Do you also know Mickey Mouse?"

4.Assume we have an array named $students. Each entry in the array contains a student's full name (e.g. "Jane Smith"). Write the PHP code needed to display all students (in the array) whose first name starts with the letter "J".

5.As in Question 4 assume we have an array named $students. Each entry in the array contains a student's full name (e.g. "Jane Smith"). Write the PHP code needed to display all students (in the array) whose LAST name begins with the letter "S". Hint: Find the location of the space character within the full name. The first letter of the last name is located in the next position.

Reference no: EM13165982

Questions Cloud

What is the concentration of the reactant b : A certain second-order reaction (B--> products) has a rate constant of 1.40×10^-3 M^-1*s^-1 at 27 Celsius and an initial half-life of 280s . What is the concentration of the reactant B after one half-life?
State model triglyceride with naoh and h2o : draw the organic product you would expect to obtain from reaction of the following model triglyceride
Write a program for a college''s admissions office : Write a program for a college's admissions office. Create variables that store a numeric high school grade point average andan admission test score.Print the message "Accept" if the studenthas any of the following:
Change the color of the text in the redlabel to red : Write that visual basic instruction to change the color of the text in the redlabel to red.
Assume we have an array named $students : Assume we have an array named $students. Each entry in the array contains a student's full name (e.g. "Jane Smith"). Write the PHP code needed to display all students (in the array) whose first name starts with the letter "J".
Send a printout of interface to the printer : write a visual basic instruction to specify that of printform1 control should send a printout of interface to the printer.
State significant difference between bacteria and eukaryotes : There are significant differences between Bacteria and Eukaryotes in the manner in which genetic information becomes functional gene product
What is the predicted freezing point of solution : A skyscraper in Pittsburg, built in the early 1970's, is supported by water filled columns. Potassium carbonate was added to the water to precent freezing during cold weather. If the solution is 40.0% K2CO3 by mass, what is the predicted freezing ..
Culture and society has influenced eating disorders : Discuscribe the way culture and society has influenced eating disorders. Discuss why eating disorders are more prevalent in western civilization than in other cultures. Use specific examples to support your answer.

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create program that uses functions and reference parameters

Create program that uses functions and reference parameters, and asks user for the outside temperature.

  Write a program using vectors and iterators

Write a program using vectors and iterators that allows a user to maintain a personal list of DVD titles

  Write the code required to analyse and display the data

Calculate and store the average for each row and column. Determine and store the values for the Average Map.

  Write a webservices application

Write a webservices application that does a simple four function calculator

  Iimplement a client-server of the game

Iimplement a client-server version of the rock-paper-scissors-lizard-Spock game.

  Model-view-controller

Explain Model-View-Controller paradigm

  Design a nested program

How many levels of nesting are there in this design?

  Convert celsius temperatures to fahrenheit temperatures

Write a C++ program that converts Celsius Temperatures to Fahrenheit Temperatures.

  Evaluate and output the value in the given base

Write C program that will input two values from the user that are a Value and a Base with which you will evaluate and output the Value in the given Base.

  Design a base class shape with virtual functions

Design a base class shape with virtual functions

  Implementation of classes

Implementation of classes Chart and BarChart. Class barChart chould display a simple textual representation of the data

  Technical paper: memory management

Technical Paper: Memory Management, The intent of this paper is to provide you with an in depth knowledge of how memory is used in executing, your programs and its critical support for applications.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd