Copy link to clipboard
Copied
Is it possible to link a specific slide in a project from another project? Rather than the begining of the project, which I know is possible.
Copy link to clipboard
Copied
Hi Sarah,
Yes, this is possible with a bit of JavaScript. Do an Execute JavaScript action on entry of slide 1 with the below code:
window.getQueryParamValue = function (name){
var q=document.location.search||document.location.hash;
if(name==null){return q;}
if(q){var aryParams=q.substring(1).split("&");
for(var i=0;i<aryParams.length;i++){
if(aryParams.substring(0,aryParams.indexOf("="))==name){
return aryParams.substring((aryParams.indexOf("=")+1));
}
}
}
return "";
}
if(typeof window.cp === 'undefined'){
var gotoSlideNumber = getQueryParamValue('cpCmndGotoSlideAndResume');
if(gotoSlideNumber != '') {
document.Captivate.cpEISetValue('m_VarHandle.cpCmndGotoSlideAndResume', gotoSlideNumber -1);
}
}else{
window.gotoSlideNumber = window.getQueryParamValue('cpCmndGotoSlideAndResume');
if(window.gotoSlideNumber != '') {
window.cpCmndGotoSlideAndResume = window.gotoSlideNumber -1;
}
}
Then you can access your course using URL parameters like so:
For SWF output:
http://captivatedev.com/demo/Cp7/JumpToSlide/slide.htm?cpCmndGotoSlideAndResume=9
For HTML5 output:
http://captivatedev.com/demo/Cp7/JumpToSlide/index.html?cpCmndGotoSlideAndResume=7
For Multiscreen:
http://captivatedev.com/demo/Cp7/JumpToSlide/multiscreen.html?cpCmndGotoSlideAndResume=5
The cpCmndGotoSlideAndResume = ? will make the course jump to that slide regardless of SWF or HTML5 output.
Copy link to clipboard
Copied
You can download that example file from here:
http://captivatedev.com/demo/Cp7/JumpToSlide/Cp7_JumpToSlideRegardlessOfOutput.zip
Copy link to clipboard
Copied
You can read more about this with specific use cases here:
http://captivatedev.com/2013/11/21/jump-specific-slide-course-using-captivate-7/