aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/text.php8
-rw-r--r--view/tpl/website_import_tools.tpl28
2 files changed, 28 insertions, 8 deletions
diff --git a/include/text.php b/include/text.php
index 57339e16d..096c8a5aa 100644
--- a/include/text.php
+++ b/include/text.php
@@ -2264,9 +2264,13 @@ function website_import_tools() {
$who = $channel['channel_address'];
- return replace_macros(get_markup_template('design_tools.tpl'), array(
+ return replace_macros(get_markup_template('website_import_tools.tpl'), array(
'$title' => t('Import'),
- '$who' => $who,
+ //'$who' => $who,
+ '$import_label' => t('Import website...'),
+ '$import_placeholder' => t('Select folder to import'),
+ '$file_upload_text' => t('Import from a zipped folder:'),
+ '$file_import_text' => t('Import from cloud files:')
));
}
diff --git a/view/tpl/website_import_tools.tpl b/view/tpl/website_import_tools.tpl
index 2e319b61d..09b100926 100644
--- a/view/tpl/website_import_tools.tpl
+++ b/view/tpl/website_import_tools.tpl
@@ -1,7 +1,23 @@
-<div id="website-import-tools" class="widget design-tools">
-<h3>{{$title}}</h3>
-<p class="descriptive-text">Import website from cloud files</p>
-<ul class="nav nav-pills nav-stacked">
- <li><button class="btn-md btn-primary"><a href="/cloud/{{$who}}">Select folder...</a></button></li>
-</ul>
+<div id="website-import-tools" class="widget">
+ <h3>{{$title}}</h3>
+ <ul class="nav nav-pills nav-stacked">
+ <li>
+ <a href="#" onclick="openClose('import-form'); return false;"><i class="fa fa-cloud-upload generic-icons"></i> {{$import_label}}</a>
+ </li>
+ <form id="import-form" enctype="multipart/form-data" method="post" action="" style="display: none;" class="sub-menu">
+ <p class="descriptive-text">{{$file_import_text}}</p>
+ <div class="form-group">
+ <select id="import" name="target" class="form-control">
+ <option value="">{{$import_placeholder}}</option>
+ <!-- Loop through folders here -->
+ </select>
+ </div>
+ <!-- Or upload a zipped file containing the website -->
+ <p class="descriptive-text">{{$file_upload_text}}</p>
+ <div class="form-group">
+ <input id="website-upload-choose" type="file" name="userfile" />
+ </div>
+ <button class="btn btn-primary btn-sm" type="submit" name="c_upload" value="c_upload">Upload</button>
+ </form>
+ </ul>
</div>