Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
S
solarium
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
common
solarium
Commits
7bc6bc24
Commit
7bc6bc24
authored
Jun 10, 2015
by
Pierre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix curl headers for solr > 5
parent
45ed4658
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
library/Solarium/Core/Client/Adapter/Curl.php
library/Solarium/Core/Client/Adapter/Curl.php
+5
-1
No files found.
library/Solarium/Core/Client/Adapter/Curl.php
View file @
7bc6bc24
...
...
@@ -156,7 +156,11 @@ class Curl extends Configurable implements AdapterInterface
}
if
(
!
isset
(
$options
[
'headers'
][
'Content-Type'
]))
{
$options
[
'headers'
][
'Content-Type'
]
=
'text/xml; charset=utf-8'
;
if
(
$method
==
Request
::
METHOD_GET
){
$options
[
'headers'
][
'Content-Type'
]
=
'application/x-www-form-urlencoded; charset=utf-8'
;
}
else
{
$options
[
'headers'
][
'Content-Type'
]
=
'application/xml; charset=utf-8'
;
}
}
// Try endpoint authentication first, fallback to request for backwards compatibility
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment