Problems displaying expanded/collapsed sections

Skip to first unread message


Jun 29, 2012, 4:01:47 AM6/29/12
Hi there!
I'm trying to play around with example from here: 

And returning JSONP from my PHP script:

header("Content-type: text/javascript");
//Parameters in the request from Rapportive to our Raplet
$callback = isset($_GET['callback'])? $_GET['callback'] : "cb";
    "status": 200,
    "css": " { color: grey; }\n .collapsed { white-space: nowrap; overflow: hidden; }",
    "js": "$('').click(function(){ $(this).text('You clicked me!'); });",
    "sections": [
            "expanded_html": "<h2 class='name'>Rahul Vohra</h2><p>Lifetime value: $1,000,000!</p>",
            "collapsed_html": "<div class='collapsed'>$1,000,000</div>"

I've figured out that display of expanded or collapsed HTML depends on browser's viewport height and total height of Rapportive widget.
At some point I thought I broke smth. and spent a whole day trying to force Rapportive to display my collapsed version by default & expanded on hover event.
My question is as following:
  - Is there any way to force display of collapsed version only which does not depend on browser's/rapportive widget height?   

p.s. And probably you should somehow stress this thing with height behavior in your docs, because it really confuses at the beginning and may lead to huge loss of time

Gary Sherman

Nov 1, 2012, 6:56:29 PM11/1/12
I'm experiencing the same issue.
Trying to test the expanded/collapsed sections, and I can only get it to show the expanded section in the sidebar.
I haven't been able to see the collapsed section actually display.
I've tried re-sizing my browser to no avail.

Any tips of how to get it to show the collapsed section?
You mentioned the "total height of Rapportive widget". Is that of the entire sidebar? or just my raplet?
How can I adjust that?

And I have the same question as the OP:
Is there any way to force display of collapsed version only which does not depend on browser's/rapportive widget height?   


Conrad Irwin

Nov 1, 2012, 7:05:25 PM11/1/12
Hi Gary,

Thanks for getting in touch, and thanks for developing a raplet :).

The best way to force a collapsed section to show up is to find a sidebar with two expanded sections (for example, my sidebar has an expanded twitter section and an expanded membership section). Then shrink the browser window until only one is expanded.

Once you've done that, then the most recently clicked section will be expanded, and all other sections will be collapsed. So you can collapse your raplet by clicking on a different section.

Please let me know how you get on,

Developer, Rapportive.

You received this message because you are subscribed to the Google
Groups "Raplet developer discussion list" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

Gary Sherman

Nov 2, 2012, 10:39:35 AM11/2/12
Hi Conrad,

Following your suggestion, I was finally able to see the collapsed and expanded sections properly.


Reply all
Reply to author
0 new messages