Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks
Author Message
viper155
Regular
Regular



Joined: Feb 18, 2006
Posts: 99

PostPosted: Wed Jun 13, 2007 11:14 pm Reply with quote

Is there a way to just hide the left blocks in the read more page, Article.php Im guessing?

Im asking bc the search engines seem to index my left block nav menu instead of the actualy story text.

Thanks.
 
View user's profile Send private message Visit poster's website
FireATST
RavenNuke(tm) Development Team



Joined: Jun 12, 2004
Posts: 654
Location: Ohio

PostPosted: Thu Jun 14, 2007 5:26 am Reply with quote

[ Only registered users can see links on this board! Get registered or login! ] Check that post. Not sure if that will give you any help or not.
 
View user's profile Send private message Visit poster's website MSN Messenger ICQ Number
viper155







PostPosted: Thu Jun 14, 2007 4:31 pm Reply with quote

Quote:
written by manunkind Another quick question.....how do I remove these left blocks only when I am reading an article? I know I can add "News" to my above code, but that removes them from the home page as well. I want them there, but not when I click to read a full article.

Any ideas?


This guy asked the same question and there was no answer as to how he was able to do this, but did say he got it working.
 
montego
Site Admin



Joined: Aug 29, 2004
Posts: 9457
Location: Arizona

PostPosted: Fri Jun 15, 2007 6:25 am Reply with quote

You could possibly do something like this. In the original post reference above from Raven, he has this:

Code:


    if ($name=="News") {}
    else blocks(left);


Try this:

Code:


    if ($name=="News" && $file="article") {}
    else blocks(left);


You will also have to add $file to the globals statement above this.

_________________
Where Do YOU Stand?
HTML Newsletter::ShortLinks::Mailer::Downloads and more... 
View user's profile Send private message Visit poster's website
viper155







PostPosted: Fri Jun 15, 2007 7:52 pm Reply with quote

This is what my code looks like in theme.php

Code:


    global $name, $file;
if ($name=='Forums') {}
   else if ($name=="News" && $file="article") {}
   else {
    blocks(left);


It is still removing the left blocks on the homepage as well. Sad
 
montego







PostPosted: Sat Jun 16, 2007 1:30 pm Reply with quote

viper155, can you please zip up your entire theme directory for this theme and send it to me at montego AT montegoscipts DOT com and I'll take a look at it when I get a chance.
 
gregexp
The Mouse Is Extension Of Arm



Joined: Feb 21, 2006
Posts: 1497
Location: In front of a screen....HELP! lol

PostPosted: Sat Jun 16, 2007 4:21 pm Reply with quote

Try Changing it to this:

global $name, $file;
if ($name=='Forums') {}
else if ($name=="News" && $file="article" && !defined('HOME_FILE')) {}
else {
blocks(left);

The !defined HOME_FILE references a definition set in index.php of your site which should resolve your issue.

_________________
For those who stand shall NEVER fall and those who fall shall RISE once more!! 
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number
viper155







PostPosted: Sat Jun 16, 2007 8:46 pm Reply with quote

It works perfectly Gregexp, also would like to thank everyone else in this thread for trying to help me.
 
viper155







PostPosted: Sun Mar 15, 2009 6:47 pm Reply with quote

Kinda bumping my own post from a while ago to attempt to get a new problem solved, hope this is okay instead of starting a new post.

I am using the theme CT_RN which came with the new revennuke and its very very nice I must stay. The theme I use to use had a different theme.php file setup and I was able to hide left blocks only on the article part of the news module using this code:

Code:


 global $name, $file;

if ($name=='Forums') {}

else if ($name=='Amazon') {}

else if ($name=='Content') {}

else if ($name=="News" && $file="article" && !defined('HOME_FILE')) {}

else {

blocks(left);





Now on the theme CT_RN the theme.php file is setup like this for hiding blocks



Code:


 // Column 1 (left)
      if (($module_name != 'Forums') AND ($module_name !='Your_Account') AND ($module_name !='Journal') AND ($module_name !='TTBO') AND ($module_name !='Topics') AND ($module_name !='Private_Messages') AND ($module_name !='Youtube_Videos') AND ($module_name !='Members_List')):
      echo '<div class="col1">';


Does anyone know how I fix this
Code:


else if ($name=="News" && $file="article" && !defined('HOME_FILE')) {}
to work for the CT_RN type of theme.php?



*EDITED* Figures I post that and then it gets figured out. Just in case someone else has this problem this is how the code should look to do what I explained above.

Code:


// Column 1 (left)
      if (($module_name != 'Forums') AND ($module_name !='Your_Account') AND ($module_name !='Journal') AND ($module_name !='TTBO') AND ($module_name !='Topics') AND ($module_name !='Private_Messages') AND ($module_name !='Youtube_Videos') AND ($module_name !='Members_List') AND ($module_name ='News' AND $file != 'article'):
      echo '<div class="col1">';
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks

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
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©