Passing arguments via URL when using HDViewSL RRS feed

All replies

  • Thanks Eric for pointing out to me the following: (main problem now solved - still thinking about the Save specific View Button)

    Take a look at the page source… this is the javascript that's causing trouble for you:


        <script type="text/javascript">

            var args;

            if ( top.location.search == "" )  {

                args = 'FileName=#hdvxmlembed&BackgroundColor=0&Viewer=1';


            else {

                args = top.location.search.substring(1);


            hdv = new hdvHost("hdvControl", "hdvDiv", "100%", "100%", top.location.href, args);


    The highlighted lines cause everything after the "?" in the current location URL to be passed to the hdvHost script that creates the HD View SL object.  That's what enables the link given in the "Save Specific View" dialog to work.  It looks like you don't want that to happen – instead you want HD View SL to always use the embedded XML to define the source of the image.  You should get what you want if you take out the highlighted lines and leave the rest.  In that case, I'd recommend removing the "Save Specific View" button as well.

     If you want to keep the "Save Specific View" functionality and pass other parameters in the location URL, you'll have to do some work to combine HD View SL's parameters with your new parameters in any URL you give to the user.  I can give suggestions, if that's what you want.

    Wednesday, July 22, 2009 10:21 PM