Skip to content

Commit 422c082

Browse files
committed
Update plugin version and load language file with
design info
1 parent 491275f commit 422c082

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

printapp.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* Plugin Name: Print.App
44
* Plugin URI: https://print.app
55
* Description: Empower your customers to personalize products like Business Cards, Photo Prints, T-Shirts, Mugs, Banners, Canvases, etc. on your store before purchase
6-
* Version: 1.2.0
6+
* Version: 1.3.0
77
* Requires at least: 3.8
88
* Requires PHP: 5.2.4
99
* Author: 36 Studios, Inc.
@@ -246,7 +246,7 @@ private function getProjectData($product_id) {
246246
$sql = $wpdb->prepare("SELECT `value` FROM `$tableName` WHERE `product_id` = %d AND `id` = %s;", $product_id, $sessId);
247247

248248
$results = $wpdb->get_results($sql);
249-
if(count($results))
249+
if (count($results))
250250
$_projects[$product_id] = $results[0]->value;
251251

252252
return $_projects;
@@ -258,8 +258,10 @@ public function print_app_add_edit_button() {
258258
$pda_domain_key = get_option('print_app_domain_key');
259259

260260
// LOAD SCRIPTS
261-
$run_url = print_app_RUN_BASE_URL . '/' . $pda_domain_key . '/' . $post->ID . '/wp';
262-
wp_enqueue_script('print_app_class', $run_url);
261+
$lang_code = substr(get_bloginfo('language'), 0, 2);
262+
if (!$lang_code) $lang_code = 'en';
263+
$run_url = print_app_RUN_BASE_URL . '/' . $pda_domain_key . '/' . $post->ID . '/wp?lang=' . $lang_code;
264+
wp_enqueue_script('print_app_class', $run_url, '', '', true);
263265

264266
$userData = "";
265267
$projects = $this->getProjectData($post->ID);

readme.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Contributors: Print.App
33
Tags: customizer, photo album, print shop, web2print, gift print, diy print, product customizer, web-to-print, print software, print solution, HTML5 WYSIWYG, t-shirt designer, wysiwyg print editor, business card
44
Requires at least: 3.8
55
Tested up to: 6.3
6-
Stable tag: 1.1.0
6+
Stable tag: 1.3.0
77
License: GPLv2 or later
88
License URI: http://www.gnu.org/licenses/gpl-2.0.html
99

@@ -101,6 +101,10 @@ Check out our [website for more details](https://print.app)
101101

102102
== Changelog ==
103103

104+
= 1.3.0 =
105+
Updated plugin to automatically load the language file with design info
106+
= 1.2.1 =
107+
Minor tag update
104108
= 1.2.0 =
105109
Updated plugin with current documentation and installation instructions
106110
= 1.1.0 =

0 commit comments

Comments
 (0)