PHP Web Host - Quality Web Hosting For All PHP Applications $35/month $250/year (Unlimited) - $25/month - 200,000 impressions - Your Ad Could be Here - Click For Details
  Login or Register
 • Home • Downloads • Your Account • Forums • 

View next topic
View previous topic


Google
 
Web RavenPHPScripts (This Site)
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.
Author Message
prophet_dna
New Member
New Member


Joined: Oct 02, 2005
Posts: 15

PostPosted: Sun May 27, 2007 1:49 am Reply with quote Back to top

Okay I think I got it fixed... Here was the solution I found...

Code:
function themeheader() {
    global  $admin, $user,  $banners, $sitename, $slogan, $cookie, $prefix, $db, $nukeurl, $anonymous;
    if ($banners == 1) {   
    $numrows = $db->sql_numrows($db->sql_query("SELECT * FROM ".$prefix."_banner WHERE type='0' AND active='1'"));
   /* Get a random banner if exist any. */
   /* More efficient random stuff, thanks to Cristian Arroyo from http://www.planetalinux.com.ar */
   $showbanners = ads(0); 
    if ($numrows>1) {


Thank you to everyone who helped out. Expecially Google and countless hours and days searching for my answer. I finally found it here in this thread on another forum...
Only registered users can see links on this board!
Get registered or login to the forums!
View user's profile Send private message
CodyG
Life Cycles Becoming CPU Cycles


Joined: Jan 02, 2003
Posts: 668
Location: Vancouver Island

PostPosted: Fri Jun 01, 2007 8:33 am Reply with quote Back to top

i was just trying to get $showbanners to work in the header.html file too ...

and i just got it working, in fisubice. When you setup the banner (advertising admin) did you select header_half from the Type: drop-down?

also, double check your paths to the image
View user's profile Send private message
spasticdonkey
RavenNuke(tm) Development Team


Joined: Dec 02, 2006
Posts: 1364
Location: Texas, USA

PostPosted: Tue Jul 24, 2007 8:58 am Reply with quote Back to top

ok i had a similar issue in fisubice under RNv2.10.01
the banner would appear at top middle of page and not in the right side of the header. My admin control panel didnt offer
Quote:
header_half from the Type: drop-down
as an option. I did a similar fix to the one listed above.....

Code:
function themeheader() {
    global  $admin, $user, $banners, $sitename, $slogan, $cookie, $prefix, $db, $nukeurl, $anonymous, $name, $admin_file;
    if ($banners == 1) {
        $numrows = $db->sql_numrows($db->sql_query('SELECT * FROM '.$prefix.'_banner WHERE active=\'1\''));

        /* Get a random banner if exist any. */
        /* More efficient random stuff, thanks to Cristian Arroyo from http://www.planetalinux.com.ar */
      $showbanners = ads(0); 
        if ($numrows>1) {


and it worked, however the banner still also appears at the top (twice)

is there another reference to
Code:
$showbanners

somewhere?
View user's profile Send private message
Guardian2003
Site Admin


Joined: Aug 28, 2003
Posts: 6373
Location: Vsetin, Czech Republic

PostPosted: Tue Jul 24, 2007 9:37 am Reply with quote Back to top

Looking at the code you posted, you seem to be missing some needed global variables, try this;

Code:

function themeheader() {
    global  $showbanners, $admin, $user, $banners, $sitename, $slogan, $cookie, $prefix, $db, $nukeurl, $anonymous, $name, $admin_file;
    if ($banners == 1) {
        $numrows = $db->sql_numrows($db->sql_query('SELECT * FROM '.$prefix.'_banner WHERE active=\'1\''));
View user's profile Send private message Send e-mail Visit poster's website
spasticdonkey
RavenNuke(tm) Development Team


Joined: Dec 02, 2006
Posts: 1364
Location: Texas, USA

PostPosted: Tue Jul 24, 2007 9:43 am Reply with quote Back to top

well changed that code in fisubice/theme.php and it still appears twice. Is there something in the header.php file that displays ads?

the only options i have to display under the admin section are:
Image
View user's profile Send private message
spasticdonkey
RavenNuke(tm) Development Team


Joined: Dec 02, 2006
Posts: 1364
Location: Texas, USA

PostPosted: Tue Jul 24, 2007 10:18 am Reply with quote Back to top

ok i found it, in the fisubice/theme.php file, i removed line #131
Code:
echo ads(0);
View user's profile Send private message
Display posts from previous:       
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.

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