Why Facebox not working on Firefox in my site

200 views
Skip to first unread message

bjoshi

unread,
Apr 30, 2012, 3:19:06 AM4/30/12
to facebox
I have added facebox to one page it is working ok in IE but not
working in Firefox and crome.

http://www.atlasconcrete.co.nz/decorative-mixes-xidc93367.html

can some one say why it is not working ?

Jean Paul Gorrichátegui

unread,
Apr 30, 2012, 8:20:03 PM4/30/12
to facebox
bjoshi,

I believe that you are trying to pull out into the facebox and entire
document, while this is not possible because of many reasons, the main
one is that actually the facebox JS creates a div that is hidden
within the same document and bringing another web document will
replace the current page. Therefore when you trigger this function,
you are appending to an existing div on that same page, so that's the
glitch that you might be facing now. If you try to load a page it will
rewrite the whole document, which is what you are experiencing with
Firefox and Google Chrome most likely. Which version of IE are you
using? I've noticed that you are using emulation for compatibility
with IE8, perhaps for some reason for that version of the IE browser
makes sense while it wouldn't be accurate for the browser to append a
document into a div in the body.. anyways, looking at one of the
trigger elements from your web site:

<a rel="facebox" href="maungaturoto-chip-16-mm-xidc96431.html">

You could enter the content of those .html pages and placed them
inside of a div with style="display:none" and trigger it instead like:

<a onclick="jQuery.facebox({ div: 'maungaturoto-chip-16-mm-
xidc96431' })" href="javascript:void(0);"> and then create a div on
that same page with the same id and styled as hidden... if you ask me,
that's too much work, but that is one option that could or could not
help for SEO, but I would advise to go for the next option.

... you could use AJAX, but I would suggest in that case to leave only
the body of your .html pages and remove the head, body and html
sections. In fact, that is one thing to be aware when re-coding that
part.. if it's styled with CSS, you might want to consider defining
these on the page that uses the facebox methods. If you are using an e-
commerce solution or a CMS, then you would need to look at the core
functions to see which one writes the creation of such links, on the
other hand if you have access to the lines where you enter the a
rel="facebox", then it should be not so difficult:

For example:

<a onclick="jQuery.facebox({ ajax: 'maungaturoto-chip-16-mm-
xidc96431.html' })" href="javascript:void(0);">

Please give it a try, and let me know if that worked for you ;)

JP-

bjoshi

unread,
May 1, 2012, 2:57:48 AM5/1/12
to facebox
Thanks Jean Paul,

It works ! i have called all content in div with in page and with
display none.

- bjoshi

On May 1, 5:20 am, Jean Paul Gorrichátegui

Helen

unread,
Aug 30, 2012, 3:17:00 AM8/30/12
to fac...@googlegroups.com
The aJax way is not working! I just tested with Firefox 14.0.1
Reply all
Reply to author
Forward
0 new messages