Author Topic: ANCHOR - how to implement table of contents and links in version 2.0.1  (Read 1963 times)

odicezar

  • Newbie
  • *
  • Posts: 11
In version 1.38 the links and content was as follows:
page>
<img width="400" height="600">
<src lang="en">src/en/contents.jpg</src>
</img>
<nav align="center" color="#423e21" hover="#5e5934" width="325" left="25" top="200">
<lnk url="anchor:download"><![CDATA[<font face="serif" size="24">Download</font>]]></lnk>
</nav>
</page>
<page anchor="download">
<img>
<src lang="en">src/en/page_download.jpg</src>
</img>
<area left="140" top="270" width="120" height="26" url="../../download/mz3v135.zip" overlay="none">
<title lang="en">Download the latest version (1.35)</title>
</area>
</page>


A book I'm upgrading to version 2.0.1 but the links are not opening. What is the procedure to run.
I appreciate any help

Odicezar


bobbo

  • Newbie
  • *
  • Posts: 19
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #1 on: November 16, 2009, 08:47:50 pm »
I think the src is now specified like this..

<img src="......"    />

odicezar

  • Newbie
  • *
  • Posts: 11
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #2 on: November 17, 2009, 01:34:32 am »
Not this! ...
The problem is this line:
Code: [Select]
<page>
<img src="src/contents.jpg" width="400" height="600"/>
<nav align="left" color="#423e21" hover="#5e5934" width="400" left="20" top="30">
<lnk lang="en" url="anchor:download"><![CDATA[<font face="serif" size="13">download</font>]]>
</lnk>
</nav>
</page>
When the book arrives on the "contents.jpg" should be a link "download" link to be clicked and go directly to the page.
But nothing happens. Just showing up is the symbol of "loading" turning in circles.
The nagegação is normal and can I go ahead or to bring.
Only I can not play the content on that page.
That's it! ...
Any errors in language, sorry, because I am Brazilian and have not mastered English very well.

Odicezar

bobbo

  • Newbie
  • *
  • Posts: 19
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #3 on: November 17, 2009, 02:32:22 am »
just a guess but maybe 'download' is a reserved word?  try changing name to 'dwnload'   or something like that ?

odicezar

  • Newbie
  • *
  • Posts: 11
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #4 on: November 17, 2009, 02:56:07 am »
Thank you. Not the case of reserved word. I can put any word that the problem remains the same.

OdiCezar

bobbo

  • Newbie
  • *
  • Posts: 19
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #5 on: November 17, 2009, 03:08:55 am »
how about this ...you have image width = 400    , but width of nav area is 400 and left = 20  ....thus does not 'fit' ?

odicezar

  • Newbie
  • *
  • Posts: 11
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #6 on: November 17, 2009, 03:29:08 pm »
I did not get it right.
Let me tell you from the beginning.
Usei como modelo o book baixado de http://megazine.mightypirates.de/download/demo.zip.

I used the book as a template downloaded from http://megazine.mightypirates.de/download/demo.zip and adapted to my needs.

1:38 In version everything worked perfectly. Only one caveat: When you run the file megazine.swf, the splash screen appears minimized, requiring the user to always maximize to see the book.
 
You might ask why not use the index.html. I wanted my book open in separate window, type popup. I could not implement this in the index.html file.

When you download the version 2.0.1 I noticed that the file already opened megazine.swf maximized as I wanted the model presented. I then decided to move my book for the new version.

In this version, the index does not appear on the page to be linked.
So I believe it is some problem of migration and some plugin.

How to make an index page in this new version? Using <nav>, <lnk>?

Bye
OdiCezar




Hans Nücke

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 787
  • MegaZine3 Sales Manager
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #7 on: November 17, 2009, 03:30:47 pm »
The code looks fine so far and should work.
You're using localization (lang="en"): have you a matching declaration in the <book declaration like:
<book ... lang="en,de"... >

If you live in Brazil then the language defaults to Portuguese, and if you only have lines of code that are ocalized to ENglish, you won't see anything unless you switch language to "en" (English"!
Give it a try and switsch to English: the fastest way to check ;-)

If that does not help and knowing you come from 1.3x:
Have you listed the needed plugins like:
<book plugins="anchors, ..., links, ..., swfaddress, titles" ... >

Check the wiki for more details

Please share those lines of code also; or confirm what was missing if you made it work
« Last Edit: November 17, 2009, 03:34:43 pm by hnuecke »

odicezar

  • Newbie
  • *
  • Posts: 11
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #8 on: November 18, 2009, 02:45:25 am »
hnueke,
I made the adjustments relating to the language that you suggested but the problem persists. The index does not appear on the page.
As you requested I put the code also megazine.mz3.

Code: [Select]
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE book SYSTEM "http://megazine.mightypirates.de/megazine.dtd">

<book plugins="anchors, console, backgroundsounds, batchpages, elementids, gallery, javascript, keyboardnavigation, links, navigationbar, options, overlays, password, slideshow, swfaddress, titles"
bgcolor="0xbba978" dragrange="80" pagewidth="400" pageheight="600" lang="en,de,pt-BR" reflection="false" maxscale="2" minscale="0.25" >
    <background>
   
       
<!--
           
Note: if it bothers you, you may delete the "Powered by MegaZine3" link by removing the following box tag.
            But we would appreciate it if you'd leave it in to spread the word. Thanks!
       
-->
       
<box background="image(gui/engine/poweredby.png)" width="160" height="45" anchors="pw-w,ph-h" url="http://megazine.mightypirates.de/" target="_blank"/>
   
</background>

<chapter>

<page stiff="true" anchor="cover">
<img src="src/cover_front.jpg" aa="true" width="400" height="600"/>
</page>
<page>
<img src="src/cover_front_in.jpg" aa="true" width="400" height="600"/>
</page>

<page>
<img src="src/contents.jpg" width="400" height="600"/>
<nav align="left" color="#423e21" hover="#5e5934" width="400" left="20" top="30">
<lnk lang="en" url="anchor:download"><![CDATA[<font face="serif" size="13">download</font>]]>
</lnk>
</nav>
</page>


<!--GABINETE FOLHA 01/15 -->

<page anchor="download">
<img>
<src lang="en">src/en/page_download.jpg</src>
</img>
<area left="140" top="270" width="120" height="26" url="../../download/mz3v135.zip" overlay="none">
<title lang="en">Download the latest version (1.35)</title>
</area>
</page>

</chapter>
</book>
For me a new suit. I found the "console"
After opening the book, ran the "console" and the codes that appear are:
[Megazine] System : Megazine version 2.0.2 initializing...
[Megazine] Notice: Begin loading XML data from file 'file:///c|/anuario/megazine.mz3'.
[Megazine] Notice: Parsing settings: step 1 (engine settings).
[settings] System: disabling notices.
[Localizer] Warnhg: could not load XML data for localization: Error #2032

 I will highlight the piece of code that does not appear on the page as it should, on the index.


Code: [Select]
<page>
<img src="src/contents.jpg" width="400" height="600"/>
<nav align="left" color="#423e21" hover="#5e5934" width="400" left="20" top="30">
<lnk lang="en" url="anchor:download"><![CDATA[<font face="serif" size="13">download</font>]]>
</lnk>
</nav>
</page>
Only appears on page contents.jpg, but the link to "anchor: download" does not appear and the problem continues.
Bye

odicezar

  • Newbie
  • *
  • Posts: 11
Re: ANCHOR - how to implement table of contents and links in version 2.0.1
« Reply #9 on: November 19, 2009, 02:35:33 am »
 I found a solution! ...
It seems there is a problem with this code:
Code: [Select]
<page>
<img src="src/contents.jpg" width="400" height="600"/>
<nav align="left" color="#423e21" hover="#5e5934" width="400" left="20" top="30">
<lnk lang="en" url="anchor:download"><![CDATA[<font face="serif" size="13">download</font>]]>
</lnk>
</nav>
</page>
I can not say exactly what it is.
So I decided to change by <nav> element <area>.
What also helped me was to validate the XML file.
Open a window with http://www.validome.org/xml/.
I found this line in the tutorial for the version 2.0.
This was key to my success.
this part of the code is as follows:
Code: [Select]
<page>
<img src="src/contents.jpg"/>
<area width="200" height="30" top="200" url="anchor:download" title="download" overlay="color(0,0,0xff00ff)"/>
</page>

It is my doubt: for with <nav> not work?
Thank all who helped or tried to help.
OdiCezar