Glp! I'm in trouble over here since I activated a RSS feed as a center block... It kind of took over the whole contents on the portal AND forum, whether I press the Home, Forum, Admin or TPAdmin button... I.e., there is no forum posts to be seen, neither nor any other blocks than the RSS feed block, and worse - I cannot reach the admin panels :tickedoff:...
So, what file should I change to manually shut off that rss feed...? I have searched through some of the php files without finding what I'm looking for...
I think that the easiest way is going to be by using phpMyAdmin to make the change in the database directly. Whether or not a given block is shown is controlled by a field in the database, so the only way to make the change in the php files would be to change the database call to prevent all blocks from being shown.
- Go to your phpMyAdmin control panel
- Go to the database for your site
- Go to the tportal_blocks table on the left hand list of tables, click on it
- Click on the Browse tab at the top, in the right hand panel.
- Find the row that contains the RSS block
- Click on the little pencil icon on the left side of the row
- Find the field that is named "off", change the value from 0 to 1
- Click Save.
You then should be able to get back into the tpadmin screens of your site.
Be very careful if you follow the above directions. Don't change anything else.
To turn it off temporarily via the php file, go to sources/TPortal.php
Find (approximately line 108- 116):
// get the blocks
$test_Themebox = false; $blocktype=array('no','userbox','newsbox','statsbox','searchbox','html','onlinebox','themebox','shoutbox','catmenu','phpbox','scriptbox','recentbox','ssi','module','rss');
if(isset($_REQUEST['tptest']) && $context['user']['is_admin']){
$pre_id=$_REQUEST['tptest'];
$request = db_query("SELECT * FROM {$tp_prefix}blocks WHERE off=0 OR id=$pre_id ORDER BY bar,pos,id ASC", __FILE__, __LINE__);
}
else
$request = db_query("SELECT * FROM {$tp_prefix}blocks WHERE off=0 ORDER BY bar,pos,id ASC", __FILE__, __LINE__);
Change both instances of
WHERE off=0 to
WHERE off=2 and save it.
Then go to your website. All of the blocks will be missing at this point. However, you should be able to get into TPAdmin and turn the RSS block off. Once that is done, you then have to go back into the sources/TPortal.php file and reverse the changes you made to it. Changing both instances of
WHERE off=2 back to
WHERE off=0 and save it. That will make the blocks visible again.
Great, thx for quick response :)! I'll try that and report any progress later on!
Worked like a charm, of course ;D. Much obliged!
Any hints about why this error occurrs? Do I dare trying to add any RSS newsfeeds at all...?
I have never tried to add a rss news feed yet, so sorry cannot help you there.
However, I have seen similar things happen, and it is possible that there was maybe an error in the code used, that caused something to be unterminated properly.
Can you post the code you used for the rss here (don't forget to put it in code blocks).
Its usually the rss feed being formatted in a different way. Next update of TP wil have a "noblocks" option for admin, so you can tack ;noblocks at the end, and simply go into tpadmin and change the block again - as long as you have that on the end of adress. Like index.php?action=tpadmin;noblocks
Quote from: Rasyr on January 04, 2006, 11:32:55 AM
I have never tried to add a rss news feed yet, so sorry cannot help you there.
However, I have seen similar things happen, and it is possible that there was maybe an error in the code used, that caused something to be unterminated properly.
Can you post the code you used for the rss here (don't forget to put it in code blocks).
What I did was probably all wrong due to noob quality on my knowledge (or lack of it) about php and blocks in TP, but I did the same way as have previously made in MkPortal (which I, btw, have left for TP instead ;)): Just pasted a link to a feed, http://www.simracingworld.com/rss/news.rss, not the xml code itself... Is that the proper way of adding newsfeeds in the TP newsfeed block?
Quote from: Bloc on January 04, 2006, 11:54:38 AM
Its usually the rss feed being formatted in a different way. Next update of TP wil have a "noblocks" option for admin, so you can tack ;noblocks at the end, and simply go into tpadmin and change the block again - as long as you have that on the end of adress. Like index.php?action=tpadmin;noblocks
Sounds great :)!
There is an error in that RSS fee misjka. I did however get it to work on my test site.
http://www.tmrules.com/beta/
Quote from: IchBinâââ,¬Å¾Ã,¢ on January 04, 2006, 01:59:57 PM
There is an error in that RSS fee misjka. I did however get it to work on my test site.
http://www.tmrules.com/beta/
You sure about that? It appears that everything past the RSS block is missing, including the page footer with the copyright notices.. :)
Yeah, your site were a little bit better than mine - but not that very much better, I think... Sure you've got the left blocks, but none of the content links or top buttons work - do they?!?
That's because it's a test site. I don't have those links pointing at anything. They're just there as part of the default install and me messing around. I was just showing you that the RSS feed didn't fubar my forum. :)
OK... What happens if you turn on that right block column also?
If we (my simracing team and I) wasn't up for an important event tonight (and we therefore need a working forum) I should show you what happens @ my place right away...
Ah yes, now I see some problems. Wasn't looking that hard before. It did disable the right block and made it so I couldn't go back into TPAdmin. Sorry about that. Indeed that RSS feed is FUBAR. :)
Phew! Then I'm not the only one :coolsmiley:... Feels good & bad :o
There is only one thing to say to bloc _ U DA MAN!!!!
Dude, hope you realize that!!!!! I work out here in IBM on the helpdesk, and just wanted to let you know that your Tiny Portal program is awesome!!!!!
Keep up the stellar work my good friend>>>>>> Peace!!!
also ps thanks to ichbin for the rss fix....
PS if you want to see what I did with it - check out www.b-o-u-l-d-e-r.com
Laterz, dubs