Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#253 2011-12-08 03:08:24

renobird
Member
From: Gainesville, Florida
Registered: 2005-03-02
Posts: 786
Website

Re: bot_write_tab_customize: rearrange and style items in the write tab

Perfect! That fixed the syntax error — thank you!

I can hide the unwanted sections via JS myself for now, but I will clean up any remnants for sed_section_fields just in case.

:)

Offline

#254 2011-12-08 12:47:11

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: bot_write_tab_customize: rearrange and style items in the write tab

renobird wrote:

I can hide the unwanted sections via JS myself for now, but I will clean up any remnants for sed_section_fields just in case.

Hi Tom,
good move, at least it will temporarily fix the problem.
Sadly I still can’t think of a solution for the section hiding issue, just to explore the more obvious solutions have you tried to uninstall (using the uninstall button at the bottom of the bot_wtc extensions page) and reinstall?

Offline

#255 2012-01-03 17:43:05

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: bot_write_tab_customize: rearrange and style items in the write tab

Hi all,
I finally found some time to update the plugin. Version 0.7.1 is mainly a bugfix release which should address all issues found till now (of course these issues wouldn’t be there if I followed Jukka’s suggestions from the beginning).

Upgrade notes

The plugin should take care of updating the data stored in the db on activation, anyway I strongly reccommend – especially if you have a lot of rules set – to backup your db before upgrading in case something goes wrong.

Changelog

v 7.1

Download and info from first post.

Last edited by redbot (2012-01-03 17:43:48)

Offline

#256 2012-01-31 01:41:00

floodfish
Member
From: Brooklyn, NY
Registered: 2007-01-11
Posts: 155
Website

Re: bot_write_tab_customize: rearrange and style items in the write tab

Hi redbot,

Not that you should have to keep legacy plugins up-to-date, but …

I have a site that is stuck on Textpattern 4.2, and thus bot_write_tab_customize 0.6.3. I am running into the hidden sections not sticking problem. Any hope for a revised version of this plugin for old versions of TXP? And failing that, any advice for modifications I could make to it to fix this issue?

Offline

#257 2012-01-31 09:54:59

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: bot_write_tab_customize: rearrange and style items in the write tab

Hi Jason,
I’ll have a look when I can access my computer. This won’t happen before two days though.

Offline

#258 2012-01-31 20:03:17

floodfish
Member
From: Brooklyn, NY
Registered: 2007-01-11
Posts: 155
Website

Re: bot_write_tab_customize: rearrange and style items in the write tab

Thanks so much—whenever you get a chance, it’d be very helpful!

Offline

#259 2012-02-01 22:53:00

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: bot_write_tab_customize: rearrange and style items in the write tab

Hi Jason,
I’ve just made a quick diff between version 6.2 and 7 without too much investigation and I think you have to change these lines.
Around line 658 replace this:

// updates static sections prefs
$static_sections_string = $static_sections ? implode('|', $static_sections) : '';
safe_update('txp_prefs', 'val= "'.$static_sections_string.'", html="text_input" ', 'name = "bot_wtc_static_sections"' );
// updates script prefs
safe_update('txp_prefs', 'val= \''.doslash($bot_wtc_script).'\', html=\'textarea\' ', 'name = \'bot_wtc_script\'' );

with this:

// updates static sections prefs
if ($static_sections) {
        $static_sections_string = implode('|', $static_sections);
	safe_update('txp_prefs', 'val= "'.$static_sections_string.'", html="text_input" ', 'name = "bot_wtc_static_sections"' );
}
// updates script prefs
if ($bot_wtc_script) {
 	safe_update('txp_prefs', 'val= \''.doslash($bot_wtc_script).'\', html=\'textarea\' ', 'name = \'bot_wtc_script\'' );
}

This should do the trick (and incidentally it fixes another bug regarding the ‘js’ box). Let me know if it solves the issue.

Offline

#260 2012-02-02 00:59:50

floodfish
Member
From: Brooklyn, NY
Registered: 2007-01-11
Posts: 155
Website

Re: bot_write_tab_customize: rearrange and style items in the write tab

Thanks, redbot.

Didn’t work unfortunately. It remembers the checkbox settings for the first 21 sections, but none thereafter.

For whatever it’s worth, I’ve uninstalled and reinstalled the plugin and also deleted and rebuilt the database table.

Offline

#261 2012-02-02 09:09:01

philwareham
Core designer
From: Haslemere, Surrey, UK
Registered: 2009-06-11
Posts: 3,564
Website GitHub Mastodon

Re: bot_write_tab_customize: rearrange and style items in the write tab

floodfish wrote:

It remembers the checkbox settings for the first 21 sections, but none thereafter.

Is that maybe to do with the 255 character limit on the database row for bot_wtc ‘sections’ field. Change it’s type from VARCHAR 255 to TEXT and see if that helps.

Offline

#262 2012-02-02 10:12:30

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: bot_write_tab_customize: rearrange and style items in the write tab

floodfish wrote:

…I am running into the hidden sections not sticking problem …

I was about to give the same advice as Phil (BTW thanks for helping) but now I have a doubt: are you talking about the “Hide sections in sections dropdown” field or the “hide in” field?
In the first case there should be no such issue given that the plugin uses the standard textpattern prefs table for this field (and the “val” column is already set to “text”).
In the other case Phil is right but then my fix above is useless since it deals with the “Hide sections in sections dropdown” field.
The only thing that come to mind is are you sure you are using txp 4.2 and not a previous version (‘val’ column in ‘prefs’ table was changed from’varchar’ to ‘text’ in txp 4.2 )?

Last edited by redbot (2012-02-02 11:38:44)

Offline

#263 2012-02-02 16:55:13

floodfish
Member
From: Brooklyn, NY
Registered: 2007-01-11
Posts: 155
Website

Re: bot_write_tab_customize: rearrange and style items in the write tab

Phil’s suggestion fixed it!

Big thanks to both of you. And this really is a very useful plugin.

Last edited by floodfish (2012-02-02 16:55:33)

Offline

#264 2012-02-15 16:55:14

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: bot_write_tab_customize: rearrange and style items in the write tab

When you fix the save issue, the plugin will not hide multi-select and checkbox custom fields. Can we come up with a solution to that, it’s really frustrating.

(please, oh please)

Offline

Board footer

Powered by FluxBB