Version Description
- January 12, 2016 =
- FIX - Update to instant_img_resize_image function to remove unnecessary function arguments. These args were causing issues on some servers.
- NEW - Refresh Media Library content when uploading images through the Instant Images uploader on edit screen for posts and pages.
- UI Enhancements
Download this release
Release Info
Developer | dcooney |
Plugin | Instant Images – One Click Unsplash Uploads |
Version | 2.0.1 |
Comparing to | |
See all releases |
Code changes from version 2.0 to 2.0.1
- README.txt +20 -10
- admin/admin.php +2 -2
- admin/assets/css/admin.css +6 -4
- admin/assets/img/post-explorer-logo-48x48.png +0 -0
- admin/assets/js/unsplash.js +13 -0
- admin/includes/cta/about.php +6 -3
- admin/includes/settings.php +1 -1
- instant-images.php +4 -4
- lang/instant-images.pot +6 -8
README.txt
CHANGED
@@ -1,29 +1,33 @@
|
|
1 |
-
=== Instant Images ===
|
2 |
Contributors: dcooney
|
3 |
Donate link: https://connekthq.com/donate/
|
4 |
Tags: stock photo, stock, unsplash, prototyping, photos, upload, media, media library, ajax, image upload, direct upload, free stock photos
|
5 |
Requires at least: 3.6
|
6 |
-
Tested up to: 4.
|
7 |
-
Stable tag: 2.0
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
-
One click uploads of
|
12 |
|
13 |
== Description ==
|
14 |
|
15 |
**Instant Images** is the fastest and easiest way to upload high quality stock photos from [unsplash.com](http://unsplash.com) directly to your media library — **all without ever leaving WordPress**!
|
16 |
|
|
|
|
|
17 |
The perfect tool for users who want to save time and frustrating by uploading images directly inside their WordPress installation and for developers who want to prototype and develop using real world imagery.
|
18 |
|
|
|
|
|
19 |
= Features =
|
20 |
|
21 |
-
* Image Search - The Instant Images search functionality let’s you quickly find and upload images for any subject in a matter of seconds!
|
22 |
-
* Time Saver - Quickly upload amazing stock photos without leaving the comfort of your WordPress admin.
|
23 |
-
* Theme/Plugin Developers - A great tool for developers who want to prototype and develop using real world imagery.
|
24 |
-
* Easy to Use - It couldn't get much more simple, just click an image and it's automatically uploaded to your media library for use on your site.
|
|
|
25 |
|
26 |
-
**[Visit Plugin Website](https://connekthq.com/plugins/instant-images/)**
|
27 |
|
28 |
***
|
29 |
|
@@ -37,7 +41,7 @@ The perfect tool for users who want to save time and frustrating by uploading im
|
|
37 |
***
|
38 |
|
39 |
= Website =
|
40 |
-
https://connekthq.com/plugins/instant-images/
|
41 |
|
42 |
***
|
43 |
|
@@ -103,6 +107,12 @@ How to install Instant Images.
|
|
103 |
|
104 |
== Changelog ==
|
105 |
|
|
|
|
|
|
|
|
|
|
|
|
|
106 |
= 2.0 =
|
107 |
* Initial Commit
|
108 |
* Updating plugin from UnsplashWP to Instant Images
|
1 |
+
=== Instant Images - One Click Unsplash Uploads ===
|
2 |
Contributors: dcooney
|
3 |
Donate link: https://connekthq.com/donate/
|
4 |
Tags: stock photo, stock, unsplash, prototyping, photos, upload, media, media library, ajax, image upload, direct upload, free stock photos
|
5 |
Requires at least: 3.6
|
6 |
+
Tested up to: 4.7.3
|
7 |
+
Stable tag: 2.0.1
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
+
One click uploads of Unsplash photos directly to your WordPress media library.
|
12 |
|
13 |
== Description ==
|
14 |
|
15 |
**Instant Images** is the fastest and easiest way to upload high quality stock photos from [unsplash.com](http://unsplash.com) directly to your media library — **all without ever leaving WordPress**!
|
16 |
|
17 |
+
[youtube https://www.youtube.com/watch?v=s6Q7Kfi2f1c]
|
18 |
+
|
19 |
The perfect tool for users who want to save time and frustrating by uploading images directly inside their WordPress installation and for developers who want to prototype and develop using real world imagery.
|
20 |
|
21 |
+
**[Visit Plugin Website](https://connekthq.com/plugins/instant-images/)**
|
22 |
+
|
23 |
= Features =
|
24 |
|
25 |
+
* **Image Search** - The Instant Images search functionality let’s you quickly find and upload images for any subject in a matter of seconds!
|
26 |
+
* **Time Saver** - Quickly upload amazing stock photos without leaving the comfort of your WordPress admin.
|
27 |
+
* **Theme/Plugin Developers** - A great tool for developers who want to prototype and develop using real world imagery.
|
28 |
+
* **Easy to Use** - It couldn't get much more simple, just click an image and it's automatically uploaded to your media library for use on your site.
|
29 |
+
|
30 |
|
|
|
31 |
|
32 |
***
|
33 |
|
41 |
***
|
42 |
|
43 |
= Website =
|
44 |
+
[https://connekthq.com/plugins/instant-images/](https://connekthq.com/plugins/instant-images/)
|
45 |
|
46 |
***
|
47 |
|
107 |
|
108 |
== Changelog ==
|
109 |
|
110 |
+
= 2.0.1 - January 12, 2016 =
|
111 |
+
* FIX - Update to instant_img_resize_image function to remove unnecessary function arguments. These args were causing issues on some servers.
|
112 |
+
* NEW - Refresh Media Library content when uploading images through the Instant Images uploader on edit screen for posts and pages.
|
113 |
+
* UI Enhancements
|
114 |
+
|
115 |
+
|
116 |
= 2.0 =
|
117 |
* Initial Commit
|
118 |
* Updating plugin from UnsplashWP to Instant Images
|
admin/admin.php
CHANGED
@@ -107,7 +107,7 @@ function instant_img_media_popup($context) {
|
|
107 |
|
108 |
// popup title
|
109 |
$title = INSTANT_IMG_TITLE;
|
110 |
-
$title_txt = INSTANT_IMG_TITLE .' - '. __('Direct image
|
111 |
$context .= "<a href='#TB_inline?width=600&height=600&inlineId=instant_images_modal'
|
112 |
class='button thickbox instant-images' title='$title_txt'>
|
113 |
<span class='dashicons dashicons-format-gallery' style='font-size: 16px; top: 6px;'></span> ".INSTANT_IMG_TITLE."</a>";
|
@@ -283,7 +283,7 @@ add_action( 'wp_ajax_instant_img_upload_image', 'instant_img_upload_image' ); //
|
|
283 |
* @since 2.0
|
284 |
*/
|
285 |
|
286 |
-
function instant_img_resize_image(
|
287 |
|
288 |
if (current_user_can( 'edit_theme_options' )){
|
289 |
|
107 |
|
108 |
// popup title
|
109 |
$title = INSTANT_IMG_TITLE;
|
110 |
+
$title_txt = INSTANT_IMG_TITLE .' - '. __('Direct image uploads to your media library', 'instant-images');
|
111 |
$context .= "<a href='#TB_inline?width=600&height=600&inlineId=instant_images_modal'
|
112 |
class='button thickbox instant-images' title='$title_txt'>
|
113 |
<span class='dashicons dashicons-format-gallery' style='font-size: 16px; top: 6px;'></span> ".INSTANT_IMG_TITLE."</a>";
|
283 |
* @since 2.0
|
284 |
*/
|
285 |
|
286 |
+
function instant_img_resize_image(){
|
287 |
|
288 |
if (current_user_can( 'edit_theme_options' )){
|
289 |
|
admin/assets/css/admin.css
CHANGED
@@ -114,12 +114,13 @@ Copyright: Darren Cooney & Connekt Media
|
|
114 |
font-weight: 700;
|
115 |
color: #333;
|
116 |
margin: 15px 0 20px;
|
|
|
117 |
}
|
118 |
.instant-img-container #initialize p{
|
119 |
display: block;
|
120 |
-
padding: 10px
|
121 |
font-size: 16px;
|
122 |
-
line-height:
|
123 |
}
|
124 |
.instant-img-container #initialize p.sm{
|
125 |
font-size: 14px;
|
@@ -129,7 +130,7 @@ Copyright: Darren Cooney & Connekt Media
|
|
129 |
color: #999;
|
130 |
display: block;
|
131 |
font-size: 14px;
|
132 |
-
padding:
|
133 |
}
|
134 |
.instant-img-container #initialize p i{
|
135 |
color: #999;
|
@@ -147,7 +148,7 @@ Copyright: Darren Cooney & Connekt Media
|
|
147 |
border-radius: 2px;
|
148 |
}
|
149 |
.instant-img-container .init-options h3{
|
150 |
-
font-size:
|
151 |
margin: 0;
|
152 |
padding: 0;
|
153 |
line-height: 1.55;
|
@@ -197,6 +198,7 @@ Copyright: Darren Cooney & Connekt Media
|
|
197 |
margin-top: -1px;
|
198 |
margin-left: 1px;
|
199 |
color: #999;
|
|
|
200 |
}
|
201 |
|
202 |
|
114 |
font-weight: 700;
|
115 |
color: #333;
|
116 |
margin: 15px 0 20px;
|
117 |
+
font-style: italic;
|
118 |
}
|
119 |
.instant-img-container #initialize p{
|
120 |
display: block;
|
121 |
+
padding: 10px 15% 0;
|
122 |
font-size: 16px;
|
123 |
+
line-height: 24px;
|
124 |
}
|
125 |
.instant-img-container #initialize p.sm{
|
126 |
font-size: 14px;
|
130 |
color: #999;
|
131 |
display: block;
|
132 |
font-size: 14px;
|
133 |
+
padding: 20px 0 0;
|
134 |
}
|
135 |
.instant-img-container #initialize p i{
|
136 |
color: #999;
|
148 |
border-radius: 2px;
|
149 |
}
|
150 |
.instant-img-container .init-options h3{
|
151 |
+
font-size: 14px;
|
152 |
margin: 0;
|
153 |
padding: 0;
|
154 |
line-height: 1.55;
|
198 |
margin-top: -1px;
|
199 |
margin-left: 1px;
|
200 |
color: #999;
|
201 |
+
font-size: 14px;
|
202 |
}
|
203 |
|
204 |
|
admin/assets/img/post-explorer-logo-48x48.png
ADDED
Binary file
|
admin/assets/js/unsplash.js
CHANGED
@@ -260,6 +260,19 @@ jQuery(document).ready(function($) {
|
|
260 |
if(!$('span.check', el).length){
|
261 |
el.append('<span class="check" title="'+ msg +'"><i class="fa fa-check"></i></span>');
|
262 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
263 |
}
|
264 |
}else{ // If reponse is empty
|
265 |
unsplash.uploadError(el);
|
260 |
if(!$('span.check', el).length){
|
261 |
el.append('<span class="check" title="'+ msg +'"><i class="fa fa-check"></i></span>');
|
262 |
}
|
263 |
+
|
264 |
+
// Refresh Media Library content on edit pages
|
265 |
+
if(typeof wp.media != 'undefined'){
|
266 |
+
if(wp.media.frame.content.get()!==null){
|
267 |
+
wp.media.frame.content.get().collection.props.set({ignore: (+ new Date())});
|
268 |
+
wp.media.frame.content.get().options.selection.reset();
|
269 |
+
}else{
|
270 |
+
if(typeof wp.media.frame.library != 'undefined'){
|
271 |
+
wp.media.frame.library.props.set({ignore: (+ new Date())});
|
272 |
+
}
|
273 |
+
}
|
274 |
+
}
|
275 |
+
|
276 |
}
|
277 |
}else{ // If reponse is empty
|
278 |
unsplash.uploadError(el);
|
admin/includes/cta/about.php
CHANGED
@@ -9,12 +9,15 @@ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
|
9 |
<strong><a href="https://connekthq.com/plugins/ajax-load-more/" target="blank">Ajax Load More</a></strong><br>A powerful plugin to add infinite scroll functionality to your website.</li>
|
10 |
<li>
|
11 |
<img src="<?php echo INSTANT_IMG_ADMIN_URL; ?>/assets/img/eq-logo-48x48.png" alt"" />
|
12 |
-
<strong><a href="https://connekthq.com/plugins/easy-query/" target="blank">Easy Query</a></strong><br>
|
|
|
|
|
|
|
13 |
<li>
|
14 |
<img src="<?php echo INSTANT_IMG_ADMIN_URL; ?>/assets/img/velocity-logo-48x48.png" alt"" />
|
15 |
-
<strong><a href="https://connekthq.com/plugins/velocity/" target="blank">Velocity</a></strong><br>Improve website performance by lazy loading
|
16 |
</ul>
|
17 |
<hr style="margin: 6px 0 20px;"/>
|
18 |
-
<p><strong><?php echo INSTANT_IMG_TITLE; ?></strong> is made with <span style="color: #e25555;">♥</span> by <a target="blank" href="https://connekthq.com">Connekt</a
|
19 |
<a class="visit" target="blank" href="https://connekthq.com/plugins/instant-images/"><i class="fa fa-globe"></i> Visit Plugin Website</a>
|
20 |
</div>
|
9 |
<strong><a href="https://connekthq.com/plugins/ajax-load-more/" target="blank">Ajax Load More</a></strong><br>A powerful plugin to add infinite scroll functionality to your website.</li>
|
10 |
<li>
|
11 |
<img src="<?php echo INSTANT_IMG_ADMIN_URL; ?>/assets/img/eq-logo-48x48.png" alt"" />
|
12 |
+
<strong><a href="https://connekthq.com/plugins/easy-query/" target="blank">Easy Query</a></strong><br>Build and display complex queries without touching a line of code.</li>
|
13 |
+
<li>
|
14 |
+
<img src="<?php echo INSTANT_IMG_ADMIN_URL; ?>/assets/img/post-explorer-logo-48x48.png" alt"" />
|
15 |
+
<strong><a href="https://connekthq.com/plugins/post-explorer/" target="blank">Post Explorer</a></strong><br>Load single posts and custom post types with Ajax.</li>
|
16 |
<li>
|
17 |
<img src="<?php echo INSTANT_IMG_ADMIN_URL; ?>/assets/img/velocity-logo-48x48.png" alt"" />
|
18 |
+
<strong><a href="https://connekthq.com/plugins/velocity/" target="blank">Velocity</a></strong><br>Improve website performance by lazy loading embedded media.</li>
|
19 |
</ul>
|
20 |
<hr style="margin: 6px 0 20px;"/>
|
21 |
+
<p><strong><?php echo INSTANT_IMG_TITLE; ?></strong> is made with <span style="color: #e25555;">♥</span> by <a target="blank" href="https://connekthq.com">Connekt</a></p>
|
22 |
<a class="visit" target="blank" href="https://connekthq.com/plugins/instant-images/"><i class="fa fa-globe"></i> Visit Plugin Website</a>
|
23 |
</div>
|
admin/includes/settings.php
CHANGED
@@ -61,7 +61,7 @@ function instant_img_admin_init(){
|
|
61 |
*/
|
62 |
|
63 |
function unsplash_general_settings_callback() {
|
64 |
-
echo '<p class="desc">' . __('Manage
|
65 |
}
|
66 |
|
67 |
|
61 |
*/
|
62 |
|
63 |
function unsplash_general_settings_callback() {
|
64 |
+
echo '<p class="desc">' . __('Manage your media upload settings', 'instant-images') . '.</p>';
|
65 |
}
|
66 |
|
67 |
|
instant-images.php
CHANGED
@@ -2,11 +2,11 @@
|
|
2 |
/*
|
3 |
Plugin Name: Instant Images
|
4 |
Plugin URI: https://connekthq.com/plugins/instant-images/
|
5 |
-
Description: One click uploads
|
6 |
Author: Darren Cooney
|
7 |
Twitter: @connekthq
|
8 |
Author URI: https://connekthq.com
|
9 |
-
Version: 2.0
|
10 |
License: GPL
|
11 |
Copyright: Darren Cooney & Connekt Media
|
12 |
*/
|
@@ -68,8 +68,8 @@ class InstantImages {
|
|
68 |
*/
|
69 |
|
70 |
private function constants(){
|
71 |
-
define('INSTANT_IMG_VERSION', '2.0');
|
72 |
-
define('INSTANT_IMG_RELEASE', '
|
73 |
define('INSTANT_IMG_TITLE', 'Instant Images');
|
74 |
$upload_dir = wp_upload_dir();
|
75 |
define('INSTANT_IMG_UPLOAD_PATH', $upload_dir['basedir'].'/instant-images');
|
2 |
/*
|
3 |
Plugin Name: Instant Images
|
4 |
Plugin URI: https://connekthq.com/plugins/instant-images/
|
5 |
+
Description: One click photo uploads directly to your media library.
|
6 |
Author: Darren Cooney
|
7 |
Twitter: @connekthq
|
8 |
Author URI: https://connekthq.com
|
9 |
+
Version: 2.0.1
|
10 |
License: GPL
|
11 |
Copyright: Darren Cooney & Connekt Media
|
12 |
*/
|
68 |
*/
|
69 |
|
70 |
private function constants(){
|
71 |
+
define('INSTANT_IMG_VERSION', '2.0.1');
|
72 |
+
define('INSTANT_IMG_RELEASE', 'January 12, 2017');
|
73 |
define('INSTANT_IMG_TITLE', 'Instant Images');
|
74 |
$upload_dir = wp_upload_dir();
|
75 |
define('INSTANT_IMG_UPLOAD_PATH', $upload_dir['basedir'].'/instant-images');
|
lang/instant-images.pot
CHANGED
@@ -1,15 +1,15 @@
|
|
1 |
msgid ""
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: Instant Images\n"
|
4 |
-
"POT-Creation-Date:
|
5 |
-
"PO-Revision-Date:
|
6 |
-
"Last-Translator: Darren Cooney <
|
7 |
"Language-Team: \n"
|
8 |
"Language: en_CA\n"
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
-
"X-Generator: Poedit 1.6.
|
13 |
"X-Poedit-Basepath: .\n"
|
14 |
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
15 |
"X-Poedit-KeywordsList: __;_e\n"
|
@@ -64,7 +64,7 @@ msgid "Please try adjusting your search criteria"
|
|
64 |
msgstr ""
|
65 |
|
66 |
#: ../admin/admin.php:110
|
67 |
-
msgid "Direct image
|
68 |
msgstr ""
|
69 |
|
70 |
#: ../admin/admin.php:201
|
@@ -123,9 +123,7 @@ msgid "Unplash Application ID"
|
|
123 |
msgstr ""
|
124 |
|
125 |
#: ../admin/includes/settings.php:64
|
126 |
-
msgid ""
|
127 |
-
"Manage the media upload settings for your <a href=\"https://unsplash.com\" "
|
128 |
-
"target=\"_blank\">unsplash.com</a> photos"
|
129 |
msgstr ""
|
130 |
|
131 |
#: ../admin/includes/settings.php:93
|
1 |
msgid ""
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: Instant Images\n"
|
4 |
+
"POT-Creation-Date: 2017-01-12 11:53-0500\n"
|
5 |
+
"PO-Revision-Date: 2017-01-12 11:53-0500\n"
|
6 |
+
"Last-Translator: Darren Cooney <dcooney@ecentricarts.com>\n"
|
7 |
"Language-Team: \n"
|
8 |
"Language: en_CA\n"
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
+
"X-Generator: Poedit 1.6.4\n"
|
13 |
"X-Poedit-Basepath: .\n"
|
14 |
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
15 |
"X-Poedit-KeywordsList: __;_e\n"
|
64 |
msgstr ""
|
65 |
|
66 |
#: ../admin/admin.php:110
|
67 |
+
msgid "Direct image uploads to your media library"
|
68 |
msgstr ""
|
69 |
|
70 |
#: ../admin/admin.php:201
|
123 |
msgstr ""
|
124 |
|
125 |
#: ../admin/includes/settings.php:64
|
126 |
+
msgid "Manage your media upload settings"
|
|
|
|
|
127 |
msgstr ""
|
128 |
|
129 |
#: ../admin/includes/settings.php:93
|