Sunteți pe pagina 1din 4

JavaScript

1. Can you name two programming paradigms important for JavaScript app
developers?
2. What is the difference between classical inheritance and prototypal
inheritance?
3. How do you check if an object is an array or not?
4. What is a closure?
5. How does this work?

PHP
1. Explain how to submit form without a submit button
2. Write the statements that are used to connect PHP with MySQL
3. How can we get the IP address of the client?
4. What is the difference between GET and POST?
5. How we can get the number of elements in an array?

SQL
1. What is Data Mining?
2. What is an ERD?
3. What is the difference between Primary Key and Unique Key?
4. How to store picture file in the database. What Object type is used?

Laravel
1. List out some benefits of Laravel over other Php frameworks?
2. What is composer?
3. How to install Laravel via composer?
4. What is php artisan. List out some artisan commands?
5. How can you change your default database type?
JavaScript

1.Javascript is a multiparadigm procedural programing language that support Object-Oriented


Programming along with prototypal inheritance.

2. Class Inheritance: instances inherit from classes, and create sub-class relationships: hierarchical
.Instances are typically instantiated via constructor functions with the `new` keyword.

Prototypal Inheritance: instances inherit directly from other objects. Instances are typically
instantiated via factory functions or `Object.create()`. Instances may be composed from many
different objects, allowing for easy selective inheritance.

3.Use variable.constructor === Array or Array.isArray(variable)

PHP
1. To submit a form without a submit button the use of javascript is necesarry using submit()
function and a certain trigger event.

2. $servername = "localhost";
$username = "username";
$password = "password";
$conn = new mysqli($servername, $username, $password);

3. $_SERVER['REMOTE_ADDR'] or $_SERVER['REMOTE_HOST']

4. The GET method sends the encoded user information appended to the page request. The page
and the encoded information are separated by the ? character.

The POST method transfers information via HTTP headers. The information is encoded as
described in case of GET method and put into a header called QUERY_STRING.

5.Using count() function.


SQL
1.Data mining is the process of discovering actionable information from large sets of data. Data
mining uses mathematical analysis to derive patterns and trends that exist in data. Typically, these
patterns cannot be discovered by traditional data exploration because the relationships are too
complex or because there is too much data. These patterns and trends can be collected and defined
as a data mining model.

2.

An entity relationship diagram (ERD) shows the relationships of entity sets stored in a database. An
entity in this context is a component of data. In other words, ER diagrams illustrate the logical
structure of databases

3.

Primary Key:

 There can only be one primary key in a table


 Cannot be null
 Primary Key is a unique key identifier of the record

Unique Key:

 Can be more than one unique key in one table


 Unique key can have NULL values
 It can be a candidate key
 Unique key can be NULL and may not be unique

4.The best way to store a image in a database is to store the path to the file on the machine where
the image is located.To store the path the dataype varchar is offten most used.It is also possible to
store small files as binary large objects but is not recommended unless the file is small.

Laravel
Laravel is a free, open-source PHP web framework, intended for the development of web
applications following the model–view–controller (MVC) architectural pattern.

Some advantages of using laravel include :

 Modular packaging with composer based dependency manager.


 Class autoloader.
 Eloquent ORM, the advanced active-record-pattern implementation
 Query builder as an alternative to Eloquent ORM, for direct access to the database.
 Support of database platforms including MySQL, PostgreSQL, and SQLServer.
 More secure to other framework and easy to implement
2. Composer is a dependency manager for PHP. Composer will manage the dependencies you
require on a project by project basis. This means that Composer will pull in all the required
libraries, dependencies and manage them all in one place.

This kind of management for dependencies in a project is not a new concept, and in fact, much of
Composer is actually inspired from npm from Node.js and Bundler from Ruby.
3. composer create-project laravel/laravel {directory} 4.2 --prefer-dist

4. Artisan is the command-line interface included with Laravel. It provides a number of helpful
commands that can assist while building an application. Some useful command include :

php artisan make:auth to generate an authentification scaffolding

php artisan make:controller to create a controller

php artisan migrate to create the tables based on the migration tables in laravel

php artisan db:seed to populate the database

It is also possible to create your own commands

5.To change the database type used in laravel you have to edit the config/database.php.The default
database type used in laravel is mysql so to change it you have to change the line ‘default’ =>
‘mysql’ to the prefered database type.

S-ar putea să vă placă și