Question

Describe when and why you should use PHP (as a server-side programming language). Why a client-side...

  • Describe when and why you should use PHP (as a server-side programming language). Why a client-side programming language (like JavaScript), not enough?
  • Also, is it generally safe to keep credentials like the Database passwords in PHP source code? Why? Compare that to doing the same thing in JavaScript.
0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer:

PHP

JavaScript

  1. PHP is a server-side scripting language.
  1. JavaScript is a client-side scripting language.
  1. PHP embedded with HTML and provides custom web content, cookies, and a data facility.
  1. JavaScript is used to create dynamic and interactive HTML pages.
  1. PHP needs to be installed before use.
  1. JavaScript interpreter comes inbuilt in browsers.
  1. PHP is used to querying the database, operation over the database, write or access a file on the server.

4.    JavaScript sends requests to the server for data, acts as an interface between server and user.

  1. PHP is a structured web application.

      5.    JavaScript is single-threaded.

  1. PHP is synchronous, it waits for input/ output operations.

       6.   JavaScript is asynchronous, it doesn’t wait for I/O operations.

PHP language is more secure than JavaScript because PHP code is not visible in the web browser while JavaScript code is visible in the web browser. javaScript code is vulnerable and prone to security risks.

Security Analyzer tool such as Secure Security Layer (SSL) and Hypertext transfer protocol secure(HTTPs) is used to secure the javaScript code.

This scripting also allows the website owner to hide the source code that generates the interface. Server-side can query database requests for data.

SSL and HTTPs are costly, so JavaScript code is costly to secure. While PHP language provides security.

So database password credentials are safe to keep in PHP source code.

Add a comment
Know the answer?
Add Answer to:
Describe when and why you should use PHP (as a server-side programming language). Why a client-side...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Please, i need Unique answer, Use your own words (don't copy and paste). *Please, don't use...

    Please, i need Unique answer, Use your own words (don't copy and paste). *Please, don't use handwriting. Describe when and why you should use PHP (as a server-side programming language). Why a client-side programming language (like JavaScript), not enough? Also, is it generally safe to keep credentials like the Database passwords in PHP source code? Why? Compare that to doing the same thing in JavaScript.

  • Your company is developing an in-house application using server-side PHP and client-side JavaScript code, making extensive...

    Your company is developing an in-house application using server-side PHP and client-side JavaScript code, making extensive use of third-party libraries in both languages and Composer to manage the many dependencies between the various libraries and packages. Which type of attack should you be particularly concerned about? Select one: a. Side-channel or timing attacks on cryptographic keys b. Buffer overflow attacks c. Phishing attacks d. Supply chain attacks

  • PHP Programming Question. Use the techniques you learned so far to create an Address Book application...

    PHP Programming Question. Use the techniques you learned so far to create an Address Book application that stores names, e-mail addresses, and phone numbers in a text file. Validate all input fields and include functionality that allows the user to view the address book. Also, include code that sorts the address book by name and deletes duplicate entries. Each page in the application should have a link back to the main page. Be creative and add extra features if you...

  • Background: I have an Access-software (~30 simultaneous users) with split front- & back-end, both UI &...

    Background: I have an Access-software (~30 simultaneous users) with split front- & back-end, both UI & DB running on Access-files. Most important features for me are reports & printing, with emphasis on fast development and deployment to the users (updates 1-3 times per week, using as little time as possible). The environment is Win7 + Access 2010. Updates are handled with .BAT-batch file. The database might be upgraded into SQL Server Express or something later this year. Problems: The Access...

  • This is in C. For this assignment we will write a simple database server. We will...

    This is in C. For this assignment we will write a simple database server. We will be creating a simple database of student records, so let’s describe these first. The format of a student record is as follows: typedef struct student {     char lname[ 10 ], initial, fname[ 10 ];     unsigned long SID;     float GPA; } SREC; Part One – the Server We will create a database server. The job of the server is to accept a...

  • need this in #c . You will now add server side validation code to the frmPersonnel...

    need this in #c . You will now add server side validation code to the frmPersonnel page. Currently, when the Submit button is pressed, the frmPersonnelVerified page is displayed. This is because the frmPersonnelVerified page is set as the Submit button's PostBackUrl property. Instead of having the page go directly to the frmPersonnelVerified page when the Submit button is pressed, we want to do some server side validation. If any of the validation rules fail, we will redisplay the frmPersonnel...

  • Need help about C PROGRAMMING,, pls use only C LANGUAGE.., yea so im doing this exercise...

    Need help about C PROGRAMMING,, pls use only C LANGUAGE.., yea so im doing this exercise as a practice for c programming, could someone do this as well so i could compare if my code makes makes sense and to see and help correct the errors im getting right now.. Any helpful help would be appreciated.. Pointers &Pointer arithmetic Memory allocation and freeing Main topics: Exercise This lab is designed to give you practice working with pointers and memory allocation...

  • Using C programming language Question 1 a) through m) Exercise #1: Write a C program that...

    Using C programming language Question 1 a) through m) Exercise #1: Write a C program that contains the following steps (make sure all variables are int). Read carefully each step as they are not only programming steps but also learning topics that explain how functions in C really work. a. Ask the user for a number between 10 and 99. Write an input validation loop to make sure it is within the prescribed range and ask again if not. b....

  • Read this article. Then write a 250 word response on two of the programs you like...

    Read this article. Then write a 250 word response on two of the programs you like the most. Open source business intelligence software 1. BIRT BIRT is an open source BI program that CloudTweaks says is often viewed as the industry standard. BIRT boasts “over 12 million downloads and over 2.5 million developers across 157 countries.” Its users include heavyweights such as Cisco, S1, and IBM (which is also a BIRT sponsor). They also have maturity going for them, as...

  • Form Processing HTML One of the most ubiquitous uses of JavaScript is validating form data on...

    Form Processing HTML One of the most ubiquitous uses of JavaScript is validating form data on the client side before it is submitted to the server. It is done everywhere because it is fast and it gives you a great deal of flexibility in how you handle errors insofar as the GUI is concerned. Attached is an image of some code I wrote (so Blackboard can't mess it up). Some things to notice that will help you with the lab....

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT