Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Themes
Author Message
DaveTomneyUK
Hangin' Around



Joined: Sep 27, 2003
Posts: 49

PostPosted: Tue Dec 07, 2004 5:48 pm Reply with quote

Hi,

Im using the DarkX theme and wondering if anyone knows how to get it so when I put a center block on my site above the "Stories" the center blocks match my left and right block theme layout.

As my current one the left, right blocks and stories have images at the top and bottom of the blocks but the center blocks have no images at the top and bottom and they look boring.

Any ideas?
 
View user's profile Send private message
jaded
Theme Guru



Joined: Nov 01, 2003
Posts: 1006

PostPosted: Wed Dec 08, 2004 11:02 am Reply with quote

The best way that I know how to answer this is to show you a working example of a theme that you CAN download and play with. You can download the 3d-fantasy theme and play around with it until you understand.
You need to worry about the tables.php file. That is what controls the look of your tables which encompasses the messages, center blocks, and background of the modules pages. Here is what the table.php looks like from that theme. You will notice all of the images that are being called in this file. That is what makes up the image borders of the tables instead of just having a css border on those things.
Code:
<?php


function OpenTable() {
    echo "<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\"><tr>
    <td width=\"15\" height=\"15\"><img src=\"themes/3D-Fantasy/images/up-left2.gif\" alt=\"\" border=\"0\"></td>
    <td background=\"themes/3D-Fantasy/images/up2.gif\" align=\"center\" width=\"100%\" height=\"15\">&nbsp;</td>
    <td><img src=\"themes/3D-Fantasy/images/up-right2.gif\" width=\"15\" height=\"15\" alt=\"\" border=\"0\"></td></tr>
    <tr>
    <td background=\"themes/3D-Fantasy/images/left2.gif\" width=\"15\">&nbsp;</td>
    <td bgcolor=\"ffffff\" width=\"100%\">";
}

function OpenTable2() {

    echo "<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\"><tr>
    <td width=\"15\" height=\"15\"><img src=\"themes/3D-Fantasy/images/up-left2.gif\" alt=\"\" border=\"0\"></td>
    <td background=\"themes/3D-Fantasy/images/up2.gif\" align=\"center\" height=\"15\">&nbsp;</td>
    <td><img src=\"themes/3D-Fantasy/images/up-right2.gif\" width=\"15\" height=\"15\" alt=\"\" border=\"0\"></td></tr>
    <tr>
    <td background=\"themes/3D-Fantasy/images/left2.gif\" width=\"15\">&nbsp;</td>
    <td bgcolor=\"ffffff\">";
}
   
function CloseTable() {
    echo "</td>
    <td background=\"themes/3D-Fantasy/images/right2.gif\">&nbsp;</td></tr>
    <tr>
    <td width=\"15\" height=\"15\"><img src=\"themes/3D-Fantasy/images/down-left2.gif\" alt=\"\" border=\"0\"></td>
    <td background=\"themes/3D-Fantasy/images/down2.gif\" align=\"center\" height=\"15\">&nbsp;</td>
    <td><img src=\"themes/3D-Fantasy/images/down-right2.gif\" width=\"15\" height=\"15\" alt=\"\" border=\"0\"></td></tr>
    </td></tr></table>
    <br>";
}

function CloseTable2() {
    echo "</td>
    <td background=\"themes/3D-Fantasy/images/right2.gif\">&nbsp;</td></tr>
    <tr>
    <td width=\"15\" height=\"15\"><img src=\"themes/3D-Fantasy/images/down-left2.gif\" alt=\"\" border=\"0\"></td>
    <td background=\"themes/3D-Fantasy/images/down2.gif\" align=\"center\" height=\"15\">&nbsp;</td>
    <td><img src=\"themes/3D-Fantasy/images/down-right2.gif\" width=\"15\" height=\"15\" alt=\"\" border=\"0\"></td></tr>
    </td></tr></table>
    <br>";
}

?>


Good Luck to you. I am sure with this working example you will be able to achieve the effect you are looking for.

_________________
Themes BB Skins [ Only registered users can see links on this board! Get registered or login! ]
Graphic Tees [ Only registered users can see links on this board! Get registered or login! ]
Paranormal Tees [ Only registered users can see links on this board! Get registered or login! ]
Ghost Stories & More [ Only registered users can see links on this board! Get registered or login! ] 
View user's profile Send private message Visit poster's website
DaveTomneyUK







PostPosted: Wed Dec 08, 2004 12:43 pm Reply with quote

Thankyou so much it works great now but if I make a block in the center how could I give it a name like you do with normal blocks if I put a $title it shows as $title and not what I give it in the admin blocks panel?
 
jaded







PostPosted: Wed Dec 08, 2004 2:26 pm Reply with quote

I am not sure that I follow you. When you create a new block in your blocks admin you name it there. Am I misunderstanding you? Can you put one up on your site for an example that I can see as an unregisterd user?
 
DaveTomneyUK







PostPosted: Wed Dec 08, 2004 2:41 pm Reply with quote

I cant show the link to my site yet as im testing it on my localhost and its not online yet but I can post a picture of it on my other site the picture is located here.

As you can see No1 I have circled showing "$title" and im wanting it to show the block name I put in my blocks admin like it does on the right block No2 I have circled "Surveys"
 
jaded







PostPosted: Wed Dec 08, 2004 2:46 pm Reply with quote

lmao@ "I want a fat babe" ROTFL

anyway.. post here for me the tables.php you are using for this theme that is giving you an error
 
DaveTomneyUK







PostPosted: Wed Dec 08, 2004 2:51 pm Reply with quote

The tables are located inside the theme.php there here:

Code:


   function OpenTable() {
<table border="0" cellpadding="0" cellspacing="0" width="100%">
  <tr>
   <td><img src="themes/DarkX/images/stl.gif" width="24" height="33" border="0" alt=""></td>
   <td width="100%" background="themes/DarkX/images/sbg.gif"><font class=content>&nbsp;<b>$title</b></font><img name="sbg" src="themes/DarkX/images/spacer.gif" width="1" height="1" border="0" alt=""></td>
<td><img src="themes/DarkX/images/srt.gif" width="62" height="33" border="0" alt=""></td>
</tr></table>
<table border="0" cellpadding="0" cellspacing="0" width="100%">
  <tr>
   <td><img name="stlc" src="themes/DarkX/images/stlc.gif" width="5" height="10" border="0" alt=""></td>
   <td width="100%" background="themes/DarkX/images/stm.gif"><img name="stm" src="themes/DarkX/images/spacer.gif" width="1" height="1" border="0" alt=""></td>
   <td><img name="strc" src="themes/DarkX/images/strc.gif" width="5" height="10" border="0" alt=""></td>
  </tr>
  <tr>
    <td background="themes/DarkX/images/sleft.gif"><img name="sleft" src="themes/DarkX/images/spacer.gif" width="1" height="1" border="0" alt=""></td>
        <td valign="top" bgcolor="#555555">
}


PS - The "I want a fat babe" is a movie in SWF format, Its very funny. If you want to look at it. its here (NOTE - its 3.6MB)
 
jaded







PostPosted: Wed Dec 08, 2004 3:20 pm Reply with quote

Quote:
<td width="100%" background="themes/DarkX/images/sbg.gif"><font class=content>&nbsp;<b>$title</b></font><img name="sbg" src="themes/DarkX/images/spacer.gif" width="1" height="1"


that is why it is happening. if you notice in the one i showed you. that is not listed. let me look at it a bit and get back to you. i would suggest trying to play with it a bit
 
DaveTomneyUK







PostPosted: Wed Dec 08, 2004 3:36 pm Reply with quote

I noticed whats happening the place where it says $title if you look lower down it says protected that is the name of the block and it should be where it says $title
 
jaded







PostPosted: Wed Dec 08, 2004 4:00 pm Reply with quote

can you give me a link to the exact theme you are using with the edited tables.php I will run it on my site and see what is wrong with it. Thanks
 
DaveTomneyUK







PostPosted: Wed Dec 08, 2004 4:12 pm Reply with quote

You may get a few errors running this theme as I have added a few mods to the theme itself like the attachment mod etc. But the theme is here

My default news is ForumNews but if you use the default news with PHP-Nuke you'll need to change the ForumNews inside the theme.php with this theme

inside theme.php look for this: (2lines)
Code:


if ($name!=ForumNews) {
 
jaded







PostPosted: Wed Dec 08, 2004 4:51 pm Reply with quote

Error 404: Not Found
please fix this
 
DaveTomneyUK







PostPosted: Wed Dec 08, 2004 4:53 pm Reply with quote

Fixed sorry I thought you got the file. When I say Fixed I mean I re uplaoded the file not fixed the theme yet. Very Happy
 
jaded







PostPosted: Wed Dec 08, 2004 8:19 pm Reply with quote

thanks. i just got it. I will let you know when i get it going
 
jaded







PostPosted: Wed Dec 08, 2004 8:37 pm Reply with quote

you can see this theme in the themes feature of my site. Please go view it and tell me if the images around the messages and blocks is correct. They seem to be functioning well. These are the images that you had calling from the tables.php Thanks
the "check out our forums" is a center block so is the paypal search

if the images that are showing up on the theme on my site are incorrect. please send me the theme.php file from the one you are using and i will work with that one
 
DaveTomneyUK







PostPosted: Thu Dec 09, 2004 6:36 am Reply with quote

the theme.php if you look you'll see a opentable(); with 2 lines that show this:

Code:


if ($name!=ForumNews) {


Please change it to this instead as I use a different news module to yours.

Code:


if ($name!=News) {


Yours looks like the default news module thats with PHP-Nuke and I use ForumNews instead. If you change the 2 lines in the theme.php of the DarkX theme the tables will look like hte pictures I posted above.
 
jaded







PostPosted: Thu Dec 09, 2004 6:57 am Reply with quote

i just wanted to be certain. please simply remove this one line of code and it will display the blocks/messages given name instead of $title
Code:
<font class=content>&nbsp;<b>$title</b></font>
 
DaveTomneyUK







PostPosted: Thu Dec 09, 2004 7:14 am Reply with quote

I removed it but it removes the $title as you said but if you look at this image here No1. shows no block title and No2 shows the block title lower down centered when it should be where No1 is circled.
 
jaded







PostPosted: Thu Dec 09, 2004 7:18 am Reply with quote

Yes, that is how the center block and message titles are posted on my site and most sites. I would assume that it is running off the default for the messages . That is how the messages and center blocks always look on my site so it was not an issue for me. I will see if I can get it moved for you but it will not be until much later today as I have several projects to work on.


Last edited by jaded on Thu Dec 09, 2004 7:20 am; edited 1 time in total 
DaveTomneyUK







PostPosted: Thu Dec 09, 2004 7:19 am Reply with quote

OK, Thankyou for helping me
 
jaded







PostPosted: Thu Dec 09, 2004 7:21 am Reply with quote

if you go to my site to view that theme please before you leave it change your theme because i will be removing that theme from my directory and i would hate for you to be locked out.
 
jaded







PostPosted: Thu Dec 09, 2004 7:24 am Reply with quote

also, as an fyi, if you look at Raven's homepage you will see his messages and center blocks function the same way. Just so you know that I am not nuts lol ROTFL
 
DaveTomneyUK







PostPosted: Thu Dec 09, 2004 7:38 am Reply with quote

I didn't think you was nuts as its driving me nuts I been messing with this theme for 2 days and didn't think of using the if statment I posted above till later yesterday. Smile So now the opentable with graphics only work on the homepage and the other opentable works on all other pages Razz

Ya I changed my theme back to "Xmas" Very Happy
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Themes

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©