[FredLug] Needing how-to for placing a Drupal block into a node

Isaac Christoffersen isaac.christoffersen at gmail.com
Mon Nov 22 08:07:32 EST 2010


You only need ftp access to upload modules to your hosted drupal instance.
Just upload them to the sites/all/modules directory.
On Nov 22, 2010 7:43 AM, "Mark Walker" <marwalk at gmail.com> wrote:
> I've been reading volumes of forum posts since checking into Panels,
> CCK & Views (all powerful options). It turns out that my hosting
> provider cannot give me those modules, and root shell doesn't come
> with the level of shared server I have with them (so I can't install
> the modules myself). I wonder if even the php snippets need Views to
> call views in them. It might be that for what I want to do I'll have
> to look elsewhere for hosting, or suck it up for a service upgrade.
> Still researching the ins and outs of all this.
>
> I'm fascinated with Drupal, however. I think that community actually
> "gets it" about CMS.
>
> Mark
>
>
> On Sun, Nov 21, 2010 at 4:02 PM, Ted Brunell <ted.brunell at gmail.com>
wrote:
>> Mark,
>> Have you seen the Panels module?  It may provide the functionality that
you
>> want.
>> You can use CCK & Views to create some custom blocks and assign them to
>> regions on the page too.
>> R/
>> Ted
>>
>> On Sun, Nov 21, 2010 at 3:57 PM, Mark Walker <marwalk at gmail.com> wrote:
>>>
>>> There are a lot of forum posts asking this question, but all the
>>> replies have been of limited practical value.  Any ideas on tweaks for
>>> this specific Drupal example?  I'll be more than happy to share your
>>> solutions on Drupal.org. :-)
>>>
>>> The forums say there used to be a module for this, but it's not
>>> available anymore.  So the way to embed a block inside a node is to
>>> include a php snippet in the body of the node.  You get the block
>>> address from the browser address when you click "configure" on a block
>>> in admin mode.  You then take that information and use it for a php
>>> snippet in the body of a node to embed that block in that node. I
>>> think I'm getting the syntax wrong or calling the wrong arguments in
>>> my snippet, as when all the changes are saved the node body just
>>> displays the code itself as text and not the block.
>>>
>>> Here's an example block address from one of the configure links (all
>>> after the domain name):
>>> ?q=admin/build/block/configure/aggregator/category-4
>>>
>>> Here's an example of the code I've tried in the body of a Story node:
>>> <?php
>>> $block = module_invoke('block', 'block', 'view', category-4);
>>> print $block['content'];
>>> ?>
>>>
>>> Only the straight php code shows and not the block content in the
>>> Story body. I'm using Drupal 6. Please tell me what I need to tweak.
>>>
>>> Thanks,
>>> Mark
>>>
>>> Mark Caldwell Walker
>>> Contact info at marwalk.tel
>>> GnuPG public key AA482E46
>>> _______________________________________________
>>> FredLug mailing list
>>> FredLug at calypso.tux.org
>>> http://calypso.tux.org/mailman/listinfo/fredlug
>>
>>
> _______________________________________________
> FredLug mailing list
> FredLug at calypso.tux.org
> http://calypso.tux.org/mailman/listinfo/fredlug
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://calypso.tux.org/pipermail/fredlug/attachments/20101122/257e0771/attachment.html 


More information about the FredLug mailing list