Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -320,8 +320,8 @@ This gets all the details for a game. This is most of the information from the
Name | Type | Description | Required | Default
-----|------|-------------|----------|---------
appIds| int[] | The ids of the games you want details for | Yes |
cc | string | The cc is the country code, you can get appropriate currency values according to [ISO 3166-1](https://wikipedia.org/wiki/ISO_3166-1) | No |
l | string | The l is the language parameter, you can get the appropriate language according to [ISO 639-1](https://wikipedia.org/wiki/ISO_639-1) (If there is one) | No |
cc | string | The cc is the country code, you can get appropriate currency values according to [ISO 3166-1](https://wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements) | No |
l | string | The l is the language parameter, you can get the appropriate language according to [ISO 639-1](https://wikipedia.org/wiki/List_of_ISO_639-1_codes) | No |


> Example Output: [appDetails](./examples/app/appDetails.txt)
Expand Down Expand Up @@ -387,4 +387,4 @@ group| string or int | The ID or the name of the group. | Yes
- [MaartenStaa](https://github.com/MaartenStaa)
- [JRizzle88](https://github.com/JRizzle88)
- [jastend](https://github.com/jastend)
- [2er7](https://github.com/2er7)
- [Teakowa](https://github.com/Teakowa)
9 changes: 8 additions & 1 deletion src/Syntax/SteamApi/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,15 @@ protected function setUpClient(array $arguments = [])
// Build the query string
$parameters = http_build_query($parameters);

$headers = [];
if (array_key_exists('l', $arguments)) {
$headers = [
'Accept-Language' => $arguments['l'],
];
}

// Send the request and get the results
$request = new Request('GET', $steamUrl . '?' . $parameters);
$request = new Request('GET', $steamUrl . '?' . $parameters, $headers);
$response = $this->sendRequest($request);

// Pass the results back
Expand Down