Im trying to code for a javascript that will be link to another API using the navigation button.
I managed to find a solution and hoping this can be useful to others.
In my example; I would like to have javascript for loading a fixed window of "Addthis" using the API.
1) Create a directory under your book.
dir book>dir addthis>
2) Change the "SITE" link and "TITLE from the attached file.
a) addthis.html
b) addthisemail.html
3) Edit the navigational bar and add-in the SHARE and EMAIL button. Follow the changes below: (NOTE ON THE PATH FILE)
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<asul>
<style>
<![CDATA[
button.fullscreen box { background: image(../../custom/functionbutton/btnrecfullscreen3.png); }
button.restore box { background: image(../../custom/functionbutton/btnrecexitfullscreen3.png); }
button.zoom_in box { background: image(../../custom/functionbutton/btnreczoomin3.png); }
button.zoom_out box { background: image(../../custom/functionbutton/btnreczoomout3.png); }
button.mute box { background: image(../../custom/functionbutton/btnrecsound3.png); }
button.unmute box { background: image(../../custom/functionbutton/btnrecmute3.png); }
button.first box { background: image(../../custom/functionbutton/btnrecfirstpage3.png); }
button.last box { background: image(../../custom/functionbutton/btnreclastpage3.png); }
button.prev box { background: image(../../custom/functionbutton/btnrecprevious3.png); }
button.next box { background: image(../../custom/functionbutton/btnrecnext3.png); }
button.share box { background: image(../../custom/functionbutton/btnrecshare3.png); }
button.email box { background: image(../../custom/functionbutton/btnrecemail3.png); }
ADD THIS CODE ON <vflow>.......</vflow of the nav bar
<!-- Addthis.SHARE -->
<button
name="btn_share"
style="common share"
title="localize(LNG_SHARE, Share)"
url="addthis/addthisshare.html">
<box name="$up$"/>
<box name="$over$" style="over"/>
<box name="$down$" style="down"/>
</button>
<!-- Addthis.Mail -->
<button
name="btn_email"
style="common email"
title="localize(LNG_EMAIL, Send Email)"
url="addthis/addthisemail.html">
<box name="$up$"/>
<box name="$over$" style="over"/>
<box name="$down$" style="down"/>
</button>