-
Notifications
You must be signed in to change notification settings - Fork 35
Logging
Josh edited this page Jul 26, 2018
·
1 revision
Evil Portal has logging on a portal by portal basis as of version 3.1. Logs are written to
/{root or sd}/portals/{portal_name}/.logs
. These logs can be viewed, cleared, or downloaded easily from the Evil Portal module in the web ui.
- Open the Evil Portal module on your pineapple.
- On the work bench, select "View" under the "Logs" column for the portal you want to view logs for.
- You can also view logs if you click into the portal and click "View Log" in the upper right hand corner
- The log viewer modal should open up.
- Here you can clear the log (top right), download the log (bottom left), refresh the log (top left) and view the file size on disk (bottom right).
These instructions are the same for Basic and Targeted Portals.
- Open the Evil Portal module on your pineapple.
- Select the portal to want to write logs for
- Edit MyPortal.php
- In the onSuccess, onError, or handleAuthorization method add this line:
$this->writeLog("Hello World");
You can replace "Hello World" with whatever string you want to log. Now once that method is called you will see a new message in your log file!