Skip to content
This repository was archived by the owner on Feb 14, 2021. It is now read-only.

Commit 2e23ca7

Browse files
committed
Updated to newest ts3admin.class-Version
1 parent dfe22e8 commit 2e23ca7

File tree

3 files changed

+32
-8
lines changed

3 files changed

+32
-8
lines changed

README.md

+30-6
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,49 @@
11
# laravel-ts3admin
22
[par0noid's ts3admin.class](https://github.com/par0noid/ts3admin.class) integration for Laravel 5.3
33

4+
> **INFO:** This package uses a singleton to access a **single** ts3admin.class-object. So you currently **can't access multiple TeamSpeak-3-Servers**!
5+
46
### Installation
5-
1. `composer require micky5991/laravel-ts3admin`
6-
2. Add Service Provider to your `app.php` configuration-file:
7+
- Add ts3admin.class repository to composer.json
8+
9+
> This is only a temporary step and will be removed in the next version
10+
11+
```bash
12+
$ composer config repositories.ts3admin git https://github.com/par0noid/ts3admin.class
13+
```
14+
__or__
15+
```
16+
"repositories": [
17+
{
18+
"type": "git",
19+
"url": "https://github.com/par0noid/ts3admin.class"
20+
}
21+
],
22+
```
23+
24+
- `composer require micky5991/laravel-ts3admin`
25+
- Add Service Provider to your `app.php` configuration-file:
726
```php
827
Micky5991\laravel_ts3admin\Providers\TeamspeakServiceProvider::class
928
```
10-
3. Copy configuration to config-folder: `php artisan vendor:publish`
29+
- Copy configuration to config-folder:
30+
```bash
31+
$ php artisan vendor:publish
32+
```
1133

12-
4. Add environmental variables to your `.env`
34+
- Add environmental variables to your `.env`
1335
```
1436
TS_SERVER_HOST=127.0.0.1
1537
TS_SERVER_PORT=9987
16-
TS_SERVER_TIMEOUT=1
38+
TS_SERVER_TIMEOUT=2
1739
TS_QUERY_PORT=10011
1840
TS_QUERY_USERNAME=serveradmin
1941
TS_QUERY_PASSWORD=secretpassword
2042
```
43+
### Configuration
44+
After completing all steps from above you should have a configuration file under: `config/teamspeak.php`. There you can configure some other aspects like the name of the ServerQuery.
2145

22-
##### Example
46+
### Example
2347
An example for a controller to the `/clients` endpoint that lists all connected clients.
2448
```php
2549
Route::get('/clients', function(\par0noid\ts3admin\ts3admin $ts) {

src/Exceptions/TeamspeakException.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
namespace Micky5991\laravel_ts3admin\Exceptions;
33

44
use Exception;
5-
use par0noid\ts3admin\ts3admin;
5+
use \ts3admin;
66

77
class TeamspeakException extends Exception
88
{

src/Providers/TeamspeakServiceProvider.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
use Illuminate\Support\ServiceProvider;
66
use Micky5991\laravel_ts3admin\Exceptions\TeamspeakException;
7-
use par0noid\ts3admin\ts3admin;
7+
use \ts3admin;
88

99
class TeamspeakServiceProvider extends ServiceProvider
1010
{

0 commit comments

Comments
 (0)