• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

backup files to google drive using PHP

phpmysqlgoogle-drive-api


PHP Snippet 1:

// User home directory (absolute)
$homedir = trim(shell_exec("cd ~ && pwd"))."/"; // If this doesn't work, you can provide the full path yourself
// Site directory (relative)
$sitedir = "www/";

PHP Snippet 2:

// User home directory (absolute)
$homedir = "/home/mhmd2991/"; // <-- FIXED HERE
// Site directory (relative)
$sitedir = "public_html/";

Related Snippets

How to get result of the formula on import xlsx with maatwebsite using Laravel? I get formula and not value of the formula

How to get multiple values with same key from an array PHP

I can't delete my image when it is liked because of the foreign key in mysql

Send POST data via raw JSON with Postman

how to youtube api data to print in toolset metabox using a button click before save-post

Convert date and time to Jalali in Laravel

Smarty: undefined extension class 'Smarty_Internal_Method_Get_Template_Vars'

SQL AVG() to 2 decimals

How to convert time from one timezone to another in PHP

How to convert binary string to normal string in php

Could not decode a text frame as UTF-8.

Split comma separated value from table column into rows using mysql?

PHP Warning: Module already loaded in Unknown on line 0

Why does array_map() with null as callback create an "array of arrays"?

Laravel Model save() & update() Not Saving

About Contact Privacy policy Terms and conditions