PDA


View Full Version : Contents Page Misaligned


cap97
05-04-2005, 06:58 PM
Trying to get a custom page to work. So here's what I did:

1) Created a php file called "test.php" in the modules directory with the following code:


<table align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" class="tborder"
width="100%">
<tr>
<td class="tcat"><span class="smallfont"><strong>$vba_options[portal_blockbullet] <!-- Module Title Here --
></strong></span></td>
</tr>
<tr>
<td class="$getbgrow" width="100%">

<!-- Content for your module goes here -->

Hey how come this doesn't work?

</td>
</tr>
</table>
<br />


2) Added a new module in admin called "Test" using said file "test.php".
3) Created a new page in admin called "Test" and set it to display left and right modules, as well as the new "Test" module.

This is the result: http://livinglegend.org/startrek/?page=test

As you can see, the new page is being displayed above everything else. And the variables aren't showing up either (although since test.php isn't wrapped in php tags, I don't see why they would, but I got the code from the instructions). Any thoughts?

Brian
05-04-2005, 08:50 PM
You can't use HTML in a PHP file like that. You need to create a new template with the HTML and then either add a new module including that template, or specify that template name in the 'Page Template' option of your page.

cap97
05-05-2005, 07:21 PM
And where am I saving these template files? Any examples I can look at to better understand what you're trying to have me do?

Brian
05-06-2005, 01:23 AM
http://www.vbadvanced.com/membersarea.php?do=viewusermanual&productid=4&pageid=2

cap97
05-06-2005, 01:38 PM
Yeah I read that already. That's how I got where I'm already at. But that doesn't tell me where to save these templates files either, or what they're supposed to look like or how they work.

Brian
05-06-2005, 01:41 PM
Did you read over the "Adding Modules - Quick Examples" section? It should be pretty simple if you just follow the instructions there.

cap97
05-06-2005, 04:22 PM
Gah. Apparently I'm more simple than the simple instructions. My bad. Thanks for the help!