[jsword-devel] iPhone WebApp Take 2
Greg Hellings
greg.hellings at gmail.com
Sun Apr 20 09:26:57 MST 2008
On Sun, Apr 20, 2008 at 7:02 AM, DM Smith <dmsmith555 at yahoo.com> wrote:
>
>
> On Apr 20, 2008, at 6:04 AM, Ben Morgan wrote:
>
> Hi Greg,
>
> In the ESV, any crossreferences attempt to reference the bible:// protocol.
> I presume this is from using the xslt from jsword.
>
> This and the Strong's references, in the xslt need to be tweaked to call
> JavaScript. I found the following result useful:
> <a href="bible://Rev.4.11" onclick="return setPassage('Rev.4.11');">Rev.
> 4:11</a>
>
> Here is the xslt change:
>
>
> <xsl:template match="reference">
> <xsl:choose>
> <xsl:when test="$XRef = 'true'">
> <a href="bible://{@osisRef}" onclick="return
> setPassage('{@osisRef}');"><xsl:apply-templates/></a>
> </xsl:when>
> <xsl:otherwise>
> <xsl:apply-templates/>
> </xsl:otherwise>
> </xsl:choose>
> </xsl:template>
>
> The javascript setPassage(ref) needs to return false if the href is to be
> ignored.
Unfortunately, since I don't write the Javascript manually, it's a bit
tougher to integrate something like this into the app. However, once
the history listener is in place, I can change these to be anchor tags
of the type #reference_Rev_4:11 or something similar. Clicks on a
reference of that type are processed by the history listener
>
> I think what I'm going to do in the long run is not use the same routine
> that I use to do passage lookups. Instead, I want to have a hover popup with
> the content. I find it annoying to go and see a single reference, when what
> I really want is to see it in context of what I am reading. I keep going
> back to the prior screen.
Hovering essentially doesn't exist in the iPhone, but a popup is
probably the way to go. There is plenty of support for those (like
the windows that pop-up in GMail if you select a contact from your
list). Good suggestion!
>
>
>
> _______________________________________________
> jsword-devel mailing list
> jsword-devel at crosswire.org
> http://www.crosswire.org/mailman/listinfo/jsword-devel
>
>
More information about the jsword-devel
mailing list