Basic questions

Laravel database table naming convention :

Laravel’s naming convention for pivot tables is singularized table names in alphabetical order separated by an underscore. So, if one table is features, and the other table is products, the pivot table will be feature_product.

You are free to use any table name you want (such as product_feature), but you will then need to specify the name of the pivot table in the relationship. This is done using the second parameter to the belongsToMany() function.

 

What is cUrl?

client url, curl is a tool to transfer data from or to a server, using one of the supported protocols (DICT, FILE, FTP, FTPS, GOPHER, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET and TFTP).

curl uses libcurl

 

What is SOAP?

Simple Object Access Protocol | platform independent |based on XML

SOAP allows you to build interoperable software and allows others to take advantage of your software over a network. It defines rules for sending and receiving Remote Procedure Calls (RPC) such as the structure of the request and responses.

someone can formulate and parse a SOAP message in their chosen language

SOAP provides a way to communicate between applications running on different operating systems, with different technologies and programming languages.

SOAP use in web service

 

File Handling

$myfile = fopen(“webdictionary.txt”, “r”) or die(“Unable to open file!”);
echo fread($myfile,filesize(“webdictionary.txt”));
fclose($myfile);

r : Open a file for read only.
w : Open a file for write only.
a : Open a file for write only.
a : new file if the file doesn’t
x : Creates a new file for write only
r+ : Open a file for read/write
w+ : Open a file for read/write
a+ : Open a file for read/write
x+ : Creates a new file for read/wright

What is Cookie?

A cookie is a small file with the maximum size of 4KB that the web server stores on the client computer. cookies are part of the HTTP request and response headers

<?php

setcookie(cookie_name, cookie_value, [expiry_time], [cookie_path], [domain], [secure], [httponly]);

?>

expiry_time : time() + 3600 for 1 hour

session_destroy() = entire session

uset($_SESSION[‘name]) = fix session variable deleted.

 

What is mySQL engine

Storage engines are MySQL components that handle the SQL operations for different table types. MySQL uses a pluggable storage engine architecture that enables storage engines to be loaded into and unloaded from a running MySQL server.

InnoDB is a storage engine for the database management system MySQL. MySQL 5.5 and later use it by default

Percona XtraDB is a storage engine for the MariaDB and Percona Server databases, and is intended as a drop-in replacement to InnoDB, which is one of the default engines available on the MySQL database

 

Type off array in php?

In PHP, there are three types of arrays: Indexed arrays – Arrays with numeric index. Associative arrays – Arrays with named keys. Multidimensional arrays – Arrays containing one or more arrays.

 

Advertisements

One thought on “Basic questions

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s