Install Google APIs Client Library for PHP
for more info check https://github.com/googleapis/google-api-php-client
1 |
composer require google/apiclient:"^2.0" |
Authentication
Install Google APIs Client Library for PHP
for more info check https://github.com/googleapis/google-api-php-client
1 |
composer require google/apiclient:"^2.0" |
Authentication
C:\wamp64\bin\php\php7.1.9
folderphp.ini
and find this line:;curl.cainfo
Change it to:
curl.cainfo = "C:\wamp64\bin\php\php7.1.9\cacert.pem"
Make sure you remove the semicolon at the beginning of the line.
Save changes to php.ini
, restart WampServer, and you’re good to go!
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
Alias /phpmyadmin "c:/wamp64/apps/phpmyadmin4.7.9/" <Directory "c:/wamp64/a... |
Add These Two line
1 2 |
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0); |
in Laravel open vendor\guzzlehttp\guzzle\src\Handler\CurlFactory.php
and change this
1 2 |
$conf[CURLOPT_SSL_VERIFYHOST] = 2; $conf[CURLOPT_SSL_VERIFYPEER] = true; |
to
1 2 |
$conf[CURLOPT_SSL_VERIFYHOST] = 0; $conf[CURLOPT_... |
if you have a script called index.php that took a parameter called slug…
1 2 3 4 5 6 7 8 9 10 11 |
<?php if (isset($_GET['slug'])) { $sql = "SELECT * FROM `your_table` WHERE slug = ? LIMIT 1"; $smt = $pdo->prepare($sql); $smt->execute(array($_GET['slug'])); $row = $smt->fetchObject(); // do something with the matching record here... } else { // display home page } |
You could then re-write requests using ...
Create a link in /var/www
like this:
sudo ln -s /usr/share/phpmyadmin /var/www/
Note: since 14.04 you may want to use /var/www/html/
instead of /var/www/
If that’s not working for you, you need to include PHPMyAdmin inside apache configuration.
The php.ini
file can be edited to change the settings and configuration of how PHP functions. This section gives a few common examples.
Sometimes a PHP application might need to allow for larger upload files such as uploading themes and plugins on a WordPress site. To allow larger uploads for your PHP application, edit the php.ini
file with the following command (Change the path and file to match your Loaded Configuration File. This example shows the path for Apache on Ubuntu 14.04.):
1 |
1 |
The default lines that control the file size upload are:
The session support can be turned on automatically at the site level, or manually in each PHP page script: Turning on session support automatically at the site level we have to modify some setting in php.ini file. you can get php.ini file in folder you install PHP. To your sessions you have to set or reset following parameter in your php.ini file
Define path to save sessions
session.save_path = “C:\php\sessiondata\”
Directory related to server session should be under 777 chmod > fully writable
Whether to use cookies.
session.use_cookies = 1
Name of the session (used as cookie name).
session.name = PHPSESSID
Define Lifetime in seconds of cookie or, if 0, until browser is restarted.
session.cookie_lifetime = 0
;The path for which the cookie is valid.
session.cookie_path = /
The domain for w...