When I delete ddblocks, they disappear from the list but they are still around. The Dynamic Display Block lists are empty (I deleted the two old ones), cleared server and client caches, made sure the blocks don't appear on the Block configuration page, yet the Basic block is still showing up on the front page where it was before.
Do I need to clear it in the database? If so, how do I do this?
I used the contextual link on the block as it appeared on the front page and the "basic" block edit page appeared. I changed the title and Saved. The block then disappeared from the front page and only the error:
* Notice: Undefined index: 1 in ddblock_get_block_title() (line 2555 of /home/mysite/public_html/drupal7/sites/all/modules/ddblock/ddblock.module).
* Notice: Undefined index: 1 in ddblock_get_blocks() (line 251 of /home/mysite/public_html/drupal7/sites/all/modules/ddblock/ddblock.module).
* Notice: Trying to get property of non-object in ddblock_content() (line 1695 of /home/mysite/public_html/drupal7/sites/all/modules/ddblock/ddblock.module).
* Notice: Trying to get property of non-object in ddblock_content() (line 1697 of /home/mysite/public_html/drupal7/sites/all/modules/ddblock/ddblock.module).
* Notice: Trying to get property of non-object in ddblock_content() (line 1698 of /home/mysite/public_html/drupal7/sites/all/modules/ddblock/ddblock.module).remains each time I reload the front page.
Browsing through the database (like a bull in a china shop) I noticed that the table "Block" has four entries, two for each of the old ddblocks, including the "basic" block with the changed title.
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | ddblock-fix-delete-1049556-2.patch | 1.48 KB | ppblaauw |
| #4 | ddblock-fix-delete-1049556-1.patch | 1.28 KB | ppblaauw |
Comments
Comment #1
steveray commentedblock table contains these lines:
Where 'This block should be deleted' is the new title I gave the block.
...also noted: table ddblock_block is empty.
Comment #2
divan commentedI have the same problem.
Comment #3
steveray commentedIf I add a new "basic" block with a block name I've not used before and then click Edit on that block, I get the old "basic" block with the 'This block should be deleted' title and modified settings.
If I add a second "basic" block (I've never had more than one before) it is created with all default values.
Comment #4
ppblaauw commentedPatch to fix deleting of blocks
Comment #5
steveray commentedI patched the file and tried deleting the old ddblocks.
The two rows for each were deleted (bartik and seven) but a new row for each in the block table was added with the "seven" theme and with the title field blank. They were never enabled in the "seven" theme.
I created a new basic ddblock and then deleted it and saw the same behavior.
I noticed that views is adding a new row to the block table during some of these delete operations.
That's all the debugging I've got time for right now; I wanted to give you what feedback I had, even if incomplete.
Comment #6
steveray commentedWhen I added the new block, it took its own new delta and didn't re-use a delta from a previously "deleted" ddblock.
Comment #7
ppblaauw commented@Steveray
thanks for testing
Probably the _block_rehash() function has to be called before deleting the rows so no new rows are added after the delete.
New patch attached.
Comment #8
W32 commentedI have the same problem.
Comment #9
ppblaauw commented#8 after applying the patch from #7 you have the same problem?
Comment #10
steveray commented#7 patch seems to work at removing the ddblock rows and no additional views row is added.
I've noticed that the title I add on the block configuration page doesn't stick on the first save but does if I retype it and save again.
Not sure if it's related, I'll create a new issue on this.
Comment #11
ppblaauw commentedcommitted to cvs