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

NukeCops  
•  Home •  Downloads •  Gallery •  Your Account •  Forums • 
Readme First
- Readme First! -

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

You are Anonymous user. You can register for free by clicking here
Nuke Cops :: View topic - rmoving the "block" from the banner ad [ ]
 Forum FAQ  •  Search  •   •  Memberlist  •  Usergroups   •  Register  •  Profile •    •  Log in to check your private messages  •  Log in

 
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next topic
Author Message
jimmyjimjim
Lieutenant
Lieutenant


Joined: Jan 23, 2003
Posts: 258

Location: USA

PostPosted: Fri Jul 11, 2003 4:13 pm Reply with quoteBack to top

Hi,

I wan't to strip the theme block from the banner block only. When I use the below code this happens...
in the if()
== results in all blocks looking normal
!= results in all block themes going away and just showing the block content.

Uhg... The nuke_blocks $bid for the advertising block is 16, so this should work... Right??? (I wan't to say thanks to Paladin for getting me started on this trek, but he's busy with his new site right now so I'm bring this question to NC).

Code:
if ($bid == 16) {

echo "<table width=\"165\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td>\n";
echo "$content\n";
echo "</td></tr></table>\n\n";

} else {

_THEME BLOCK STRUCTURE ($title & $content)_


Any ideas?
Find all posts by jimmyjimjimView user's profileSend private message
disgruntledtech
Site Admin
Site Admin


Joined: Apr 14, 2003
Posts: 991

Location: Tulsa, OK

PostPosted: Fri Jul 11, 2003 10:59 pm Reply with quoteBack to top

is $bid in the global statement for that function

example
Code:
global $bid;
Find all posts by disgruntledtechView user's profileSend private messageSend e-mailVisit poster's website
chris-au
Elite Nuker
Elite Nuker


Joined: Jan 31, 2003
Posts: 717


PostPosted: Fri Jul 11, 2003 11:52 pm Reply with quoteBack to top

Is that the block-Advertising.php?
If so, there is no function in that file.

_________________
Chris
Find all posts by chris-auView user's profileSend private messageVisit poster's website
disgruntledtech
Site Admin
Site Admin


Joined: Apr 14, 2003
Posts: 991

Location: Tulsa, OK

PostPosted: Sat Jul 12, 2003 12:51 am Reply with quoteBack to top

chris-au wrote:
Is that the block-Advertising.php?
If so, there is no function in that file.


thats not a block's code its the block theme function themesideblock()
Find all posts by disgruntledtechView user's profileSend private messageSend e-mailVisit poster's website
jimmyjimjim
Lieutenant
Lieutenant


Joined: Jan 23, 2003
Posts: 258

Location: USA

PostPosted: Sat Jul 12, 2003 6:15 am Reply with quoteBack to top

yes... $bid is in the global...

The way my themesideblock() is setup is:

Code:
themesideblock($title, $content) {

global $bid;

if ($bid == 16) {

do the modified block

} else {

do the standard block configuratoin

}
}


This should work... shouldn't it? I mean its kinda working and not returning any errors and I'm accessing the nuke_blocks table for the correct $bid.
Find all posts by jimmyjimjimView user's profileSend private message
chris-au
Elite Nuker
Elite Nuker


Joined: Jan 31, 2003
Posts: 717


PostPosted: Sat Jul 12, 2003 1:26 pm Reply with quoteBack to top

Thanks for the info.

I do not think that you should try to change that there.

You should have a look at mainfile.php.

Experiment with the function render_blocks( etc etc.

That is wher the $bid is firstly being accessed.

_________________
Chris
Find all posts by chris-auView user's profileSend private messageVisit poster's website
jimmyjimjim
Lieutenant
Lieutenant


Joined: Jan 23, 2003
Posts: 258

Location: USA

PostPosted: Sat Jul 12, 2003 5:46 pm Reply with quoteBack to top

ok... I'm in the mainfile and I'm reviewing the render_blocks function. But I'm lost... How can I tell I tell my theme to choose a block_theme layout based on $bid from here?

! Smile come on... throw a dog a bone... Smile
Find all posts by jimmyjimjimView user's profileSend private message
chris-au
Elite Nuker
Elite Nuker


Joined: Jan 31, 2003
Posts: 717


PostPosted: Sat Jul 12, 2003 6:29 pm Reply with quoteBack to top

I read your post but I really don't know what EXACTLY you want to do.
I know at times I am a bit dense in understanding what the real quetion is (see my previous post here).

In admin/blocks there are many things one can do with blocks but I suppose that is not the question.

If I know what you want to do, I ceratinly will try to get an answer for you,
I like challenges.

_________________
Chris
Find all posts by chris-auView user's profileSend private messageVisit poster's website
jimmyjimjim
Lieutenant
Lieutenant


Joined: Jan 23, 2003
Posts: 258

Location: USA

PostPosted: Sat Jul 12, 2003 7:19 pm Reply with quoteBack to top

The result I am trying to achieve is this...

I would like to display the banners block ($bid 16) $content only wrapped in a <table><tr><td> with nothing around the displayed banner...

WHile maintaining the themes blocks structure for the rest of my site.

I just want to remove the block from around the banner so that the banner, and only the banner is displayed on the page with no block around it.

Smile
Find all posts by jimmyjimjimView user's profileSend private message
chris-au
Elite Nuker
Elite Nuker


Joined: Jan 31, 2003
Posts: 717


PostPosted: Sat Jul 12, 2003 7:47 pm Reply with quoteBack to top

Can I see your site with that banner block somewhere?

_________________
Chris
Find all posts by chris-auView user's profileSend private messageVisit poster's website
jimmyjimjim
Lieutenant
Lieutenant


Joined: Jan 23, 2003
Posts: 258

Location: USA

PostPosted: Sun Jul 13, 2003 6:25 am Reply with quoteBack to top

This is where I am...

I created this...
Code:
ALTER TABLE nuke_blocks ADD `blockplace` CHAR(50) NOT NULL AFTER `blockfile`;

Now... in my theme I want to do this...

Code:
if ($blockplace == 1) {

do a modified block theme

} else {

do the default block theme

Now the questoin is where do I put this?
Code:
$sql = "SELECT blockplace FROM ".$prefix."_blocks";
$result = $db->sql_query($sql);
$row = $db->sql_fetchrow($result);
$blockplace = $row[blockplace];
Find all posts by jimmyjimjimView user's profileSend private message
jimmyjimjim
Lieutenant
Lieutenant


Joined: Jan 23, 2003
Posts: 258

Location: USA

PostPosted: Sun Jul 13, 2003 10:01 am Reply with quoteBack to top

Ok.. THis is driving me NUTS! I updated function blocks($side) (in mainfile.php) to call $blockplace.


And now I'm back to the beggining...
If $blockplace == 1 then nothing changes...

If I say $blockplace !=1 then everything changes... So I know its working, but...

All all of the blocks executed at the same time? Why can't I convert just one?
Find all posts by jimmyjimjimView user's profileSend private message
chris-au
Elite Nuker
Elite Nuker


Joined: Jan 31, 2003
Posts: 717


PostPosted: Sun Jul 13, 2003 1:01 pm Reply with quoteBack to top

I think you want to display a certain block in a certain way.
Still quite don't understand what.

But, if you download Blocks_Mod.zip from from here you can manipulate blocks in relation to with a theme if you wish.

_________________
Chris


Last edited by chris-au on Sun Jul 13, 2003 4:05 pm; edited 1 time in total
Find all posts by chris-auView user's profileSend private messageVisit poster's website
jimmyjimjim
Lieutenant
Lieutenant


Joined: Jan 23, 2003
Posts: 258

Location: USA

PostPosted: Sun Jul 13, 2003 3:45 pm Reply with quoteBack to top

I'm sorry but I couldn't find the file you were pointing me to... COUld you possibly provide a direct link?

THanks in advance...
Find all posts by jimmyjimjimView user's profileSend private message
disgruntledtech
Site Admin
Site Admin


Joined: Apr 14, 2003
Posts: 991

Location: Tulsa, OK

PostPosted: Sun Jul 13, 2003 3:51 pm Reply with quoteBack to top

here is the corrected link:

http://www.sengers-au.com/downloads.html
Find all posts by disgruntledtechView user's profileSend private messageSend e-mailVisit poster's website
Display posts from previous:      
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next 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



Powered by phpBB © 2001, 2005 phpBB Group

Ported by Nuke Cops © 2003 www.nukecops.com
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::
Powered by · TOGETHER TEAM srl ITALY http://www.togetherteam.it · DONDELEO E-COMMERCE http://www.DonDeLeo.com
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.257 Seconds - 352 pages served in past 5 minutes. Nuke Cops Founded by Paul Laudanski (Zhen-Xjell)
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::