Create a custom upgrade process?
// _activate() routine
function foo_activate()
{
global $cache;
// Insert/update version into cache
$plugins = $cache->read('foo_plugins');
if(!$plugins)
{
$plugins = array();
}
$info = foo_info();
if(!isset($plugins['foo']))
{
$plugins['foo'] = $info['versioncode'];
}
/*~*~* RUN UPDATES START *~*~*/
if($info['versioncode'] > $plugins['foo'])
{
if($info['versioncode'] == 561)
{
if($plugins['foo'] == 560)
{
//Fix: Autosave draft feature
//assuming 560 is the version where this feature was implemented
}
if($plugins['foo'] <= 560)
{
//add settings for 560 and lower
}
if($plugins['foo'] < 560)
{
//remove settings for lower to 560
}
}
}
/*~*~* RUN UPDATES END *~*~*/
$plugins['foo'] = $info['versioncode'];
$cache->update('foo_plugins', $plugins);
}
// _uninstall() routine
function foo_uninstall()
{
global $cache;
// Delete version from cache
$plugins = (array)$cache->read('foo_plugins');
if(isset($plugins['foo']))
{
unset($plugins['foo']);
}
if(!empty($plugins))
{
$cache->update('foo_plugins', $plugins);
}
else
{
$cache->delete('foo_plugins');
}
}
Deactivate -> Uplaod new files -> Activate -> Congratulations you have updated without losing changes!
New Version Released: 6.0.0
Now you can see all Editor Auto Saved Drafts in UCP.
To upgrade you need unistall old version, upload new version and install. Need unistall, because has new options in ACP settings.
Download: http://community.mybb.com/mods.php?actio...28&bid=528 or
https://github.com/martec/quickadveditor...ses/latest
(2014-11-10, 08:32 AM)Omar G. Wrote: [ -> ]Create a custom upgrade process?
Deactivate -> Uplaod new files -> Activate -> Congratulations you have updated without losing changes!
Thanks i will see in this in next version. But do not think it will be useful, because in every version have changes in the template.
(2014-11-11, 08:31 AM)Omar G. Wrote: [ -> ]That is the point...
so what changes you don´t want lost?
if in all versions has changes in template, will recreate templates in every version. will lose changes in template anyway.
I have installed this new version but now when I reply to a thread, my reply doesn't appear

I have to refresh page to look it.
Someone has this problem? How has solved? Or understand from what is due..
Thanks
News..if I disable:
Canonical Link Feature
Set to no if you do not want enable canonical link feature, this feature required by Auto Save Draft. If you use canonical link feature of google seo plugin, you can disable this feature.
I can look my reply without refresh page, but I haven't editor.... If I enable it, instead, I look editor on textarea but I don't look my reply after I sent it.
Then in plugin file there is
/**********************************
* Thread compatibility functions *
**********************************/
if(typeof Thread !== 'undefined')
{
If should not be
if(typeof Thread != 'undefined')
?
My settings
http://i.imgur.com/EJvJ0uG.png
I want only quick reply (editor on textarea) + smilies

I don't need canonical links (I don't know what's it), save draft or other
at the moment I can not give any kind of support, I am quite busy with other things.
anyway Canonical Link feature required by Auto Saved Draft feature... So if you disabled Canonical Link You need disable too Auto-save in ACP...
New Version Released: 6.1.1
Fix issue with canonical link
Download: http://community.mybb.com/mods.php?actio...28&bid=656 or
https://github.com/martec/quickadveditor...ses/latest
Upgrade
To upgrade you need unistall old version, upload new version and install. Need unistall, because has new options in ACP settings.
(2014-12-17, 12:21 AM)niere8 Wrote: [ -> ]News..if I disable:
Canonical Link Feature
Set to no if you do not want enable canonical link feature, this feature required by Auto Save Draft. If you use canonical link feature of google seo plugin, you can disable this feature.
fixed in 6.1.1
thanks for report...
(2014-12-17, 12:21 AM)niere8 Wrote: [ -> ]I can look my reply without refresh page, but I haven't editor.... If I enable it, instead, I look editor on textarea but I don't look my reply after I sent it.
i can´t reproduce this issue...
you can check here
http://martec.ml/test/
User: test
pass: test123
Hi, I have found the problem..maybe.
I have uninstalled all quickeditors etc, reverted to original showthread_quickreply, codebuttons, codebutquick.
Reinstalled only this latest quick editor but if I'm on forumdisplay_threadlist and open a thread, I go directly to the bottom (to the editor), instead of at the top.
I done these tests:
- If I'm a normal user (no supermod - mod - admin) I go normally at the top of the thread. If instead I'm an admin / mod / supermod I go at the bottom of the page. So I think it's also a problem with inline moderation.
- Without {$codebutquick} in showthread_quickreply page works well, but obviously I haven't editor in textarea. If I add {$codebutquick} instead I have editor but I go at the bottom (and only if I'm admin, supermod, mod).
In IE8 I have these errors in showthread (I'm looking as an admin):
Quote:Error details Web page
User-agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)
Timestamp: Tue, 30 Dec 2014 16:38:49 UTC
Message: Expected identifier, string or number
Line: 2066
Type: 36
Code: 0
URI: /forum/showthread.php?tid=xxxx
in HTML 2066 is: $('<div/>', { id: 'autosave', class: 'bottom-right' }).appendTo('body');
Error details Web page
Message: 'partialmode' is undefined
Line: 555
Type: 2
Code: 0
URI: /forum/jscripts/bbcodes_sceditor.js
In forumdisplay, instead, I have this error for inline_moderation:
Quote:Error details Web page
User-agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)
Timestamp: Tue, 30 Dec 2014 17:26:05 UTC
Message: Property or method not supported by the object
Line: 35
Type: 6
Code: 0
URI: /forum/jscripts/inline_moderation.js?ver=1800
Then I changed in usercp of a normal user (date and hour format) and also this user (normal) started to go at the bottom of the page
