Great tool!
I just downloaded the latest version and it seems to be giving me a hard time.
I am using XAJAX and a hidden div with a call to loadanchor. Life is good until the floatbox is closed.
At that point my page content has been shifted up to the top of the window and no amount of cohersion will restore it.
Ideas?
Thanks,
Ed
Page shifting
Page: 1
Author | Post |
---|---|
#1 Wed Apr 15, 2009 3:24 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
|
#2 Wed Apr 15, 2009 4:54 pm
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
No idea. Got a link where I can peer into this behaviour a little closer?
I don't think there's anything in floatbox that can shift your page on close (but I've been wrong before). Can you work around it by setting an afterBoxEnd action with a scrollTo() command to put the page where you want it? Or perhaps a named anchor or id on the page and a loadPageOnClose setting using that #name? |
#3 Wed Apr 15, 2009 7:32 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
Thanks for the quick reply.
Cant supply a link as it is all in development. I'll try scrollTo() but I don't hold much hope... |
#4 Wed Apr 15, 2009 7:57 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
loadPageOnClose:self works but itseems a bit of a hack...
Ed |
#5 Wed Apr 15, 2009 8:57 pm
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
Agreed. But without a page to look at, it's the best I can come up with for you. I've never seen this behaviour nor heard of anyone else experiencing it.
|
#6 Thu Apr 16, 2009 1:50 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
Another insight: It only seems to happen with IE. FF wirks file...
|
#7 Thu Apr 16, 2009 2:17 pm
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
Any chance the link that invokes loadAnchor has an href of "#" and does not have "return false;" after onclick's loadAnchor call?
|
#8 Thu Apr 16, 2009 4:56 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
The loadAnchor call is made by scripting from a php page using XAJAX.
Here's the code:
|
#9 Thu Apr 16, 2009 5:29 pm
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
I doubt this causes your scroll problem, but your loadAnchor call as quoted is whack. The parameters are just strings, so the "rev=" and "title=" portion of the 2nd and 3rd parameters needs to go. I'm surprised it would even work as quoted.
|
#10 Thu Apr 16, 2009 5:42 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
The loadAnchor call is a parameter to the script() function. It has single quotes around it and double quotes within. The script() function causes the passed string to be executed as JS when it reaches the browser.
Works great |
#11 Thu Apr 16, 2009 5:49 pm
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
No no. You misunderstand me.
fb.loadAnchor("#fbdiv", rev="width:900 height:500 scrolling:auto loadPageOnClose:self", title="Account Details - Press Esc or Click Close to Return" ) ...should be... fb.loadAnchor("#fbdiv", "width:900 height:500 scrolling:auto loadPageOnClose:self", "Account Details - Press Esc or Click Close to Return" ) I can see how it would work fine though. In your mistaken syntax, you are assigning a string to the global var rev and to the global var title and returning the results of those assignments as parameters to loadAnchor. What you mean to do is to just pass the strings, so for cleanliness' sake, delete the rev= and title= bits. |
#12 Thu Apr 16, 2009 7:53 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
Did that. Works fine but the problem still exists.
I have a lot of CSS of my own in the pages. perhaps it's one of those. |
#13 Thu Apr 16, 2009 8:06 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
Well I found it....
Now all is well with the world! Thanks for your help and a very nice tool. Ed |
#14 Thu Apr 16, 2009 8:27 pm
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
Oh no. You don't want to do that. In floatbox, ieOld is defined as version 6 or earlier. The change you made will cause floatbox to not recognize IE6 as old, and will not run the code needed to make it behave. Your IE6 site visitors will get bad rendering of shadows, will try to load round corners and mess up the box layout, the semi-opaque overlay will not grow with a browser window resize, any select elements on the base page will bleed through floatbox, might get weird jpg fade in/out artifacts, and will probably get some bad control positioning if you move the controls around.
But your experiment could help narrow down the problem. Now I assume when you say it happens only in IE, that you are testing with IE6. And if that change got rid of the scroll problem, then it must be something in the IE6-specific helper code. Damn I wish you could provide a link instead of this endless conjecturing with the lights out. |
#15 Thu Apr 16, 2009 8:41 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
!@#$%. I changed it back to 7 and the problem went away.
Arrrrrrgh |
#16 Thu Apr 16, 2009 9:10 pm
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
Well, that's good, right?
|
#17 Thu Apr 16, 2009 11:50 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
That's good
I think it might be a cache issue. I'll tryit tomorrow and let you know. Ed |
#18 Fri Apr 17, 2009 3:27 pm
|
|
Member
Registered: Apr 2009
Posts: 30
|
Couldn't reproduce the problem.
Write it off to bad carma. Have another issue at the moment: I use FB to display help pages. The pages contain html/plain text and get loaded into a hidden div tag and are displayed using loadAnchor(). The problem is that they are all displaying the content centered in the FB window. If I unhide the hidden div, the text is aligned normally. Any thoughts? Ed |
#19 Sat Apr 18, 2009 2:26 am
|
|
Administrator
Registered: Aug 2008
Posts: 3382
|
Oh man, you're trying to get me to go down another rabbit hole of guessing what might be going on without seeing anything. Are you sure you can't post an unlinked sample up on your web server somewhere that I can look at? Are you really really sure you can't do that?
I would think that the only reason why your text might be centered is that something told it to be centered. You could take a look in firebug after the floatbox with the centered content is open, navigate through the html in firebug to find your content, and then check out the styles in effect for that content. That should tell you where the centering is coming from. |
Page: 1