I haven't looked into the phpBB source - does it offer the option to let posters evaluate a BBtag into some meta BBcode?
The result would be BB-Tags the forum could evaluate like normal other BB-Tags.
While quoting or editing the post the posts source should still only display the [/code] tags and not all the rest (really broke a lot in the old forums).
phpBB issues
Re: phpBB issues
Recommends AHK Studio
Re: phpBB issues
Not sure about that, but I think I got the lag fixed.
after investigating this in depth, I found that the blocking/lag was caused mostly by the synchronous code I had written in prism.urls.js.
I've made it completely asynchronous, and it will only parse the ahk code for links when the mouse enters a code tag for the first time for that specific code tag.
Otherwise, prism.js was running pretty quickly already, I have also set it to defer to allow a smoother loading experience overall.
There might be still a bit of a lag because of how big the topic is, but it should still be a major improvement.
after investigating this in depth, I found that the blocking/lag was caused mostly by the synchronous code I had written in prism.urls.js.
I've made it completely asynchronous, and it will only parse the ahk code for links when the mouse enters a code tag for the first time for that specific code tag.
Otherwise, prism.js was running pretty quickly already, I have also set it to defer to allow a smoother loading experience overall.
There might be still a bit of a lag because of how big the topic is, but it should still be a major improvement.
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
FYI I just found this. Might be worth considering once stable and they create an importer for phpBB.
https://flarum.org/
https://flarum.org/
Re: phpBB issues
- I went to my function list thread, and noticed it was working really fast.
- I've checked the speed for the 4 links that I mentioned.
- They're all working great apart from the really long base64 string thread.
- Perhaps that one could be given the 'Codebox=text' treatment.
- AFAICS the problem is solved, although maybe there's some other issue causing the base64 thread problem in IE. Thanks.
~1 second (IE)
list of every command/function/variable from across all versions - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=74&t=27321
~who knows (IE) (I'm having real problems with this page, it's making the tab hang)
~instant (Firefox)
~2 seconds (Chrome)
Base64 decode and create file from clipboard - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=5&t=64341
~instant (IE)
[Class] eAutocomplete - Custom word completion for (Rich)Edit controls - Page 2 - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=6&t=48940&start=20
~3 seconds (IE)
[Editor] Gdip Bitmap Maker - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=6&t=62550
- I've checked the speed for the 4 links that I mentioned.
- They're all working great apart from the really long base64 string thread.
- Perhaps that one could be given the 'Codebox=text' treatment.
- AFAICS the problem is solved, although maybe there's some other issue causing the base64 thread problem in IE. Thanks.
~1 second (IE)
list of every command/function/variable from across all versions - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=74&t=27321
~who knows (IE) (I'm having real problems with this page, it's making the tab hang)
~instant (Firefox)
~2 seconds (Chrome)
Base64 decode and create file from clipboard - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=5&t=64341
~instant (IE)
[Class] eAutocomplete - Custom word completion for (Rich)Edit controls - Page 2 - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=6&t=48940&start=20
~3 seconds (IE)
[Editor] Gdip Bitmap Maker - AutoHotkey Community
https://autohotkey.com/boards/viewtopic.php?f=6&t=62550
homepage | tutorials | wish list | fun threads | donate
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
Re: phpBB issues
@kczx3 Very cool!
@jeeswg Good to hear
@jeeswg Good to hear
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
@kczx3
Since early April? I managed to find to the topic finally.
https://www.autohotkey.com/boards/viewtopic.php?p=100225#p100225
TLDR; jNizM had suggested a plugin, then Kobaltauge had managed to find a more up to date one. So I installed it, and the story goes from there
Since early April? I managed to find to the topic finally.
https://www.autohotkey.com/boards/viewtopic.php?p=100225#p100225
TLDR; jNizM had suggested a plugin, then Kobaltauge had managed to find a more up to date one. So I installed it, and the story goes from there
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
Unfortunately this change has caused AHK documentation lookup in code boxes to stop working on my iPad, which of course uses a touch screen.joedf wrote: ↑30 Jul 2019, 12:20Not sure about that, but I think I got the lag fixed.
after investigating this in depth, I found that the blocking/lag was caused mostly by the synchronous code I had written in prism.urls.js.
I've made it completely asynchronous, and it will only parse the ahk code for links when the mouse enters a code tag for the first time for that specific code tag.
Otherwise, prism.js was running pretty quickly already, I have also set it to defer to allow a smoother loading experience overall.
There might be still a bit of a lag because of how big the topic is, but it should still be a major improvement.
Any chance of a fix?
My scripts:-
XRef - Produces Cross Reference lists for scripts
ReClip - A Text Reformatting and Clip Management utility
ScriptGuard - Protects Compiled Scripts from Decompilation
I also maintain Ahk2Exe
XRef - Produces Cross Reference lists for scripts
ReClip - A Text Reformatting and Clip Management utility
ScriptGuard - Protects Compiled Scripts from Decompilation
I also maintain Ahk2Exe
Re: phpBB issues
Yeah I noticed that last night on my iPhone. I think I can fix this pretty easily.
EDIT: I added a 'ontouchstart' event, so tap a code box once to activate links. Also, I just thought of how I could this a lot more efficient. I'll post about it later.
EDIT: I added a 'ontouchstart' event, so tap a code box once to activate links. Also, I just thought of how I could this a lot more efficient. I'll post about it later.
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
New/Current version: https://www.autohotkey.com/boards/assets/prism/prism.urls.js
Now it simply puts one "click" event per code box (instead of an anchor tag for each token) and detects the token type and produces a link that opens in a new tab/window. CSS is used for "link" styling for the tokens.
Old version:
Now it simply puts one "click" event per code box (instead of an anchor tag for each token) and detects the token type and produces a link that opens in a new tab/window. CSS is used for "link" styling for the tokens.
Code: Select all
// NEW VERSION
// Using global events for target case-by-case detection
// linker to docs for prism.js update
// created 7/01/2019 - updated 09/08/2019
// script by joedf
var redirectQURL = '/docs/redirect.php?topic=';
// add CSS 'link' styling
codelinkstyle = document.createElement('style');
codelinkstyle .innerHTML = "code .selector:hover, code .constant:hover, code .keyword:hover, code .symbol:hover, \
code .tag:hover, code .builtin:hover, code .x_function:hover, code .important:hover, \
code .variable:hover { \
text-decoration:underline !important; \
cursor: pointer; \
}";
document.head.appendChild(codelinkstyle);
// add events for each codebox
var cboxes = document.querySelectorAll('code.language-autohotkey');
for(var i=0;i<cboxes.length;i++) {
cboxes[i].addEventListener('click', function(e){
var citem = e.target;
if (citem.className.indexOf('token') >= 0) {
var type = citem.className.replace('token','').trim().toLowerCase();
var cURL = null;
// supported types: selector, constant, operator, and variable
if (['selector','constant','keyword','symbol','tag'].indexOf(type)>=0) {
cURL = redirectQURL+citem.innerText;
} else if (['builtin','x_function'].indexOf(type)>-1) {
cURL = redirectQURL+citem.innerText+'()';
} else if (type.indexOf('variable')>-1) {
// same as bove normal rediretor usage but remove the % symbols...
cURL = redirectQURL+citem.innerText.replace(/%/gi,'');
} else if (type.indexOf('important')>-1) {
// same as bove normal rediretor usage but remove the # symbols...
cURL = redirectQURL+citem.innerText.replace(/#/gi,'');
} else {
// do nothing? leave as is...
return false;
}
var w = window.open(cURL, '_blank');
w.focus();
return true;
}
});
}
console.log("prism.urls.js executed.");
Old version:
Code: Select all
// ORIGINAL
// with <a>nchor tags on each thing
// linker to docs for prism.js update
// created 7/01/2019 - updated 09/08/2019
// script by joedf
////////////////////////////////////
var redirectQURL = '/docs/redirect.php?topic=';
// get AHK codeboxes
var cboxes = document.querySelectorAll('code.language-autohotkey');
for(var i=0;i<cboxes.length;i++) {
['mouseenter', 'touchstart'].forEach(function(e) {
cboxes[i].addEventListener(e,function(){
if (!this.hasAttribute('highlightedlinks')) {
ctokens = this.querySelectorAll('.token:not(.punctuation):not(.comment)');
this.setAttribute('highlightedlinks','true');
for(var j=0;j<ctokens.length;j++) {
(function(index) {
setTimeout(function(){
var citem = ctokens[index];
var type = citem.className.replace('token','').trim().toLowerCase();
// supported types: selector, constant, operator, and variable
if (['selector','constant','keyword','symbol','tag'].indexOf(type)>-1) {
citem.outerHTML = '<a href="'+redirectQURL+citem.innerHTML+'">'+citem.outerHTML+'</a>';
} else if (['builtin','x_function'].indexOf(type)>-1) {
citem.outerHTML = '<a href="'+redirectQURL+citem.innerHTML+'()">'+citem.outerHTML+'</a>';
} else if (type.indexOf('variable')>-1) {
// same as bove normal rediretor usage but remove the % symbols...
citem.outerHTML = '<a href="'+redirectQURL+citem.innerHTML.replace(/%/gi,'')+'">'+citem.outerHTML+'</a>';
} else if (type.indexOf('important')>-1) {
// same as bove normal rediretor usage but remove the # symbols...
citem.outerHTML = '<a href="'+redirectQURL+citem.innerHTML.replace(/#/gi,'')+'">'+citem.outerHTML+'</a>';
} else {
// do nothing? leave as is...
}
},1);
})(j);
}
}
});
});
}
/* force the underlined link style */
codelinkstyle = document.createElement('style');
codelinkstyle .innerHTML = "code a:hover{text-decoration:underline !important;}";
document.head.appendChild(codelinkstyle);
console.log("prism.urls.js executed.");
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
Also, I've just added a download feature to codeboxes with a filename defined.
My brain works so much better when I go to bed early (ish)
For future reference:
https://www.autohotkey.com/boards/assets/javascript/core.js
EDIT: update, added filename in the tooltip-title for download link
My brain works so much better when I go to bed early (ish)
For future reference:
https://www.autohotkey.com/boards/assets/javascript/core.js
Code: Select all
// joedf: add download for codeboxes
// should work for IE11, Chrome v1+, FF36+
function download_code_init(){
var boxes = document.getElementsByTagName('code');
for (var i = 0; i < boxes.length; i++) {
if (boxes[i].parentNode.parentNode.getAttribute('data-filename') != null) {
var filename = boxes[i].parentNode.parentNode.getAttribute('data-filename').trim().replace(/[<>:"\/\\\|\?\'\*]/g,'_');
var tagP = (boxes[i].parentNode.tagName.toLowerCase() == 'pre' ? boxes[i].parentNode.previousSibling : boxes[i].previousSibling);
tagP.innerHTML += ' - <a href="#" title="download '+filename+'" onclick="downloadCode(this); return false;">Download</a>';
}
}
}
// joedf: modified from https://stackoverflow.com/a/33542499/883015
window.downloadCode = function(e) {
// get Filename (regex ensures valid and safe name) and Data
var filename = e.parentNode.parentNode.getAttribute('data-filename').trim().replace(/[<>:"\/\\\|\?\'\*]/g,'_');
var data = e.parentNode.parentNode.getElementsByTagName('code')[0].innerText;
var blob = new Blob([data], {type: 'text/plain'});
if(window.navigator.msSaveOrOpenBlob) {
window.navigator.msSaveBlob(blob, filename);
} else {
var elem = window.document.createElement('a');
elem.href = window.URL.createObjectURL(blob);
elem.download = filename;
document.body.appendChild(elem);
elem.click();
document.body.removeChild(elem);
}
}
download_code_init();
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
Does this work for you now? I’m still having no joy. Is this solution deployed across all themes? I use prosilver.
My scripts:-
XRef - Produces Cross Reference lists for scripts
ReClip - A Text Reformatting and Clip Management utility
ScriptGuard - Protects Compiled Scripts from Decompilation
I also maintain Ahk2Exe
XRef - Produces Cross Reference lists for scripts
ReClip - A Text Reformatting and Clip Management utility
ScriptGuard - Protects Compiled Scripts from Decompilation
I also maintain Ahk2Exe
Re: phpBB issues
I just tested with an iPad and iPhone 5s, a desktop, and laptop, FF and Chrome.
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
It seems to be working now,
My scripts:-
XRef - Produces Cross Reference lists for scripts
ReClip - A Text Reformatting and Clip Management utility
ScriptGuard - Protects Compiled Scripts from Decompilation
I also maintain Ahk2Exe
XRef - Produces Cross Reference lists for scripts
ReClip - A Text Reformatting and Clip Management utility
ScriptGuard - Protects Compiled Scripts from Decompilation
I also maintain Ahk2Exe
Re: phpBB issues
Great! Could be just a CDN or local cache refresh issue
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
This is still horrible as long time & multiple tabs user
[AHK] v2.0.5 | [WIN] 11 Pro (Version 22H2) | [GitHub] Profile
Re: phpBB issues
ditto +1, but it's not too bad... I just let them load in the background... :/
Windows 10 x64 Professional, Intel i5-8500, NVIDIA GTX 1060 6GB, 2x16GB Kingston FURY Beast - DDR4 3200 MHz | [About Me] | [About the AHK Foundation] | [Courses on AutoHotkey]
[ASPDM - StdLib Distribution] | [Qonsole - Quake-like console emulator] | [LibCon - Autohotkey Console Library]
Re: phpBB issues
Hi there, still no solution.
I'm 'punished' at almost every visit at the forums, sometimes several times a day. Do you really think you need that 'punishment' for registered users? What about purchasing professional support to solve such problems? I'm willing to pay a share of the costs.
I'm 'punished' at almost every visit at the forums, sometimes several times a day. Do you really think you need that 'punishment' for registered users? What about purchasing professional support to solve such problems? I'm willing to pay a share of the costs.
Who is online
Users browsing this forum: No registered users and 18 guests