BeDrive

# Documentation

## Creating a new database

First thing you want to do before installing BeDrive is to create a new database on your mysql server. If you already know how to do this/or have already created one just skip to the next step.

Your host will most likely be running phpMyAdmin as mysql manager, if that's the case here's a step by step guide (if not the proccess will be very similar on other managers).

Login to your control panel, find and click phpMyAdmin link: Click on the database tab in the top menu, enter any name you like and click create.

## Uploading Files

After creating a database, unzpip the .zip file you donwloaded from CodeCanyon and upload the contents of BeDrive folder to your servers root folder (usually called www or html or something similar) or a sub-directory, shared hosting providers usually have a web based file manager, but you should use something like Filezilla to do the upload as the web based managers can cause various problems fairly often.

## Installing BeDrive

After you uploaded BeDrive files, simply open up your site url and follow on-screen instructions to finish the installation.

## Updating BeDrive to new versions

- 1. Extract the .zip file you downloaded from CodeCanyon.
- 3. Upload and overwrite all the files same way you did when you installed BeDrive.
- 5. Visit yoursite.com/update url to complete the update proccess.

## Social Login

In order make social login (logging in via google, twitter and facebook) work you will need to register for a corresponding app and get that services Client ID and Client Secret. Check out the section for each service for a detailed instruction for how to register and get those tokens. Once you've got your client id and secret simply enter them in corresponding field in admin area -> third party services and keys.

## Facebook

You can resgister for a facebook app Here by clicking on My Apps > add a new app at the top. Once you create the app you can find your id and secret in your app dashboard, you will also need to enter your site url in Settings > site url field and make your app public from Staus & Review tab.

## Twitter

You can register for a twitter app Here, after you register you will need to enter your site url in Website and Callback Url fields in your app settings, you can find your key and secret in the Keys & Access Tokens tab.

## Google

You can register for a google app Here by clicking on Create new project, after creating new project go to credentials tab and in the authorized redirect uri field enter http://yoursiteurl.com/auth/social/google/login, you might also need to enable Google plus and contacts APIs.

## Mail

In order to make mail work (for password reset and other functions), you will need to register for a mandrill API key. Mandrill is used to avoid the many problems that occur when using public smtp servers (like gmail or your hostings private one). Here's how to get your API key.

### Register for mandrill api key

To register for mandrill key go to this url, create a new account and then log in. Then click get api keys -> +add api key

Then simply copy mandrill api key and enter it into corresponding field ind admin area -> third party services and keys

## Payments

In order to make payments system work, you will need to register with stripe. Stripe will handle all credit card information and payments so you don't need to worry about security.

### Register for stripe

To register for stripe go to this url, create a new account and then log in. Then at the top right click Your Account -> Account Settings -> API Keys

You will need to enter these keys into corresponding fields in admin area -> third party services and keys on your site.

You can use test keys to test that everything is working properly (you can get test credit card details here). Once you are ready to go to live mode, use live keys and switch your stripe to live mode from stripe dashboard

## Plans

To make payments work you will need to create the plans you want to offer your users from stripe dashboard. To do this go to stripe dashboard, click plans on the left and then +new at the top.

The create plan panel should be self explanatory, there are just a few things to note, leave trial period days empty. And in the ID field enter how much space you want to offer your users with this plan. For example 100GB or 50MB or 1TB, BeDrive will use this value as a reference through your site so make sure it is spelled correctly.

Once you have created plans you want BeDrive will automatically generate payments panel with them for you so you don't need to do anything else.

For information on how to withdraw payments to your bank account visit this url.

## Analytics

### Registering for google analytics account

Analytics page is powered by google analytics so you will need to register for google analytics and add their supplied code to your site. Here's how to do it.

- 1. Go to this url You will be prompted to login to your google account or create a new one if you don't have it already. Do it.
- 2. Click on Admin -> Property -> Create new Property -> fill out required fields -> click on get tracking ID
- 3. Go to Admin area -> settings -> third party service keys and paste the code into google analytics tracking code field.

### Viewing analytics information

Once you have created analytics account and entered it in settings page, go to admin area -> analytics, click on Access google analytics button, then click accept

And you are done. You can now easily view analytics information right from the admin area. You can also select different analytics account, property and view from the bottom of the page.

## Users

From users page, you can get an overview of your site users, create a new one, delete existing ones and edit their profile information.

## Files

From files page, you can get an overview of files uploaded by all your users and delete them.

## Folders

From folders page, you can get an overview of folders uploaded by all your users and delete them.

## Settings

On the settings page you can change various options on your site from your homepage view to user registration. There's a description under each options so you shouldn't have any troubles figuring out which setting does what.

## Translating BeDrive

It's really easy to translate BeDrive. Simply open up application/resources/lang/en/app.yml file with a text editor and enter your translations on the right.

## Uploading Files and Folders

From dashboard, files and folders can be uploaded by draging and droping them anywhere on the page (upload icon will start pulsing once you hower some files over the page) or clicking on orange upload button at the top. While items are bying uploaded you will see a progress panel at the bottom. Once they are upload you can edit, manage and organize them right away.

## Folders

When user creates an account root folder is automatically created for them. This is where all files and sub-folders by default will be stored. New folders and sub-folders can be created by clicking orange folder button and the top. Once folder is created it can be selected from the left panel or from breadcrumbs and new files will be uploaded to that folder instead of root.

## Trash

Deleted Files and Folders will be moved to trash first. Files and Folders currently in trash can bee seen by clicking on trash in the left panel. These items can easily be restored by right clicking on them and then clicking restore. Items deleted from trash will be removed permanently from database and filesystem and are impossible to restore.

## Recent

Files and Folders uploaded recently can be found in Recent panel. 50 most recently uploaded or modified items will be displayed here.

## Favorites

Favorites page will display folders and files user has marked as favorite. Items can be marked as favorite by right clicking on them (or clicking more options button) and then clicking favorite.

## Search

You can search for files and folders from search bar at the top navbar. Clicking on auto-complete suggestions will show that items preview preview page while clicking on search button will show all results in the search page where full management options are available for matches.

## Activity Panel

Activity panel will show all the recent activity relevant to currently open folder (when files inside it were created, modified, deleted and more).

## Accessing available actions

Various actions can be performed on uploaded files and created folders. To access these action you can right click on an item or click on more options button

Here is an explanation of all available actions:

- Preview - preview selected item (images, audio, video, zip, pdf and text files can currently be preview in the browser).
- Share - Open sharing panel to get a link to item preview page, add a password to item or share it via social services.
- Copy Link - Copy link for currently selected item into clipboard.
- Move to - Move selected files or folder. You can also do this by simply dragging an item to a desired folder (or trash).
- Favorite - Add selected photo to favorited for easy access later.
- Rename - Rename selected item. This will only change items display name so all the old links will still work.
- Make a Copy - Copy currently selected file or folder.
- Download - Download a file or a .zip containing all files in a folder.
- Remove - Move selected item to trash or delete permanently if it's already in trash.
- Restore - Restore selected item from trash into it's original folder

## Changing Home Page

You can easily change what is shown as your homepage from admin area -> settings. You can choose between Landing Page, Login Page or Custom Page. If you choose custom page you will need to enter a path (on your server) or a url (on the internet) to your custom .html file.

## Upload from homepage

If you have homepage uploading enabled in admin area -> settings, users will be able to drag and drop their files directly on the homepage to host and share them without logging in or registering. If user logs in after uploading a files this way, those files will be attached to his account automatically and they will be able to manage and edit them.

## Support

If you have any problems or questions, please use the contact form on BeDrive codecanyon page support tab to send us a message instead of doing it in the comments, so we can resolive it as fast as possible, thanks!