Documentation
GoStock – Free and Premium Stock Photos Script
Created: 02, February 2017 by Miguel Vasquez
GoStock - Free Stock Photos Script It is a platform to share stock photos free and premium of high quality, users will be able to upload their photos to share with the whole community and visitors, and may receive donations through PayPal. In addition users will be able to give you like, comment, share and add to collections your favorite photos.
Table of Contents
- Setting MySQL
- Uploading Files
- Installation
- Access to Admin Panel
- Social Login
- Set up Cloud Storage
- Customize
- Sources and Credits
- How to add a new language
Features:
- Built with Laravel 6
- Bootstrap
- Font Awesome
- IcoMoon
- Facebook Login
- Follow / Unfollow system
- Like in Photos
- Collections of Photos
- Categories
- Notifications Real-time
- Latest, Featured, Popular, Most Commented, Most Viewed, Most Downloads sections
- Photo search
- Download photos in different size
- Search for photos by colors and cameras
- Members can upload unlimited photos
- Updates photos
- Option Delete Account
- Members can change their name, email and password
- Upload Avatar
- Upload Cover
- Change password
- Donations through PayPal for members
- XSS: Protection from cross site scripting
- Secure Bcrypt password hashing
- SMTP Support
- Share social
- Easy translation
- Ajax pagination in Photos and Comments
- Comment system
- Like in comments
- Feed section (Posts by users you follow)
- Admin Features:
- Change the site name
- Change the site title welcome
- Manage General Settings and Limits
- Statistics
- Set keywords for the site. (SEO)
- Add a description (SEO)
- Create/Edit pages e.g.: Help, Privacy, etc.
- Manage Categories
- Manage Photos
- Manage Members.
- Manage Members, Photos Reported
- Set up social accounts
- Manage Google Adsense, Google Analytics
Requirements:
- PHP 7.2.0 or Greater
- MySQL 5.6
- OpenSSL PHP Extension
- PDO PHP Extension
- Mbstring PHP Extension
- Tokenizer PHP Extension
- XML PHP Extension
- Ctype PHP Extension
- JSON PHP Extension
- BCMath PHP Extension
- cURL
- GD Library or ImageMagick or Imagick.
- allow_url_fopen (PHP.INI) is ON
IMPORTANT:
Make sure your server has PHP 7.2.0 or higher and MySQL 5.6 as a minimum
Setting MySQL
- 1.) Create a database
- 2.) Create a user for database
- 3.) Import the Database
- Log into your phpMyAdmin and import the
gostock.sqlfile located in the folderMySQL
Uploading Files
- Upload the folder
"Script"to the"public_html"or"www"folder on your server.
Installation
- After you have uploaded all files can start to setup the files.
- Database Connection
- Open the file
.envlocated in your root folder, with any text editor, e.g: NOTEPAD (IMPORTANT: You can not find the file and you are using cPanel click show hidden files) - change the following parameters, for theirs:
APP_URL=http://localhost
IMPORTANT: Place the URL correctly otherwise the images will not be displayed.
DB_DATABASE=YOU_DATABASE
DB_USERNAME=YOU_USERNAME
DB_PASSWORD="YOU_PASSWORD"
IMPORTANT:
Place all data without spaces
mail.php located in the folder config, with any text editor, e.g: NOTEPAD'from' => [
'address' => env('MAIL_FROM_ADDRESS', 'no-reply@example.com'),
'name' => env('MAIL_FROM_NAME', 'Gostock'),
],
'Gostock' and 'no-reply@example.com'.env located in the root folder, with any text editor, e.g: NOTEPADMAIL_DRIVER=mail
MAIL_HOST=smtp.mailtrap.io
MAIL_PORT=2525
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
mail and smtp
IMPORTANT:
Place all data without spaces
http://yourwebsite.com/login and enter the following credentials.User: Admin
Pass: 123456
app.php located in the folder config, with any text editor, e.g: NOTEPAD'timezone' => 'America/Caracas',
.env located in the root folder, with any text editor, e.g: NOTEPADINVISIBLE_RECAPTCHA_SITEKEY=YOU_KEY
INVISIBLE_RECAPTCHA_SECRETKEY=YOU_SCRETKEY
IMPORTANT:
choose reCAPTCHA v2 and Invisible reCAPTCHA
Social Login
- Open the file
services.phplocated in the folderconfig, with any text editor, e.g: NOTEPAD
'facebook' => [
'client_id' => "APP_ID", // configure with your app id
'client_secret' => 'APP_SECRET', // your app secret
'redirect' => 'http://YOURSITE.COM/oauth/facebook/callback', // IMPORTANT NOT REMOVE /oauth/facebook/callback
],
'twitter' => [
'client_id' => "APP_ID", // configure with your app id
'client_secret' => 'APP_SECRET', // your app secret
'redirect' => 'http://YOURSITE.COM/oauth/twitter/callback', // IMPORTANT NOT REMOVE /oauth/twitter/callback
],
IMPORTANT:
You should ensure that this is ON Facebook/Twitter login at http://site.com/panel/admin/settings
Set up Cloud Storage
- Open the file
.envand Choose the disk of the file system you want to use, the available ones are:default,wasabi,s3,dospace
FILESYSTEM_DRIVER=default
- default: Disk local (Local storage).
- wasabi: Disk Wasabi, a cheaper alternative than Amazon.
- s3: Disk Amazon S3.
- dospace: Disk DigitalOcean.
.env fileAWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=
AWS_BUCKET=
WAS_ACCESS_KEY_ID=
WAS_SECRET_ACCESS_KEY=
WAS_DEFAULT_REGION=
WAS_BUCKET=
DOS_ACCESS_KEY_ID=
DOS_SECRET_ACCESS_KEY=
DOS_DEFAULT_REGION=
DOS_BUCKET=
Wasabi in trial mode does not allow public files, you must send an email to support@wasabi.com to enable public files, or avoid trial mode.
Important: If you want to migrate your site to any storage service (Amazon, DigtalOcean or Wasabi), you must upload the following folders located in the public folder of your current site:
- avatar
- cover
- uploads
Important: If your site is new you should upload only these folders located in the public:
- avatar
- cover
Customize
- Changing the logo, Favicon, Image Header, Image Bottom, Watermark and others
- Go to
https://yourwebsite.com/panel/admin/theme - Change the default link color
- Find this #F00 in
public / css / main.cssand you replace it with the one you want
How to add a new language
Make sure these folders have 755 or 777 permissions
Sources and Credits
- Laravel - http://laravel.com/
- jQuery - http://jquery.com/
- Bootstrap - http://getbootstrap.com/
- Font Awesome - http://fortawesome.github.io/Font-Awesome/
- IcoMoon - http://icomoon.io
- Flat UI - http://designmodo.github.io/Flat-UI/
- Placeholder Plugin jquery.placeholder.1.1.1.min.js // Mike Taylor, http://miketaylr.com
- Char Count count.js // Alen Grakalic
- jquery Form // malsup.com/jquery/form/
- jqueryTimeago.js // http://timeago.yarp.com/
- jquery.colorbox.js // Jack Moore - http://www.jacklmoore.com/colorbox
- Readmore - http://jedfoster.com/Readmore.js/
- Bootboxjs - http://bootboxjs.com/
- Images - unsplash - http://unsplash.com/ -- splitshire http://www.splitshire.com/
- Avatars - http://uifaces.com/
- Fonts - https://www.google.com/fonts
- http://www.tinymce.com/
- https://github.com/sliptree/bootstrap-tokenfield
- http://morrisjs.github.io/morris.js/
SITEMAPS: http://YOURSITE.COM/sitemaps.xml
Any problem or doubt send me an email to miguelvasquez991@gmail.com
Do not forget to visit miguelvasquez.net
Thank you for purchasing my script 😉