Laravel redirect() issue

Issue:

If ELB pass 443 port to 80 port of the web server inside, and disable 80 port on ELB, redirect() will cause problem. Because redirect() always redirect pages to http and it will not display.

Following traditional way to redirect pages will cause session problem in laravel:

Solution:

Pass full URL to redirect() function instead of URI only.

How to set BASE_URL: (in app\Providers\AppServiceProvider.php)

Suggestion:

Not to close 80 port on ELB.

Reference:

New domain for Apache

https://www.digitalocean.com/community/tutorials/how-to-set-up-apache-virtual-hosts-on-ubuntu-14-04-lts

Change permission:

Restart apache:

 

cURL with basic authorization

 

Detect Mobile OS

 

Fix Mouse Lag (Latency) in Windows 10

Disable “Enable resampling scroll events” in Chrome config:

chrome://flags/

Chrome Cursor Latency Fix

Disable “Use hardware to accelerate…” in advanced setting page

FMAPP.exe Issue:

C:\Program Files\Realtek\Audio\HDA\FMAPP.exe
Rename it to FMAPP_bak.exe

  1. http://kenlai.blogspot.com/2015/08/win10-mouse-lag.html
  2. https://www.tenforums.com/drivers-hardware/14107-windows-10-mouse-lagging-2.html#post336879

調低滑鼠回報速率:

https://forum.gamer.com.tw/C.php?bsn=60030&snA=506100

Update audio driver for your motherboard.

To me is Gigabyte / Realtek:
https://www.gigabyte.com/tw/Motherboard/G1Sniper-Z6-rev-10#support-dl-driver-audio

Disable Flash in Chrome settings:

https://stackoverflow.com/questions/42765418/how-to-disable-flash-in-chrome

Update Intel HD Graphic Driver

https://answers.microsoft.com/zh-hant/windows/forum/windows8_1-performance/%E5%95%8F%E9%A1%8C%E5%B7%B2%E8%A7%A3%E6%B1%BA/d6ebd54f-7f20-4d9a-b7d2-70a91ff0f416

Change to wired mouse (Final Solution)

https://answers.microsoft.com/en-us/windows/forum/all/my-mouse-lags-all-the-time-windows-10-wireless/53f14673-7d1d-4f9e-9c44-4e7748903acd

Other Reference:

Laravel Filemanager

Official:

https://unisharp.github.io/laravel-filemanager/installation

Notes for installation:

  1. Under 5.5 need to add service providers and then execute vender:publish commands.
  2. <script src=”/vendor/laravel-filemanager/js/lfm.js”></script>
    Javascript name in DOC is wrong.
  3. Remove “auth” middleware from /config/lfm.php if don’t need auth.
  4. If don’t use auth, override function in /vendor/…/Handlers/ConfigHandler to return static number. e.g. 1
  5. Make sure extension “mbstring” and “exif” is enabled in php.ini

To debug uploading process:

\vendor\unisharp\laravel-filemanager\src\controllers\UploadController.php

HTML Example:

Helper to get thumb:

Note:

  1. Main view of File Manager is “\vendor\unisharp\laravel-filemanager\src\views\index.blade.php” and it uses some helpers of laravel like url(), asset(). If you use https only, these helpers will cause error. Try to overwrite Laravel helpers will solve these problems.
    Path to laravel helper:
    \vendor\laravel\framework\src\Illuminate\Foundation\helpers.php

     

php artisan vendor:publish

This command will copy config file or assets files from /vendor to /public/vendor

e.g. Laravel Filemanager

https://unisharp.github.io/laravel-filemanager/installation

After add service providers in config/app.php, following commands will copy config and assets: