Print

Print


On Mon, Mar 17, 2008 at 10:41 AM, Jonathan Rochkind <[log in to unmask]> wrote:
> Well, the SFX architecture has a feature called "display logic" that
>  let's you on the server side determine how the menu will display based
>  on what services are available. This is more obviously relevant to
>  "digitized text availability" from Google Books than just cover images.
>  You might want to suppress ILL links if there is digitized text (in
>  fact, you probably wouldn't in that particular case, but that gives you
>  the idea of what things you might want to do. At least my library
>  wouldn't, maybe others with especially small ILL budgets might).  Or
>  just give a pre-ILL warning message ("are you sure the Google text isn't
>  sufficient?), that might be more realistic.
>
>  Anyway, you obviously couldn't do this using the existing SFX display
>  logic feature if the Google Books info is only client side.
>  Now, "impossible?"  In the world of software development, few things are
>  actually impossible. You could try to duplicate that feature using only
>  client-side Javascript hiding and showing various DIVs.  The SFX HTML
>  currently isn't that clean, it woudl be hard. But you have the
>  capability to customize the SFX HTML however you want to. (And your
>  customizations will likely break with a future SFX release).   So
>  nothings impossible, but I wouldn't want to go down that road.
>

Your particular requirement (hide the ILL link if Google has text) is
easily implemented using the gbs classes: simply wrap the ILL link in
a <span class="gbs-if-noview">...</span> and you're done. SFX will
likely preserve such <span> tags across releases since it doesn't know
what style you're applying.

If I were you, I'd probably look for a server-side solution first,
too, but let's discuss the architectural differences a bit more.

You mentioned modularity and maintainability - I'd say that a
client-side solution can be kept modular and maintainable as well - in
particular if you minimize the actual JavaScript code you embed in
your output page.

In addition, client-side has significant advantages in both latency
and scalability, in particular when mashing in data from a provider
with a distributed architecture that has a degree of redundancy, and
therefore availability, that is as high Google's.

 - Godmar