Support Spidean

Do you like our FREE downloads? How about the FREE support for the FREE downloads? Please help us out and donate any amount! It's fast and easy through PayPal.

Spidean Forums

Board Index > Support (.87) > custom block does not display, omitted from render


 < Last Thread   Next Thread >New Topic  Post Reply
Author: Subject: custom block does not display, omitted from render

Newbie





Posts: 4
Registered: 11/6/2005
Status: Offline

  posted on 11/6/2005 at 10:12 PM
PN 0.760, AT 0.851
Linux Redhat Fedora, MySQL/php
ISP: godaddy.com
Site: www.atlalabs.com (warning: it's ugly right now, stuck halfway between AT stock and my content)

I'm new to PN/AT, but not to web programming. I've spent four hours with the FAQ/UG and searching this forum specifically on this problem. I apologize if I'm posting a redundant problem (just show me the tutorial link and I'll leave in peace <grin>.

Fundamentally, I think I have a few knowledge gaps:
1.) I do not understand how AT blocks override/supplement/replace standard blocks. Is this interaction causing problems (my stock blocks modules is still activated)?
2.) I do not understand how modules, content, and blocks interact at the code level. Are blocks just includes? and merely serve as wrappers for the modules?
3.) I do not understand the difference between modules and pages. Essentially, PN/AT terminology seems either to be inconsistent or just cryptic, or I'm just ASU (another stupid user <grin>.

Enough disclaimer, on to the scenario:

I'm trying to display a custom block with static content at the top of my page. My homepage begins with the News module according to the settings admin module.

My procedure:
AT->Themes->AT_Atlalabs->Block Areas:
Left, Right, Center, top_content_bar
AT->Themes->AT_Atlalabs->Theme Defaults:
Page template = theme.html
top_content_bar Blocks = top_nav_banner.html // Show? Yes.
AT->Themes->AT_Atlalabs->Custom Pages->*Homepage:
Page template = theme.html
top_content_bar Blocks = top_nav_banner.html // Show? Yes.

I've pasted the relevant parts of the theme files below for your reference. I've referenced the block everyway I could think of (in case you're wondering why there are a bunch of block references to the same block there).

None of these approaches appear to work. The block contents (the test message and horizontal rule) do not show. Even more interesting is that the block references (despite debugging being turned on) do not show up in the page source as seen by the browser. It's as if pnRender understands them, but doesn't know what to do with them so it just strips them from the output(???).

ANY HELP WOULD BE GREATLY APPRECIATED! Thank you very much.

Warm regards,
-Jonathan

[partial contents of file: theme.html]
<html>
<head>
<!-- Note to Self: HEAD CONTENT IS STRIPPED OUT BY AUTOTHEME AND REPLACED WITH THE DEFAULT HEAD CONTENT -->
</head>
<body text="#000000" vLink="#333333" aLink="#999999" link="#666666" bgColor="#ffffff" leftMargin="0" topMargin="0" rightMargin="0" marginheight="0" marginwidth="0">
<!-- [public-messages] -->
<!-- [user-login] -->
<!-- [top_content_bar-blocks] -->
<!-- [top_content_bar] -->
<!-- [autoblock1-blocks] -->

[contents of file: top_nav_banner.html]
<!-- THIS IS THE TOP NAVIGATION BANNER, IN STATIC HTML -->
<hr>
inside the top_nav_banner


 
Reply With Quote Visit User's Homepage

Newbie




Posts: 4
Registered: 5/28/2003
Status: Offline

  posted on 11/13/2005 at 04:31 AM
Jonathan,
How are you doing with this?

Most of your confusion actually seems to be about the way postnuke works...
*AT controls standard blocks, doesn't override/supplement/replace
*Content is the stuff you type.
*Modules are scripts within postnuke that do something (AT is a module) - a FAQ or a forum or a static content manager - are all modules.
*Blocks are specific snippets of output (from modules or other sources) which can be shown irregardless of the module you are looking at. AT's block controls are for fine control over which blocks are shown where and when.
Pages are formatted output from a module. each module will have one or more pages of output.

If you need help with the specifics still, reply here and I will take a look at it...
Laurie

 
Reply With Quote

Newbie




Posts: 4
Registered: 11/6/2005
Status: Offline

  posted on 11/13/2005 at 02:01 PM
Thank you Laurie for your kind reply. Yeah, you are right. I kind of figured that was my problem so I began digging inside the PostNuke codebase and getting a better feel for things.

The core problem with my work was that while I created the block template code, I did not create an actual block that uses the template. As I now understand it PN works with the following wrapper structure:

Page template (locates the blocks)
Block template (formats the block)
Block contents (contents of the block, could also format the block if custom HTML/PHP)

To get my static code to appear, I had to create an HTML block, with nothing in it, that used my block template (that had the static HTML). Then everything checked out A-OK.

Thanks again!

Warm regards,
-Jonathan

 
Reply With Quote

Newbie




Posts: 4
Registered: 5/28/2003
Status: Offline

  posted on 11/14/2005 at 04:55 PM
Jonathan,
Just as an idea:
you mentioned making a blank html block to show your html code as formatted in your block template... I do it the oposite way... I make a "blank" box ( an html file with only one line:
<!-- [block-content] -->
I then make an html block and put all of the html code in there.
Works better for some uses, makes changes easier to apply and can be used for other blocks besides html when you don't want the title to show.
Best of luck,
Laurie

 
Reply With Quote
New Topic    Post Reply


Main Menu

Get AutoTheme

Featured Item

Poll

How do you like the new look?

[ Results | Polls ]

Votes: 103
Comments: 0

Powered by the AutoTheme HTML Theme System
Page created in 0.121325 Seconds