Permalink
Browse files

ENHANCEMENT: Ntfcatn. image embedding(trac #7438)

Adding an additional warning / notification message, when author embedds an external image.
  • Loading branch information...
mightycoco authored and chillu committed Jun 25, 2012
1 parent f79d2df commit 5f94d230002d25cab906a27ae0705953c7d0d9d8
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -896,6 +896,10 @@ public function getOembed() {
public function appCategory() {
return 'embed';
}
+
+ public function getInfo() {
+ return $this->oembed->info;
+ }
}
class HtmlEditorField_Image extends HtmlEditorField_File {
View
@@ -548,5 +548,6 @@ en:
STARTALL: 'Start all'
STARTALLINFO: 'Start all uploads'
Saved: Saved
+ HOTLINKINFO: Info: This image will be hotlinked. Please ensure you have permissions from the original site creator to do so.
Versioned:
has_many_Versions: Versions
View
@@ -513,5 +513,6 @@ en_GB:
STARTALL: 'Start all'
STARTALLINFO: 'Start all uploads'
Saved: Saved
+ HOTLINKINFO: Info: This image will be hotlinked. Please ensure you have permissions from the original site creator to do so.
Versioned:
has_many_Versions: Versions
View
@@ -253,6 +253,7 @@ protected function loadData() {
$data['provider_url'] = $protocoll.$host;
$data['width'] = imagesx($image);
$data['height'] = imagesy($image);
+ $data['info'] = _t('UploadField.HOTLINKINFO', 'Info: This image will be hotlinked. Please ensure you have permissions from the original site creator to do so.');
}
}
@@ -88,6 +88,13 @@ body.cms.ss-uploadfield-edit-iframe, .composite.ss-assetuploadfield .details fie
padding: 0;
overflow: hidden;
position: relative;
+ .info {
+ position: relative;
+ padding: 7px;
+ overflow: hidden;
+ background-color: #FFBE66;
+ border: 1px solid #FF9300;
+ }
}
.ss-uploadfield-item-preview {
position: absolute;
@@ -38,11 +38,13 @@
</div>
</div>
</div>
- <div class="details ss-uploadfield-item-editform loading">
- <fieldset>
- <% loop Fields %>
- $FieldHolder
- <% end_loop %>
- </fieldset>
+ <% if Info %><div class="info">$Info</div><% end_if %>
+ <div class="details ss-uploadfield-item-editform loading">
+ <fieldset>
+ <% loop Fields %>
+ $FieldHolder
+ <% end_loop %>
+ </fieldset>
+ </div>
</div>
</div>

0 comments on commit 5f94d23

Please sign in to comment.