You are missing our premiere tool bar navigation system! Register and use it for FREE!

Author: hueLocation: OhioPostPosted: Sat May 19, 2007 11:10 am    Post subject:

I should have clarified myself a bit more as I made just a "generalized" statement, and not so much intended directly towards your issue at hand. For example :
•  Home •  Downloads •  Gallery •  Your Account •  Forums • 

Author: hueLocation: OhioPostPosted: Sat May 19, 2007 6:53 am    Post subject:

Editing the html that was within the echo/print statement would probably be the best way .

Author: SideXPostPosted: Sat May 19, 2007 10:31 am    Post subject:

Which echo/print statemenet are you talking about? The only one I see is the "print $r_file;" statement, which wouldn't follow the correct logic I need. There is no echo/print statements in blocks.php that work because implode, stripslashes, and eval cause it to not execute properly. At least thats what I'm blaming it on.

I'm trying to do something like (in pseudo code):
Readme First
- Readme First! -

Read and follow the rules, otherwise your posts will be closed
· Home
· Buy a Theme
· Advertising
· AvantGo
· Bookmarks
· Columbia
· Community
· Donations
· Downloads
· Feedback
· Forums
· Private Messages
· Search
· Statistics
· Stories Archive
· Submit News
· Surveys
· Theme Gallery
· Top
· Topics
· Your Account
Who's Online
There are currently, 190 guest(s) and 0 member(s) that are online.

You are Anonymous user. You can register for free by clicking here
Nuke Cops :: View topic - themesidebox themesidebox

Nuke Cops -> Core Chargers

Author: SideX PostPosted: Fri May 18, 2007 3:32 pm    Post subject: themesidebox

In my theme.php file I was using the themesidebox function like this:

function themesidebox($title, $content) {
    $tmpl_file = "themes/CS_BF2142/blocks.php";
    $thefile = implode("", file($tmpl_file));
    $thefile = addslashes($thefile);
    $thefile = "\$r_file=\"".$thefile."\";";
    print $r_file;

However it wasn't rendering my php properly. So I changed it to

function themesidebox($title, $content) {

Is there anything bad about doing this?

if($title = modules){
$img = "/themes/themename/images/1.gif";
} elseif ($title = survays){
$img = "/themes/themename/images/2.gif";
} else {
$img = "/themes/themename/images/blocks_01.gif";

Which will use different images depending on the block name.
function themesidebox($title, $content) {
    echo "<table border=\"0\" align=\"center\" width=\"138\" cellpadding=\"0\" cellspacing=\"0\">"
        ."<tr><td background=\"themes/yourtheme/images/table-title.gif\" width=\"138\" height=\"20\">"
        ."&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color=\"#FFFFFF\"><b>$title</b></font>"
        ."</td></tr><tr><td><img src=\"themes/yourtheme/images/pixel.gif\" width=\"100%\" height=\"3\"></td></tr></table>\n"
        ."<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"138\">\n"
        ."<tr><td width=\"138\" bgcolor=\"#000000\">\n"
        ."<table border=\"0\" cellpadding=\"1\" cellspacing=\"1\" width=\"138\">\n"
        ."<tr><td width=\"138\" bgcolor=\"#ffffff\">\n"

Author: SideX PostPosted: Sat May 19, 2007 6:11 pm    Post subject:

Ah OK. Thats pretty much what I was doing, but rather than including the block code inside the theme.php file I was putting the echo statement in blocks.php and just including it. Same difference Very Happy


Nuke Cops -> Core Chargers

All times are GMT - 8 Hours

Page 1 of 1

Powered by phpBB © 2001,2002 phpBB Group
Web site engine's code is Copyright © 2002 by PHP-Nuke. All Rights Reserved. PHP-Nuke is Free Software released under the GNU/GPL license.
Page Generation: 0.181 Seconds - 163 pages served in past 5 minutes. Nuke Cops Founded by Paul Laudanski (Zhen-Xjell)
added by Evaders - DO NOT REMOVE
:: FI Theme :: PHP-Nuke theme by coldblooded ( ::