array(
'next' => 'Next section',
'prev' => 'Previous section',
'next_default' => 'This is the last section',
'prev_default' => 'This is the first section'
),
'it' => array(
'next' => 'Sezione successiva',
'prev' => 'Sezione precedente',
'next_default' => 'Questa è l\'ultima sezione',
'prev_default' => 'Questa è la prima sezione'
)
);
$labels = isset($labels[$lang]) ? $labels[$lang] : $labels['en'];
// Haal posts op in dezelfde categorie, tag en taal
$args = array(
'posts_per_page' => -1,
'post_type' => 'post',
'orderby' => 'title',
'order' => 'ASC',
'tag_slug__in' => $tag_slugs,
'category__in' => wp_get_post_categories($post->ID),
'post_status' => 'publish',
'suppress_filters' => false, // WPML filter toepassen
'lang' => $lang // WPML taalfilter
);
$posts = get_posts($args);
if(empty($posts)) return;
// Vind index van huidige post
$current_index = null;
foreach($posts as $i => $p) {
if($p->ID == $post->ID) {
$current_index = $i;
break;
}
}
if($current_index === null) return;
// Bepaal next/previous post
if($direction === 'next') {
$target_index = $current_index + 1;
$text = ($target_index < count($posts)) ? $labels['next'] : $labels['next_default'];
} else {
$target_index = $current_index - 1;
$text = ($target_index >= 0) ? $labels['prev'] : $labels['prev_default'];
}
$link = ($target_index >= 0 && $target_index < count($posts)) ? get_permalink($posts[$target_index]->ID) : '#';
$icon_position = ($direction === 'prev') ? 'before' : 'after';
echo '
';
}
/**
* Functie: Back to manual links met WPML en meertalige labels
*/
function back_to_manual_link($page_id, $img_url, $labels) {
$lang = defined('ICL_LANGUAGE_CODE') ? ICL_LANGUAGE_CODE : 'en';
$text = isset($labels[$lang]) ? $labels[$lang] : $labels['en'];
if(function_exists('icl_object_id')) {
$translated_id = apply_filters('wpml_object_id', $page_id, 'page', true);
} else {
$translated_id = $page_id;
}
$link = get_permalink($translated_id);
echo '
';
}
// --- Next/Previous links ---
if(has_tag(array('manual-en-2','manuale-it'))) {
manual_navigation_by_title('prev', array('manual-en-2','manuale-it'), 'https://thinkable.nl/wp-content/uploads/2018/09/previous.png');
manual_navigation_by_title('next', array('manual-en-2','manuale-it'), 'https://thinkable.nl/wp-content/uploads/2018/09/next.png');
}
// --- Back to manual links ---
$manual_links = array(
'tvmanualsection-en' => array(
'page_id' => 1515,
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to TactileView manual overview',
'it' => 'Torna al manuale TactileView'
)
),
'tpmanualsection-en' => array(
'page_id' => 1996,
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to TactiPad manual overview',
'it' => 'Torna al manuale TactiPad'
)
),
'manuale-it' => array(
'page_id' => 1996,
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to TactiPad manual overview',
'it' => 'Torna al manuale TactiPad'
)
),
'circleframe-en' => array(
'url' => 'https://thinkable.nl/tactipad/circleframe-manual',
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to CircleFrame manual overview',
'it' => 'Torna al manuale CircleFrame'
)
),
'graphgrid-en' => array(
'url' => 'https://thinkable.nl/tactipad/graphgrid-manual',
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to GraphGrid manual overview',
'it' => 'Torna al manuale GraphGrid'
)
),
'graphgrid-manual-en' => array(
'url' => 'https://thinkable.nl/tactipad/graphgrid-manual',
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to GraphGrid manual overview',
'it' => 'Torna al manuale GraphGrid'
)
),
'graphgrid-tools-en' => array(
'url' => 'https://thinkable.nl/tactipad/graphgrid/',
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to GraphGrid overview',
'it' => 'Torna alla panoramica GraphGrid'
)
),
'tactiforma' => array(
'url' => 'https://thinkable.nl/tactiforma-manual-overview/',
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to Tactiforma overview',
'it' => 'Torna alla panoramica Tactiforma'
)
),
'mdamanualsection-en' => array(
'page_id' => 4284,
'img' => 'https://thinkable.nl/wp-content/uploads/2018/09/up.png',
'labels' => array(
'en' => 'Return to MDA manual overview',
'it' => 'Torna al manuale MDA'
)
),
);
foreach($manual_links as $tag => $data) {
if(has_tag($tag) || has_category($tag)) {
if(isset($data['page_id'])) {
back_to_manual_link($data['page_id'], $data['img'], $data['labels']);
} elseif(isset($data['url'])) {
$text = isset($data['labels'][$lang]) ? $data['labels'][$lang] : $data['labels']['en'];
echo '
';
}
}
}
?>
The MDA has the possibility to mount two different MDA directories directly to a PC, Mac or tablet.
The first directory is the MDA-upload directory. Any SVG image that you copy into this directory will appear on the upload page in the MDA interface. The second directory is the MDA-autosketch directory. Any SVG image or GPX formatted file derived from an SVG image will be sketched automatically on the MDA.
In order to mount a directory, both the MDA and the device you want to mount the drive on need to be connected to the same network. You can also connect your device to the MDA’s hotspot. Mounting a drive requires a one-time setup, afterwards the MDA directories are directly and always available on PC, Mac or tablet.
In order to mount the MDA on your device, the following setup actions are required:
- On a PC: open “File Explorer”, select “Home”, go to “Easy Access” in the “New” section and select “Map as Drive”. Select a drive letter (like U: for upload, or S: for autosketch). Don’t use the browse option for “Folder” but enter the following in the “Folder” input field: \\mda\MDA-upload (if you changed the name of the MDA from mda to a different name, use the new name instead of mda in this command). Make sure that the box “Reconnect at sign-in” is selected and press “Finish” (if prompted for a login and/or password, type guest for both). Now the MDA-Upload directory is permanently mounted on your PC, accessible under the drive letter that you selected during the setup. When you copy or save a file to this drive, it appears on the upload page of the MDA. Mounting the autosketch directory requires the same procedure as mentioned above, with the exception that you need to enter \\mda\MDA-autosketch in the “Folder” input field. Again, if you changed the default name of the MDA you have to change mda to the new name.
- On a Mac, the name of the MDA appears automatically in the “Shared” section of the “Finder”. Click on the name of the MDA (default mda) and click on “Connect as”, continue with “Connect” and enter guest in the name field and password field. Make sure to tick (ü) the box “Remember this password in my keychain” and press “Select”. The MDA-upload directory will from now on be accessible from the Finder. In case you want to connect to the autosketch directory, first you will have to select “disconnect” and then repeat the above procedure, but this time with the loginname autosketch and password autosketch. You will be connected as autosketch instead of guest, although the directory will still called MDA-upload. If you regularly need to switch between upload (guest) and autosketch, do not save your login credentials to “keychain”, but instead enter them every time to access the proper directory.
- On an iPad, you can make a connection to the MDA through the “FileBrowser” app, a free app available in the app-store. In FileBrowser, select “Location” in the bottom bar and then “+” in the top bar. Select “Computer/Network Drive” and then “Mac”. The app will start scanning, but you do not need wait for the scan to finish. Instead select “Manual setup”. On the next screen, select “Mac” and enter mda in the “Address” field (or the new name in case you have changed the default name mda). Click “Edit…” in the “User name” field and enter guest, click “Edit…” in the “Password” field and enter guest again. Enter mda in the “Display name” field. By selecting mda from the “locations” tab, you will now have a connection from the iPad to both the MDA-upload directory and the MDA-autosketch directory.
- On Android, an connection can be established trough the free “AndSMB” app, which can be downloaded from the Play Store. In AndSMB select the + button in the top bar. On the next screen, enter mda in the “Hostname” field (or the new name in case you have changed the default name mda). In the “Username” and “Password” field enter guest. In the “Remote dir” field enter /MDA-upload. Leave the rest of the fields empty. Click save, and in the pop up window enter mda, or whatever other name you want the drive to have in AndSMB. By selecting AndSMB when selecting “Share” and then selecting the name you gave to the drive in AndSMB files will automatically be uploaded to the upload map.