Commit d33147a2 authored by webchick's avatar webchick
Browse files

Revert "Issue #1586356 by dww, amateescu: Fixed Missing 'weight' support from...

Revert "Issue #1586356 by dww, amateescu: Fixed Missing 'weight' support from hook_field_widget_info() makes it impossible to sanely order widgets."

This reverts commit 2ffe4abd. Totally, totally wrong commit message.
parent 2ffe4abd
...@@ -710,7 +710,7 @@ function file_get_content_headers(File $file) { ...@@ -710,7 +710,7 @@ function file_get_content_headers(File $file) {
} }
return array( return array(
'Content-Type' => $type, 'Content-Type' => $type . '; name="' . $name . '"',
'Content-Length' => $file->filesize, 'Content-Length' => $file->filesize,
'Content-Disposition' => $disposition . '; filename="' . $name . '"', 'Content-Disposition' => $disposition . '; filename="' . $name . '"',
'Cache-Control' => 'private', 'Cache-Control' => 'private',
......
...@@ -77,7 +77,7 @@ function _testImageFieldFormatters($scheme) { ...@@ -77,7 +77,7 @@ function _testImageFieldFormatters($scheme) {
if ($scheme == 'private') { if ($scheme == 'private') {
// Only verify HTTP headers when using private scheme and the headers are // Only verify HTTP headers when using private scheme and the headers are
// sent by Drupal. // sent by Drupal.
$this->assertEqual($this->drupalGetHeader('Content-Type'), 'image/png', t('Content-Type header was sent.')); $this->assertEqual($this->drupalGetHeader('Content-Type'), 'image/png; name="' . $test_image->filename . '"', t('Content-Type header was sent.'));
$this->assertEqual($this->drupalGetHeader('Content-Disposition'), 'inline; filename="' . $test_image->filename . '"', t('Content-Disposition header was sent.')); $this->assertEqual($this->drupalGetHeader('Content-Disposition'), 'inline; filename="' . $test_image->filename . '"', t('Content-Disposition header was sent.'));
$this->assertTrue(strstr($this->drupalGetHeader('Cache-Control'),'private') !== FALSE, t('Cache-Control header was sent.')); $this->assertTrue(strstr($this->drupalGetHeader('Cache-Control'),'private') !== FALSE, t('Cache-Control header was sent.'));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment