1
PatsRule
Help With Custom Page
  • 2005/2/11 22:14

  • PatsRule

  • Just popping in

  • Posts: 37

  • Since: 2004/9/15


Hi All... Thank You in advance

I want to create what I call a 2'nd Home Page. It will mimic my Start Page except for the center block content. My problem is I can't get the right side blocks to appear. I've been searching through the FAQ's and did various searches but I'm either missing something or not understanding something. Here's what I have done so far:

I created a testing page called testpage.php, uploaded to the proper directory..actually my root which is called Xoops. Added a link in my main menu so I can see the changes which I was able to as I went along. Then used the following code to try and get it. All // are not in the code.

//include("../Xoops/mainfile.php");
include(XOOPS_ROOT_PATH."/header.php");
?>
//

Then inserted the html code which came out great. My Header was perfect on top to my theme...The left side blocks (user menu, main menu, etc..) were there and it was perfectly the way I wanted it in the center of the page. But the right side blocks (Polls..Who's Online, etc.. ARE NOT THERE however.

Then //include(XOOPS_ROOT_PATH."/footer.php");
?>//

What am I missing?? I've copied and pasted the HTML code from view source on the home and aligned it so it appeared right column and it looked exact, but the problem is it doesn't update accordingly doing it that way.

I also tried copying and pasting the HTML code in the same place from my theme rblock but all that did was give me the theme of my block look with this inside.

//<{$block.title}>//
//<{$block.content}>//

After 5 hours I decided to post so if the answer is here, I apologize because I can't find it or figure out something that was posted. It's probably something stupid but I'm about braindead right now. What am I missing??

2
PatsRule
Re: Help With Custom Page
  • 2005/2/12 16:01

  • PatsRule

  • Just popping in

  • Posts: 37

  • Since: 2004/9/15


This must be a tough one. I searched more and figured this would "supposedly" add the right blocks to my page but that doesn't work either.

//
include("../Xoops/mainfile.php");
include(XOOPS_ROOT_PATH."/header.php");
$xoopsOption['show_rblock'] = 1; (added)
?>
//

The //'s are not in my code btw. Is there something else I need to change/include so this page calls on the show_rblock function?? This would help me a lot, as my static pages could now basically be a home page for separate content (IE: Different Sports), yet all the key core functions of what my site is about would be on all these pages. I use a lot of tables and to just insert my HTML/java/javascripts and have each page having the same structure would be so much easier for me to add content.

Thanks again.

3
Dave_L
Re: Help With Custom Page
  • 2005/2/12 17:11

  • Dave_L

  • XOOPS is my life!

  • Posts: 2277

  • Since: 2003/11/7


$xoopsOption['show_rblock'] = 1;

won't have any effect unless it precedes

include(XOOPS_ROOT_PATH."/header.php");

I don't know if that will help you. I've never tried to do what you're doing.

4
PatsRule
Re: Help With Custom Page
  • 2005/2/12 19:28

  • PatsRule

  • Just popping in

  • Posts: 37

  • Since: 2004/9/15


Thanks Dave but no go. I thought that was it when I first read your post. Really strange how the right blocks won't go in. I didn't think this would be all that difficult as it is just a static page with HTML content. Using what I read from the FAQ here and as well as other searches and my own knowledge, to create one with XOOPS context on BOTH sides didn't appear all that difficult.

Basically you insert the includes and it gives you the header and left side blocks..the HTML you put in ends up in the center, but nothing in the right column. Testing again I put it just the code from the FAQ and Hello as HTML and my page looked exactly like my home page but just the word hello in the top of the center block. Simple code

//
include("../Xoops/mainfile.php");
$xoopsOption['show_rblock'] = 1;
include(XOOPS_ROOT_PATH."/header.php");
?>
//

//



Hello

//
//
include(XOOPS_ROOT_PATH."/footer.php");
?>
//

Regardless of where the "$xoopsOption['show_rblock'] = 1;" is, or if it is taken out, it appears the same. It's driving me loony already...lol. But thanks again.

5
yeziha
Re: Help With Custom Page
  • 2005/4/26 16:13

  • yeziha

  • Just popping in

  • Posts: 39

  • Since: 2005/2/22


Pats, try using a module!

I built a load of pages from the Sections module.
Simply cut off unnecessary functions and you'll have a very convrnient module samle. In the module files replace all "sections" with "your_page" and "sec_cont" with "you_page_cont". and mind the paths: ../sections/ replace with .../your_module_folder/.

Name the folder "your_module_folder", copy it to the "/modules/" folder and install. Works perfectly. :)

Login

Who's Online

144 user(s) are online (111 user(s) are browsing Support Forums)


Members: 0


Guests: 144


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Dec 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits