Ask questions and get good answers on mb.jQuery.components

Hi.

I'm building a site for a new Italian museum (sorry, it's not on a public IP, yet). For the kiosks on the floors I've been asked to build a page with the map of the floor, and a list of all authors (≈500) and all the works (≈1000). I choose to use mbExtruder, to be able to open the menu (hiding part of the map) only on user request, and in a sleek way ;-). So far so good. For each author I build a "voice", this way:

<div class="voice {panel:'works.php?author=${author_id}'}"><a onclick="$('#label').attr('src', 'label.php');"><span class="label">${author_forename} ${author_surname}</span></a></div>

I would expect url "works.php?author=${author_id}" to be called when user opens an extruder panel voice; instead it's called when main page loads, causing ≈500 POST (or GET) calls, which freezes the browser for ≈15 seconds ("works.php" is currently empty), even firing a "script timeout" warning. Of course when there are only 5-10 panel voices (as in your demo page), you don't even notice the problem; but when you have 500 panel voices you do notice it... Is this behaviour by design or can it be classified as an anomaly? Is there something I can do to bypass this issue?

Thanks in advance for your attention.

Marco

asked Oct 13 '10 at 05:37

marcolino's gravatar image

marcolino
112


The first level of the extruder voices are evaluated on page load, the other panels are called once a voice is clicked. Actually this is the behaviour; anyway you'll have the same problem loading 500 and more voices on extruder open event... You should maybe think to load fiew voices introducing a more button for example...

answered Oct 13 '10 at 18:41

Matteo%20Bicocchi's gravatar image

Matteo Bicocchi ♦♦
1776129

Hi, Matteo, you are right... ;-) I did not think to a "more..." button, I will implement it for sure. Thanks again.

answered Oct 14 '10 at 03:36

marcolino's gravatar image

marcolino
112

Hi again... I did check again the behaviour of mbExtruder, and in effect I see it does evaluate the second level voices, too... I probably did not correctly explain the problem on my first post ... On the onload stage, I see 500 calls to the url "works.php", which implements the second level... I would expect the second level urls to be alled when user opens a voice panel.... Calling second level urls on the onload stage would be correct just for "accordion" panels, I suppose...

answered Oct 14 '10 at 04:24

marcolino's gravatar image

marcolino
112

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Tags:

×11
×3
×1
×1
×1

Asked: Oct 13 '10 at 05:37

Seen: 646 times

Last updated: Oct 14 '10 at 04:24

jQuery main site - Matteo Bicocchi