• 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

Loading data from MySQL and populating dropdown select with jQuery Mobile, PHP

How to get page number on dompdf PDF when using "view"

Combine array with same value and add other [duplicate]

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'posts.post' doesn't exist

str_word_count() function doesn't display Arabic language properly

php retrieve specific data onclick from database in a list format

PHP each() function replacement

How to get an Array value inside an object in an array Php [duplicate]

how to insert data into select2 search input after scan using qrcode

Laravel multi auth - Authentication user provider [] is not defined

Nginx RTMP not recording

Converting IPv6 to IPv4 address in PHP

How to display MySQL table using php and edit it in a web browser

PHP array, move keys and values to new array, but mix it up

renameColumn migration fails for existing column with columns does not exist error

About Contact Privacy policy Terms and conditions