Sym Paradise
The Boxes Paradise
Home
  • My Menu
    • Log In
  • Contents
    • Discussion
    • Help
      • User Help
        • Installation
        • Others
      • Developer Help
        • Drupal
        • Others
      • Box Request
  • Library
    • Main Library
    • Search Boxes
  • Handbooks
    • User Handbook
    • Developer Handbook
    • Using This Site

TBP for nice-menus?

kpchiao
28th Nov 2010, 12:02:41 PM
Tags:
  • User Help

Is it possible to use TBP boxes on blocks of nice-menus for Drupal?

  • Login or register to post comments
  • 1076 reads
Share

Congratulations!

6th Dec 2010, 10:55:00 PM

Wow!

Great to hear that you have gotten it to work! Happy theming!

Cheers!

TBP
  • Login or register to post comments

It works!

6th Dec 2010, 05:43:37 PM

Because I also use Nice Menus to create menus, the block ids are different from the default ones.

For example, the .tpl.php file names for theming block are block-nice_menus_1.tpl.php, block-nice_menus_2.tpl.php ... etc.

kpchiao
  • Login or register to post comments

Block Theming

5th Dec 2010, 05:28:00 PM

Hi,

What you want to achieve is to actually theme a block.

You will need to copy the block.tpl.php into your theme's directory, and edit this block. An example of what this block can have is this:

<?php
// $Id: block.tpl.php,v 1.2 2007/08/07 08:39:36 goba Exp $
?>

<div class="<?php print "block block-$block->module" ?>" 
  id="<?php print "block-$block->module-$block->delta"; ?>">
 <script type="text/javascript" src="http://theboxes.paradise.sg/sites/theboxes.paradise.sg/
   files/Box/3/files/theboxesparadise_3.js">
 </script>
 <script type="text/javascript"> tbp_3_getHeader(); </script>
 <script type="text/javascript"> tbp_3_getStartTitle(); </script>
   <h3><?php print $block->subject ?></h3>
 <script type="text/javascript"> tbp_3_getMid(); </script>
   <?php print $block->content ?>
  <script type="text/javascript"> tbp_3_getEnd(); </script>
</div>

Note that this will theme all blocks to use this TBP box. If you want just a specific block that contains this menu, you have to know this block's ID, and your template file should have one of these filenames - block-block-1.tpl.php, block-block-2.tpl.php, depending on what ID is the block. Important: the default block.tpl.php must be there as well even if you are using a block-block-1.tpl.php

TBP
  • Login or register to post comments

I need another solution.

5th Dec 2010, 04:18:59 PM

Thanks for your quick response, however, that is not what I meant by.

The code you provided is for creating a node or page rather than for a default menu or block in Drupal. What I need is to use the default process to create a menu and then put it inside a block, which is to be placed in the right or left column of a theme.  I want such block to be embedded inside a centain TBP box. But it seems to me there is no way to put the TBP codes while the block are been building in Drupal.

kpchiao
  • Login or register to post comments

This is an example

4th Dec 2010, 11:44:00 PM

Hi,

<script type="text/javascript"
    src="http://theboxes.paradise.sg/sites/theboxes.paradise.sg/
            files/Box/3/files/theboxesparadise_3.js">
</script>
<script type="text/javascript"> tbp_3_getHeader(); </script>  
<script type="text/javascript"> tbp_3_getStartTitle(); </script>
Box's title goes here.
<script type="text/javascript"> tbp_3_getMid(); </script>
Your menu code can be put in here.
<script type="text/javascript"> tbp_3_getEnd(); </script>


 

You can find out more here as well for using different boxes.

TBP
  • Login or register to post comments

How to do

4th Dec 2010, 02:11:00 PM

But I don't know how to do that. My drupal is version 6.

Could you show me how to put a menu inside a TBP box?

kpchiao
  • Login or register to post comments

TBP as Wrapper?

3rd Dec 2010, 06:17:00 AM

Hi,

Do you mean to say that the menu is inside a TBP Box?

If so, the answer is Yes. You can put the menu in the contents part of the Box.

TBP
  • Login or register to post comments

Box Usage Statistics

Box Countersort icon
TBP 16 150514
TBP 50 120877
TBP 66 99313
TBP 36 89673
TBP 83 54162

Popular Boxes

  • TBP 72 (5,014)
  • TBP 66 (4,698)
  • TBP 3 (3,632)
  • TBP 71 (3,468)
  • TBP 30 (3,446)

Recent Box Requests

  • Blue response box
  • slightly embossed box that can be color filled to reqs
  • Panels 3 - Nice normal box
  • 3D Box, Bevel, Aqua-like

Recent Developer Help Posts

  • I have been unsuccessfully trying to create my client's design of a highly stylized box in Drupal 6 using Panels 3.

Recent User Help Posts

  • TBP for nice-menus?
  • Page load time
  • Where to put table when creating 3 boxes
  • print box for each content posted
  • $idstr empty?
  • Box Sizes
  • Can't find Javascript code on download
  • Panels 3
  • Can I customize the font or color, of the title and the contents inside the Box?
  • How can I embed a TBP Box on my web page?

User login

  • Create new account
  • Request new password
Copyright © 2009 Sym Paradise. All rights reserved. Terms of Use | Copyright Information