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 '
';
}
}
}
?>
SVG images can be sketched from the MDA interface, from the following four pages:
- Uploads, images can be uploaded to this page by yourself
- USB-stick, images from an inserted USB-stick
- MyImages, images requested by you, made by designers from the MyImages community
- Examples, images from the various example categories present on the MDA
In every case the way to start sketching the image is with a simple mouse click (or a different method for “clicking” the image). . The MDA will then start sketching the selected image.
At the top of all of the four pages, the last sketched image is shown, by clicking on this image, the image will be sketched again.
The Uploads and MyImages pages also allow you to delete images from the MDA.
Note that when you try to sketch another image while the MDA is still sketching, you will get a notification that the MDA is busy, and you will have to wait until the MDA has completed the sketch to issue the sketch command.