Since thinking about the idea of breaking off the block serving portion into a separate submodule, I have been wondering how much of this whole module could work on top of Services module.

I don't remember if there's a blocks service already, but if not, the block serving module would be a fairly slim to write as a service.

Comments

tamasd’s picture

The problem is that this module works with ajax on the client side (by design). This is a bit similar concept like bigpipe (how facebook works).

This is good, because the host site does not need to render the block (only a really small one, which will be replaced with an JSONP-based AJAX call). It can come handy on a completely AJAX-ed site.

If I make it work with services, I will lose the advantage of this module.

Your idea is not bad, but it is out of the scope of this module, I think.

joachim’s picture

Services can just as easily return HTML suitable for AJAX, can't it?

tamasd’s picture

It is theoretically possible, but the problem is the same origin policy, which really limits the usage of this feature.

That is why this module uses jsonp, which is a limited workaround on this problem.

What could be a possible solution is to ship a proxy script, but I am not sure if it a good idea.

tamasd’s picture

Status: Active » Closed (won't fix)