Re: Embedding Simpleviewer

Hello all,

As this is my first post on this forum I'd like to thank all the people above me for their guidance. I have had lots of useful input and have improved my simpleviewer a lot already. However I still have the issue that dreamweaver CS4 shows my pictures, while IE / Firefox do not.
I have read on several websites that Dreamweaver has trouble using the SWFObject.swf. And that you have to use a specific script in the <head> section. Well take a look below as I described my situation. And thanks in advance!


I am building a website and want to embed simpleviewer to a certain page. However I will use multiple simpleviewers on my website eventually (as photographer I will have 3-4 categories that are shown seperately) and thus put each gallery in a different folder for clarity.

Using Photoshop CS4 to make my gallery, I also get an index with the following script:

<script type="text/javascript" src="Mensen/swfobject.js"></script>
        <script type="text/javascript">
            var flashvars = {};
            flashvars.galleryURL = "Mensen/gallery.xml";
            //flashvars.firstImageIndex = "0";
            //flashvars.preloaderColor = "#FFFFFF";
            var params = {};
            params.allowfullscreen = true;
            params.allowscriptaccess = "always";
            params.bgcolor = "000";
            swfobject.embedSWF("Mensen/simpleviewer.swf", "flashContent", "100%", "100%", "9.0.124", false, flashvars, params);
        </script>

As you can see I already adjusted the link of the swfobject.js, the gallery.xml and the simpleviewer.swf to the correct directory "Mensen/" (Dutch for people). Using this script in the <Head> section combined with the <div id="flashContent"> in the <body> section I can view the simpleviewer in Dreamweaver fine [using 'liveview'].
However, when I use a browser to view the website the area of the simpleviewer is empty. Only the background shows.


Now I've read on multiple fora and websites that to embed correct I should use the following script:

<script type="text/javascript"  src="Mensen/swfobject.js"></script>
        <script type="text/javascript">
            var fo = new SWFObject("Mensen.simpleviewer.swf", "viewer", "800", "600", "8", "#181818");       
            fo.addVariable("xmlDataPath", "Mensen/gallery.xml");
            fo.write("flashContent");   
        </script>

Similar to the first script, I've already adjusted the references.  (again using the div flashContent)

Now I would expect that the 2nd script would work as well, but it does not. Not even in Dreamweaver I get to see the simpleviewer.


Am I missing something here?


As I am still building my website I do not have bought space to put things on. If complete code is required, please let me know and i'll [quote/ it for you.

Thanks in advance and my apology for necromancing this topic back to life, but it fits my problem perfectly.


Greetz,

Oliver

Re: Embedding Simpleviewer

The first embed code is for SimpleViewer 2.x and the second is for SimpleViewer 1.x, so you need to know which version you are using. Is the page you are having trouble with online so I can take a look?

Mike Richards
SimpleViewer Support Team.

Re: Embedding Simpleviewer

Dear Mike,

Thanks for your response. I am currently using v2.
Unfortunately I haven't bought any webspace yet as I thought I'd take a while building a website offline. I can attach/copy the code if you prefer?

Currently I have the following results:
Directories:
Main
-Profile
--Section1
--Section2
--Section3
--Section4

Each section will have its own simpleviewer and own photo's.
-Simpleviewer created through Photoshop.
All photo's have been correctly placed in simpleviewer and the created index.html works perfectly in my browsers.

-Whole content is put in their own section
Similar to the FAQ on SV I use "Profile" page to direct people to four different simpleviewers. However the link is not purely SV but also contains texts and other stuff. There lies my problem

If I direct the links in my profile to (for example) Section1/index.html
I would direct people to a page only showing SV with the right photo's
Therefore I direct them to: Section1/ProfileSection1.html
That page contains the first Quote (in the head) of my first post as well as the DIV (in the body). The SV opens perfectly in Dreamweaver live view, yet browsers do not seem to understand what is required of them and the whole page is loaded except the SV part.


I hope you understand what I mean, and if I can do anything to further clarify. Please don't hesitate to ask!

Oliver

Re: Embedding Simpleviewer

I've bought some website room and put it online.
Not figured out yet how I can upload all files/images/folders automatically, so not uploaded all stuff yet.

Please check out: www.foto-dag.nl

I have a simpleviewer active in the Portfolio > Animal section  (the prairedog picture).
www.foto-dag.nl/portfolio/PortfolioDieren.html is the correct links, but no SV seems to be active
www.foto-dag.nl/portfolio/index.html is placed online, but only to show you that SV works with that code.

However, index.html is a page on its own and I want it placed within my normal lay out (portfolioDieren.html)

Hope this helps, and thanks for the effort!


Oliver

Re: Embedding Simpleviewer

Took a look at your pages you need to remove the #000000 from swfobject.embedSWF("simpleviewer.swf", "flashContent", "100%", "100%", "9.0.124", false, flashvars, params, #000000);

In the past there have been some issues with SpryMenuBar.js and SWFObject conflicting so I would keep an eye out for that.

Also for firefox you should add the css code below.

 html, body    { height:100%; }
Mike Richards
SimpleViewer Support Team.

Re: Embedding Simpleviewer

HELP!!! Isn't there a short cut video that can be viewed to show how the embedding process is done. I've created my gallery and would like to add it to my web site, but I'm having problems with the process. I've read through the forums and there is something I am missing. Is there a way to hyper link this to my site?

Re: Embedding Simpleviewer

@dhamptonjr

The SimpleViewer Embedding Guide can be found here: http://simpleviewer.net/simpleviewer/su … dding.html

Is there a way to hyper link this to my site?

If you wish to link to a gallery from a page in your web site, you could upload your entire gallery folder to your web server and use an HTML hyperlink pointing to the gallery's HTML index page, eg:

<a href="galleryfolder/index.html">Click here to view gallery</a>

If you wish to embed a gallery into an existing page in your web site alonside other content, you could upload your entire gallery folder to your web server and use an <iframe> to load the gallery's HTML index page, eg:

<iframe src="galleryfolder/index" width="800" height="600" frameborder="0" scrolling="no"></iframe>
Steven Speirs
SimpleViewer Support Team