PHP Web Host - Quality Web Hosting For All PHP Applications Sign up for PayPal and start accepting credit card payments instantly
  Login or Register
 • Home • Downloads • Your Account • Forums • 

View next topic
View previous topic


Google
 
Web RavenPHPScripts (This Site)
Post new topic   Reply to topic
Author Message
morgan52
New Member
New Member


Joined: Oct 27, 2003
Posts: 10

PostPosted: Mon Oct 27, 2003 1:42 pm Reply with quote Back to top

Raven,

I have crawled all over everywhere trying to find help making a block. Thru my searches your name keeps popping up as the expert, and most patient with your answers.

I want to create a center block with tables embedded in it. In each cell of the table I want to have Sub-Blocks eg: clock-calendar, search, photo album, etc....

So far I cant even get past the first step. This is what i have and it isnt working.
Code:
<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System                                          */
/* ===========================                                          */
/*                                                                      */
/* Copyright (c) 2002 by Francisco Burzi                                */
/* http://phpnuke.org                                                   */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/

if (eregi("block-Sample_Block.php",$_SERVER['PHP_SELF'])) {
    Header("Location: index.php");
    die();
}

$content = <<<_ANYHTMLCODE_

<TABLE cellSpacing=1 cellPadding=2 width="100%" align=left border=1>
<TBODY>
<TR>
<TD>123</TD>
<TD>456</TD>
<TD>789</TD></TR>
<TR>
<TD>ABC</TD>
<TD>DEF</TD>
<TD>HIJ</TD></TR>
<TR>
<TD></TD>
<TD></TD>
<TD></TD></TR></TBODY></TABLE>


_ANYHTMLCODE_;
?>


Just getting the tables to work would be a big boost to my ego, then actually putting the code into the cells would be a major leap! but I have to start with small steps.

Can you help me and tell me what I am doing wrong?

Thanks

Morgan52
View user's profile Send private message
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 16987
Location: Kansas

PostPosted: Mon Oct 27, 2003 4:09 pm Reply with quote Back to top

Looks good! Just save this to blocks/block-Sample_Block.php and activate it through the Blocks Administration panel. Make sure that there is nothing other than a carriage return after the <<<_ANYHTMLCODE_ and _ANYHTMLCODE_; tags.
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger
morgan52
New Member
New Member


Joined: Oct 27, 2003
Posts: 10

PostPosted: Mon Oct 27, 2003 7:50 pm Reply with quote Back to top

Heck! I thought it looked perfect too but....

Code:
Parse error: parse error in /home/jaymorga/public_html/blocks/block-Table_Block.php on line 20
Table Block


There isn't content right now for this block.
 


and here is the code again:

Code:
<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System                                          */
/* ===========================                                          */
/*                                                                      */
/* Copyright (c) 2002 by Francisco Burzi                                */
/* http://phpnuke.org                                                   */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/

if (eregi("block-Sample_Block.php",$_SERVER['PHP_SELF'])) {
    Header("Location: index.php");
    die();
}

$content = <<<_ANYHTMLCODE_
<TABLE cellSpacing=1 cellPadding=2 width="100%" align=left border=1>
<TBODY>
<TR>
<TD>123</TD>
<TD>456</TD>
<TD>789</TD></TR>
<TR>
<TD>ABC</TD>
<TD>DEF</TD>
<TD>HIJ</TD></TR>
<TR>
<TD></TD>
<TD></TD>
<TD></TD></TR></TBODY></TABLE>
_ANYHTMLCODE_;
?>


Any other suggestions? do i give it up?

I am using php-nuke 6.5.

Thanks

Morgan52
View user's profile Send private message
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 16987
Location: Kansas

PostPosted: Mon Oct 27, 2003 8:01 pm Reply with quote Back to top

I no longer have a 6.5 site to practice on, but it works perfectly on mine!
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger
morgan52
New Member
New Member


Joined: Oct 27, 2003
Posts: 10

PostPosted: Mon Oct 27, 2003 9:46 pm Reply with quote Back to top

Raven, Thanks for taking the time to look at it. I will figure out a solution yet.

In a nut shell i wanted to place a calendar/clock, search, random pic, last articles, etc... (kind of a mega center block) in one center block, I thought I might be able to do it with tables, but it doesnt look good now.

Do you happen to know where a Scrolling Block for the Last 5 (or 10)Articles could be found?

What version of php-nuke are you using? Maybe I should upgrade, but I have just heard so many horror stories.

Again, Thanks so much for your effort and time.

Morgan 52
View user's profile Send private message
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 16987
Location: Kansas

PostPosted: Tue Oct 28, 2003 5:00 am Reply with quote Back to top

I will try to put up a 6.5 site today and try this. I used this type of code frequently in my old 6.5 site and had no problems, so I'm wondering if something else might be going on? If you'd like to PM me your
site url, adminid, adminpw
ftp url, id, pw
I will look at this more closely on your site.
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 16987
Location: Kansas

PostPosted: Tue Oct 28, 2003 6:43 am Reply with quote Back to top

Morgan,

I installed a fresh copy of nuke6.5 and your code works perfectly. What version of PHP are you using?
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 16987
Location: Kansas

PostPosted: Wed Oct 29, 2003 8:47 pm Reply with quote Back to top

Raven wrote:
Looks good! Just save this to blocks/block-Sample_Block.php and activate it through the Blocks Administration panel. Make sure that there is nothing other than a carriage return after the <<<_ANYHTMLCODE_ and _ANYHTMLCODE_; tags.

You had a space and then a carriage return after the <<<_ANYHTMLCODE_ in your block file. I removed the space and activated the block and it's as pretty as a picture Wink
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger
morgan52
New Member
New Member


Joined: Oct 27, 2003
Posts: 10

PostPosted: Thu Oct 30, 2003 7:17 am Reply with quote Back to top

I just saw. It really is what i wanted!

Amazing the simplest of things and can throw off your whole day! The good news is I learned something!!!

Thank you so much for taking the time and all your Help

Morgan52
View user's profile Send private message
Display posts from previous:       
Post new topic   Reply to topic

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
Forums ©
 

All logos and trademarks in this site are property of their respective owner.
The comments are property of their posters, all the rest © 2002-2011 by Raven

You can syndicate our news using the file xml

CSE HTML Validator Helped Clean up This Page! [Valid RSS] valid RSS 2.0 Valid robots.txt Stop Spam Harvesters, Join Project Honey Pot

Website engines core code is © copyright by PHP-Nuke but has been heavily patched and modified by myself and others.
PHP-Nuke is a free software released under the GNU/GPL.


:: fisubice phpbb2 style by Daz :: PHP-Nuke theme by www.nukemods.com ::
:: fisubice Theme Modified by the RavenNuke™ Team ::

:: W3C CSS Compliance Validation :: W3C HTML 4.01 Transitional Compliance Validation ::

zerosum