Textpattern CMS support forum

You are not logged in. Register | Login | Help

#271 2012-02-21 21:41:07

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

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

Ok Dale, thanks for the help.
asap I’ll release a new version which fixes the save bug as well as the installation bug (the first error message you reported – which actually isn’t a serious bug, just an annoyance).
Regarding the issue with the script-generated multiselect it can’t be fixed at plugin-code level (since the select is created after the plugin execution) but probably it can be solved by adding a specific jquery rule in the js box… more on this when I’ll have a moment.
BTW, tough not necessary, would you mind showing what the script does?

Offline

#272 2012-02-22 15:36:02

mrdale
Moderator
From: Walla Walla
Registered: 2004-11-19
Posts: 2,192
Website

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

Here’s the glz _cf script. The following will output a multi-select of non sticky articles from “mySection” showing titles, where the selection becomes a url_title. I use it to associate multiple articles from “mySection” with the current article for display purposes.

function my_section_articles($custom_field, $custom_id, $custom_value) {
$titles = array();
$query = safe_rows('url_title, title', 'textpattern', "section like 'mySection' AND status !=5");
$titles[] = ' ';
foreach ($query as $title)
$titles[$title['url_title']] = $title['title'];
return glz_selectInput($custom_field, $custom_id, $titles, $custom_value, "1", true); }

Offline

#273 2012-07-31 00:08:15

GugUser
Member
From: Quito (Ecuador)
Registered: 2007-12-16
Posts: 1,353

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

It seems that this very useful plugin will no longer works in the next version 4.5 of Textpattern (look the following rah_section_titles forum posts).

Do you plan to adapt it to the next version of Textpattern?

Thank you very much for your plugins.

Offline

#274 2012-08-29 14:53:31

maniqui
Moderator
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,059
Website

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

Sharing a tip:

This is a replacement/alternative for jmd_save (use Ctrl+S to save articles on Write tab) which I’m not sure it’s currently working in some modern browsers (I’ve had some issues with Chromium).

Using bot_write_tab_customize, you can add additional Javascript code to the Write panel.

Visit the “Extensions -> Write tab customize” tab, click on the “Additional JS code”, paste this code into the textarea and click on “Update”.

<script type="text/javascript">
var jmd_save = {};
jmd_save.main = function()
{

  $(window).keydown(function(event) {
      //19 for Mac Command+S
      if (!( String.fromCharCode(event.which).toLowerCase() == 's' && event.ctrlKey) && !(event.which == 19)) return true;
      event.preventDefault();
      jmd_save.submit();
      return false;
  });

}();

/**
 * Submits the main-editing form.
 */
jmd_save.submit = function()
{
    var btn = $('.publish');
    if (btn.length > 0)
        return btn[0].click();
};
</script>

And that’s all. Just hit Ctrl+S when writing an article, and it should get saved.
An ideal companion to rah_expanding and the new AJAX article save functionality in Textpattern 4.5.


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#275 2012-08-30 17:41:47

Gocom
Plugin Author
Registered: 2006-07-14
Posts: 4,524
Website

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

maniqui wrote:

And that’s all. Just hit Ctrl+S when writing an article, and it should get saved.

Damn knots. Thought to give the code a spin and run it through a blender.

Offline

#276 2012-08-30 19:52:28

johnstephens
Plugin Author
From: Woodbridge, VA
Registered: 2008-06-01
Posts: 959
Website

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

GugUser wrote:

It seems that this very useful plugin will no longer works in the next version 4.5 of Textpattern (look the following rah_section_titles forum posts).

Do you plan to adapt it to the next version of Textpattern?

Thank you very much for your plugins.

I’m experiencing the same troubles as GugUser, it seems. Given the juicy changes to the Write tab, it’s no surprise that this plugin would be affected, but are we the only ones?

Offline

#277 2012-08-30 20:34:10

Gocom
Plugin Author
Registered: 2006-07-14
Posts: 4,524
Website

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

johnstephens wrote:

I’m experiencing the same troubles as GugUser, it seems. Given the juicy changes to the Write tab, it’s no surprise that this plugin would be affected, but are we the only ones?

Everyone would be experiencing the same troubles caused by layout changes, yes. It’s not just random or configuration based. Not that many have even (yet?) updated to Textpattern 4.5 and using bot_wtc on it. Give it some time, the base that is affected will grow, but not everyone will be posting about it. Some will silently fork their private code w/o sharing it (I would say that is very common) and others just move on or don’t feel like reporting (live with the errors).

But when you do wonder why there aren’t reports of this or that, we small. Take a look at the total page view count (not unique or users) of this thread for instance. Under 50,000. Now, what do you think is the user base that is up to date or cares.

Offline

#278 2012-08-30 21:01:28

johnstephens
Plugin Author
From: Woodbridge, VA
Registered: 2008-06-01
Posts: 959
Website

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

Thanks, Gocom! I don’t have the wherewithal to fork the plugin and fix it, but I can hold out for the real thing. I’m very grateful for your confirmation that the problem isn’t just my configuration.

Offline

#279 2012-08-31 12:13:17

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 apologize for being away for so long. I was just a little burnt out with anything web related. I didn’t even know of txp 4.5!
Just give me some time to update myself about the new txp version …and some other time to re-understand my own plugin code.
I’ll try to fix these issues asap ok?
Cheers

Offline

#280 2012-08-31 12:16:33

tye
Member
From: Pottsville, NSW
Registered: 2005-07-06
Posts: 856
Website

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

More than happy to test things for you :)

Offline

Board footer

Powered by FluxBB