Topic: Wordpress BaseUrl Problem

I am using a wordpress site and want to use the pro tools then use the galleries through the base Url method rather than the plugin. I have been following the instructions in this post http://juicebox.net/forum/viewtopic.php?id=906but can't get anything to work. I am putting the gallery folder in the httpdocs folder on the server with a gallery folder title of jbg and using this coding in the text area not the visual. I have tried many variations to no avail. I am at a loss so here I am. Thanks for any help anyone can provide.

<!--START JUICEBOX EMBED-->
<script src="httpdocs/jbg/jbcore/juicebox.js"></script>
<script>
new juicebox({
baseUrl : "httpdocs/jbg/",
containerId : "juicebox-container",
galleryWidth: "100%",
galleryHeight: "100%",
backgroundColor: "rgba(18,18,18,1)"
});
</script>
<div id="juicebox-container"></div>
<!--END JUICEBOX EMBED-->

Re: Wordpress BaseUrl Problem

httpdocs/jbg/jbcore/juicebox.js is a server path rather than a URL (the 'httpdocs' folder is visible only to you on your web server and not to anyone else on the internet).
You can use absolute paths, in the form http://www.example.com/jbg/jbcore/juicebox.js or relative paths (relative to the page containing the gallery's embedding code).
If your 'jbg' gallery folder is in your root directory, you can use a leading slash to denote the root and use the following embedding code, e.g.:

<!--START JUICEBOX EMBED-->
<script src="/jbg/jbcore/juicebox.js"></script>
<script>
new juicebox({
baseUrl : "/jbg/",
containerId : "juicebox-container",
galleryWidth: "100%",
galleryHeight: "100%",
backgroundColor: "rgba(18,18,18,1)"
});
</script>
<div id="juicebox-container"></div>
<!--END JUICEBOX EMBED-->

Re: Wordpress BaseUrl Problem

Thanks Steven. I knew it was something frustratingly simple. My server permissions do not allow me to add or manipulate the root directory. Httpdocs was a folder it allowed me to add files to so I stuck the gallery folder in there. With it being visible only through the FTP client and not through the web I wasted a lot of time trying to link to it. I tried, as I said, many variations of the coding to attempt to access the files, the correct syntax that you sent me was one of them but still nothing, obviously.

It does not matter where on your web server you upload your gallery folder to as long as the two paths in the embedding code (the path to the 'juicebox.js' file and the baseUrl itself) are correct.

This part of the link in my original post is what threw me off. I am so new at this every time I sit down I am learning my way through it.

As soon as I can get a hold of my cousin who owns the server I will try to sort this out. If I still run in to any problems I will let you know. Thanks for replying to my post.

Re: Wordpress BaseUrl Problem

My server permissions do not allow me to add or manipulate the root directory. Httpdocs was a folder it allowed me to add files to so I stuck the gallery folder in there.

That's perfectly normal and the right thing to do.
'httpdocs' ('http:// documents') is the folder on your web server that you upload files and folder to for them to be accessible on the internet. (Some web servers name this folder 'public_html'.)
Just change your existing embedded code for the code I posted above (making no changes to it) and your gallery should display fine.

5 (edited by skater0422 2013-10-17 23:00:33)

Re: Wordpress BaseUrl Problem

Steven, you are the man. I get what you are saying now. I had never tried the path without first including /httpdocs/. Thank you very much for your help, it is working perfectly. I owe you a beer the next time you are in Baltimore.