1
maciek
Re: Problem with blocks after upgrade.
  • 2005/8/13 22:45

  • maciek

  • Just popping in

  • Posts: 5

  • Since: 2005/8/1 8


Ok, try this:
Log in to mysql, then execute following:

select bid from (prefix)_newblocks
left join (prefix)_modules on (prefix)_newblocks.mid = (prefix)_modules.mid
where (prefix)_modules.mid is null;

If there is some output (unless it is 'Empty set' of course ;)), delete all the blocks from (prefix)_newblocks table with bids you got (delete from (prefix)_newblocks where bid=bid).

Then execute next select:

select (prefix)_block_instance.bid from (prefix)_block_instance
left join (prefix)_newblocks on (prefix)_block_instance.bid = (prefix)_newblocks.bid
where (prefix)_newblocks.bid is null;

and delete the blocks from (prefix)_block_instance with bids you got.

Do not forget to make backup first.



2
maciek
Re: Problem with blocks after upgrade.
  • 2005/8/6 14:05

  • maciek

  • Just popping in

  • Posts: 5

  • Since: 2005/8/1 8


I have no idea.
Are there any errors? Write them here.



3
maciek
Re: Problem with blocks after upgrade.
  • 2005/8/2 18:59

  • maciek

  • Just popping in

  • Posts: 5

  • Since: 2005/8/1 8


Quote:
I have the same problem and my site does not display any blocks to users that are not logged in.

That's not the same - I couldn't list my blocks on the admin page, but they were visible for users.

I added some 'debug' lines in blocksadmin.php just before 58th line.
58th line is the first line of foreach loop, and I added these lines (at the beginning of foreach loop):
echo "mid: " . $block->getVar('mid');
echo "name: " . $modules[$block->getVar('mid')]->getVar('name') . "<br>";

I enabled php warnings of course.

This caused that when I clicked "List All Blocks" I saw list of "mid: xx name: yyy" which are module id and name of the module.
At the bottom of the page I had just number without corresponding name - attempt of getting the name was causing this error.

Then I found this number in database - it was in (prefix)_newblocks and (prefix)_blocks_instance tables.
I did this 2 times - I had 2 different junk blocks.



4
maciek
Re: Problem with blocks after upgrade.
  • 2005/8/2 15:29

  • maciek

  • Just popping in

  • Posts: 5

  • Since: 2005/8/1 8


After some playing with database i found that i have some junk entries (two _MI_SHOUTBOX_BLOCK). From some reason they didn't dissapeared after deleting zentrack module.
I had deleted them directly in MySQL and everything works just fine.



5
maciek
Problem with blocks after upgrade.
  • 2005/8/1 9:45

  • maciek

  • Just popping in

  • Posts: 5

  • Since: 2005/8/1 8


I did upgrade from 2.0.13 to 2.2 (+hotfix). After upgrade I can't list blocks (Administration menu/Blocks/List all blocks). I'm getting this error:
Fatal error: Call to a member function on a non-object in (...)/modules/system/admin/blocksadmin/blocksadmin.php on line 58
I found that there is function (list_blocks()) which wants something from module with mid=48, and i do not have such one. How this functions gets this number, or maybe - what should I do to repair this?




TopTop



Login

Who's Online

164 user(s) are online (115 user(s) are browsing Support Forums)


Members: 0


Guests: 164


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits