This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
5266
Archived fixes / Re: Logging password errors
« on May 2nd, 2012, 07:39 PM »
It's not implemented yet, I just wanted to see opinions about it :)
And hopefully Pete will implement it before I do, because I'm awfully busy on tons of features at the same time, in case you didn't check out today's rev log ;)
The Like button is still here...? It's just hidden inside the Actions button in Mobile mode, if you're wondering.
And hopefully Pete will implement it before I do, because I'm awfully busy on tons of features at the same time, in case you didn't check out today's rev log ;)
The Like button is still here...? It's just hidden inside the Actions button in Mobile mode, if you're wondering.
5267
Archived fixes / Logging password errors
« on May 2nd, 2012, 07:26 PM »
If there's one type of error that really bothers me in the error log, it's the "Password incorrect" error...
I believe it is logged every time someone enters an incorrect password when logging in.
Because it's the kind of thing that really I couldn't care less about, I'd suggest that we only log these (or at least offer a setting to...) when there have been X consecutive failed password attempts. That would still take care of brute force attempt warnings, while still leaving admins in peace without the need to systematically check their error log only to find these errors...
I'm not sure there's even a system in place to allow for logging errors according to their gravity level.
I believe it is logged every time someone enters an incorrect password when logging in.
Because it's the kind of thing that really I couldn't care less about, I'd suggest that we only log these (or at least offer a setting to...) when there have been X consecutive failed password attempts. That would still take care of brute force attempt warnings, while still leaving admins in peace without the need to systematically check their error log only to find these errors...
I'm not sure there's even a system in place to allow for logging errors according to their gravity level.
5268
Features / Re: New revs
« on May 2nd, 2012, 07:05 PM »
rev 1577
(9 files, 4kb) -- a quick rename.
* Renamed the topicseen variable/query string to just 'seen'. There is another variable, boardseen, which is not as often used, and I don't think it's worth specifying the 'topic' is seen in the variable name... (Display.php, MessageIndex.php, QuickMod.php, Subs-Boards.php, Subs-Post.php, Unread.php, UnreadReplies.php, SSI.php, Search.template.php)
(9 files, 4kb) -- a quick rename.
* Renamed the topicseen variable/query string to just 'seen'. There is another variable, boardseen, which is not as often used, and I don't think it's worth specifying the 'topic' is seen in the variable name... (Display.php, MessageIndex.php, QuickMod.php, Subs-Boards.php, Subs-Post.php, Unread.php, UnreadReplies.php, SSI.php, Search.template.php)
5269
Features / Re: New revs
« on May 2nd, 2012, 06:50 PM »
rev 1576
(4 files, 5kb)
* As seen on wedge.org, Admin and PM top-level warnings will now be in red (.warn) and other warnings will be in orange (.note). (index.template.php, index.css)
* More CSS updates. Also removing Droid Sans from Warm. (index.css, Warm/skin.xml)
+ Forgot to commit the Themes template changes for mobile mode. (Themes.template.php)
(4 files, 5kb)
* As seen on wedge.org, Admin and PM top-level warnings will now be in red (.warn) and other warnings will be in orange (.note). (index.template.php, index.css)
* More CSS updates. Also removing Droid Sans from Warm. (index.css, Warm/skin.xml)
+ Forgot to commit the Themes template changes for mobile mode. (Themes.template.php)
5270
Features / Re: New revs
« on May 2nd, 2012, 05:32 PM »
rev 1575
(5 files +2, 28kb) (not as scary as it sounds, though...)
+ (Finally) committing my support for mobile mode. It's quite basic, in that it shouldn't be too complicated to understand or handle. Users visiting from a smartphone or whatever will get a separate default skin setting which can be set by the admin, and they themselves can change that skin to a non-mobile one in case they'd rather have a full experience. The skin is set per-session, meaning that you can navigate your forum with your desktop and mobile browsers at the same time with the same account, and two different skins. (install.sql, Class-MoDe.php, Load.php, Themes.php, Themes.language.php)
+ Added sha1.js v2.2 to the attic. This is the 'newer' 2009 version, but it compresses to 200+ bytes worse than the current one, and doesn't add anything to the original
implementation that needed to be fixed. (other/attic/sha1_2.2.js)
@ Need to implement: the 'pick' area of the skin selector will only set the default skin for your own current mode (mobile or desktop). Need to either make that clear, or add a variable to allow setting either of those... Any volunteers to share their preference or just implement the few lines needed to do that? :P
(5 files +2, 28kb) (not as scary as it sounds, though...)
+ (Finally) committing my support for mobile mode. It's quite basic, in that it shouldn't be too complicated to understand or handle. Users visiting from a smartphone or whatever will get a separate default skin setting which can be set by the admin, and they themselves can change that skin to a non-mobile one in case they'd rather have a full experience. The skin is set per-session, meaning that you can navigate your forum with your desktop and mobile browsers at the same time with the same account, and two different skins. (install.sql, Class-MoDe.php, Load.php, Themes.php, Themes.language.php)
+ Added sha1.js v2.2 to the attic. This is the 'newer' 2009 version, but it compresses to 200+ bytes worse than the current one, and doesn't add anything to the original
implementation that needed to be fixed. (other/attic/sha1_2.2.js)
@ Need to implement: the 'pick' area of the skin selector will only set the default skin for your own current mode (mobile or desktop). Need to either make that clear, or add a variable to allow setting either of those... Any volunteers to share their preference or just implement the few lines needed to do that? :P
5271
Features / Re: New revs
« on May 2nd, 2012, 05:01 PM »
rev 1574
(3 files, 2kb)
! SMF bug: in signatures, only the first line-break was excluded from length calculation. These regexes were missing a global modifier... (Profile.template.php)
+ Implemented scrollbar for touch devices (iPhone etc), as written by Dragooon. It's a bit slow, but at least it works. (sbox.js)
* Optimized sha1.js for size. Some very weird changes allowed for an extra 50+ byte shrinking of the gzipped file. (sha1.js)
(3 files, 2kb)
! SMF bug: in signatures, only the first line-break was excluded from length calculation. These regexes were missing a global modifier... (Profile.template.php)
+ Implemented scrollbar for touch devices (iPhone etc), as written by Dragooon. It's a bit slow, but at least it works. (sbox.js)
* Optimized sha1.js for size. Some very weird changes allowed for an extra 50+ byte shrinking of the gzipped file. (sha1.js)
5272
Off-topic / Re: Bitcointalk.org $11k bounty for new forum software
« on May 2nd, 2012, 04:42 PM »
Except we won't "pre-release" Wedge to anyone but our consultants and, later, our friends...
If they're willing to wait until Wedge alpha is out, then good for them. If they want to give us money to finish implementing what they need, good for them too.
If they're willing to wait until Wedge alpha is out, then good for them. If they want to give us money to finish implementing what they need, good for them too.
5273
Features / Re: New revs
« on May 2nd, 2012, 01:04 PM »
rev 1573
(4 files +1, 12kb)
+ Mobile mode will now hide some more areas in board/message index, such as topic stats. (Boards.template.php, MessageIndex.template.php)
+ Forgot to actually commit postpage... Well, now it's renamed back to post.js. (Class-Editor.php, post.js)
* Spacinazi. (stats.js)
(4 files +1, 12kb)
+ Mobile mode will now hide some more areas in board/message index, such as topic stats. (Boards.template.php, MessageIndex.template.php)
+ Forgot to actually commit postpage... Well, now it's renamed back to post.js. (Class-Editor.php, post.js)
* Spacinazi. (stats.js)
5274
Features / Re: New revs
« on May 2nd, 2012, 12:45 PM »
rev 1572
(10 files, 16kb)
* A larger logical rewrite of AeMe. (Aeva-Foxy.php, Aeva-Gallery.php, Aeva-Gallery2.php, Aeva-ModCP.php, Subs-Media.php, (GenericMenu.template.php), ManageMedia.template.php, Media.template.php, Media.language.php, mediadmin.js)
. Category headers now use page titles (this should help with readability and, basically, common sense.)
. $txt['media_album'] was probably unclear for i18n so I added $txt['media_album_is'] which is sprintf'd into a proper line.
. A cache key for embedded media items could be too long and was shortened to two md5 hashes.
. Fixed plenty of template glitches, such as showing the Mass Download button on empty albums, duh...
. Some problems with the urlmore variable missing an extra semicolon.
. Rewrote media admin toggler to fix it and add a nice little animation.
. Added template_show_generic_tabs function to make them into *actual* generic tabs...
. Spacinazi fiesta... Really.
(10 files, 16kb)
* A larger logical rewrite of AeMe. (Aeva-Foxy.php, Aeva-Gallery.php, Aeva-Gallery2.php, Aeva-ModCP.php, Subs-Media.php, (GenericMenu.template.php), ManageMedia.template.php, Media.template.php, Media.language.php, mediadmin.js)
. Category headers now use page titles (this should help with readability and, basically, common sense.)
. $txt['media_album'] was probably unclear for i18n so I added $txt['media_album_is'] which is sprintf'd into a proper line.
. A cache key for embedded media items could be too long and was shortened to two md5 hashes.
. Fixed plenty of template glitches, such as showing the Mass Download button on empty albums, duh...
. Some problems with the urlmore variable missing an extra semicolon.
. Rewrote media admin toggler to fix it and add a nice little animation.
. Added template_show_generic_tabs function to make them into *actual* generic tabs...
. Spacinazi fiesta... Really.
5275
Features / Re: New revs
« on May 2nd, 2012, 12:42 PM »
rev 1571 (a huge scary commit... Even I have trouble navigating it >_< needs extra care from volunteer reviewers whom I'll love forever.)
(18 files -1, 18kb)
+ Added a new option to allow add_js_file() and add_css_file() to ignore some filenames when they build the actual filename for a cached file. In typical Nao fashion, the CSS version is totally untested and was written right... now. (Class-Editor.php, Load.php, Subs-Cache.php)
+ Added a .wereplace() custom function for Wedge JS. It behaves similarly to .easyReplace() in the editor, but is now in the main script file, and used in a few more places. (Subs-Post.php, Welcome.template.php, editor-func.js, script.js, suggest.js, topic.js)
! Fixed tag splitter (was broken after my recent rewrites.) (Class-Editor.php, editor-func.js)
! Fixed 'local' suffix for CSS files -- it was internally considered as a main file name, instead of a potential suffix. Also added a 'global' suffix if you need to differentiate between the two, although basically, every single suffix will apply globally without the need to resort to using this one. (Load.php)
! Fixed bug in calling previewPost. Although I still don't know the point of having this check for the CTRL key... Anyone tried it? For me it 'simply' creates a new tab with the preview... Odd. (Post.php)
! Finally took time to just tell Wedge to shut up if a menu tab doesn't provide a description. (GenericMenu.template.php)
- Got rid of add_params for menus. Anyone ever used these...? (PostModeration.php, GenericMenu.template.php)
* Replaced the login time hack with a cleaner and more accurate session variable for determining the desired position of our script files in the HTML source. (index.template.php)
* Renamed post.js to editor-func.js (editor-related helper functions), and ignoring editor-func filename. (Class-Editor.php, editor-func.js, post.js)
@ Temp: renamed whatever remained of post.js to postpage.js, will rename it back in the next commit. (Class-Editor.php, post.js, postpage.js)
* Moved 99% of the Post template's inline JavaScript to the postpage.js file. And it still works. Polls need some polish. (Post.template.php, postpage.js)
* More size optimizations, some being even more logical than the original code, my favorites really. (editor.js, pm.js, script.js, spellcheck.js, suggest.js, topic.js)
* Commenazi, spacinazi. (QueryString.php, admin.js)
(18 files -1, 18kb)
+ Added a new option to allow add_js_file() and add_css_file() to ignore some filenames when they build the actual filename for a cached file. In typical Nao fashion, the CSS version is totally untested and was written right... now. (Class-Editor.php, Load.php, Subs-Cache.php)
+ Added a .wereplace() custom function for Wedge JS. It behaves similarly to .easyReplace() in the editor, but is now in the main script file, and used in a few more places. (Subs-Post.php, Welcome.template.php, editor-func.js, script.js, suggest.js, topic.js)
! Fixed tag splitter (was broken after my recent rewrites.) (Class-Editor.php, editor-func.js)
! Fixed 'local' suffix for CSS files -- it was internally considered as a main file name, instead of a potential suffix. Also added a 'global' suffix if you need to differentiate between the two, although basically, every single suffix will apply globally without the need to resort to using this one. (Load.php)
! Fixed bug in calling previewPost. Although I still don't know the point of having this check for the CTRL key... Anyone tried it? For me it 'simply' creates a new tab with the preview... Odd. (Post.php)
! Finally took time to just tell Wedge to shut up if a menu tab doesn't provide a description. (GenericMenu.template.php)
- Got rid of add_params for menus. Anyone ever used these...? (PostModeration.php, GenericMenu.template.php)
* Replaced the login time hack with a cleaner and more accurate session variable for determining the desired position of our script files in the HTML source. (index.template.php)
* Renamed post.js to editor-func.js (editor-related helper functions), and ignoring editor-func filename. (Class-Editor.php, editor-func.js, post.js)
@ Temp: renamed whatever remained of post.js to postpage.js, will rename it back in the next commit. (Class-Editor.php, post.js, postpage.js)
* Moved 99% of the Post template's inline JavaScript to the postpage.js file. And it still works. Polls need some polish. (Post.template.php, postpage.js)
* More size optimizations, some being even more logical than the original code, my favorites really. (editor.js, pm.js, script.js, spellcheck.js, suggest.js, topic.js)
* Commenazi, spacinazi. (QueryString.php, admin.js)
5276
Archived fixes / Re: Long cache keys make the cache fail.
« on May 2nd, 2012, 12:00 PM »
Salting is the process of adding a secret string to any password before encrypting them, making it impossible to brute force a password by dictionary or whatever, right..? (I'm trying to remember :P)
5277
Off-topic / Re: Bitcointalk.org $11k bounty for new forum software
« on May 2nd, 2012, 10:56 AM »From the thread, it's like a serious offer from the admin. Bitcoin is an alternative electronic currency[1].
1. http://en.wikipedia.org/wiki/Bitcoin
Is that toy money, then? I saw on French wikipedia that the currency's value fluctuates greatly over the months... So when the topic title says "$11k", it really means "if you can do this immediately AND find someone who'd be willing to pay you $11k for your bitcoins..."
It could also mean "$11 bounty for new forum software" (without the "k") if this money thing fails to take off... Or "$11M bounty" even.
The admin favor an SMF based fork/site/customization than other solution because he/she already familiar with SMF.
5278
Off-topic / Re: Bitcointalk.org $11k bounty for new forum software
« on May 2nd, 2012, 10:35 AM »
Is this spam? You have a suspicious user name.
I don't get a word of what that forum is about. People making bets..?! Doesn't look very serious to me.
If basically you're telling me that a community is willing to fork out $11k for us to implement a few extra features to Wedge, then it can be discussed. But even $11k (split in two because I'll always share any benefits with Pete, whoever does whatever work on whatever project related to Wedge), isn't going to be a clear incentive for us to stray away from pure work on what we want to do on Wedge...
And "get rid of the web 2.0ish"... What is that supposed to mean?
I don't get a word of what that forum is about. People making bets..?! Doesn't look very serious to me.
If basically you're telling me that a community is willing to fork out $11k for us to implement a few extra features to Wedge, then it can be discussed. But even $11k (split in two because I'll always share any benefits with Pete, whoever does whatever work on whatever project related to Wedge), isn't going to be a clear incentive for us to stray away from pure work on what we want to do on Wedge...
And "get rid of the web 2.0ish"... What is that supposed to mean?
5279
Off-topic / Re: So, busy out here in RL
« on May 2nd, 2012, 08:42 AM »
I've read this entirely, and all I got was this lousy T-Shirt.™
Node.js sounds fun to play with, still... Maybe that's because I'm so much into JS these days. (I don't know, I just like playing with it... Even though I'm doing things the other way around, like getting rid of prototypes and so on... Even though -- I think that a prototype as such should be a thing of plugins, not stock code -- stock code should have this.function instead of object.prototype.function... Anyway.)
I still don't understand the point of Node.js, though. (Or perhaps, even more fittingly, the point of being force to use it to compile LESS scripts when WeCSS proves that it's perfectly easy to do the same in PHP....)
Node.js sounds fun to play with, still... Maybe that's because I'm so much into JS these days. (I don't know, I just like playing with it... Even though I'm doing things the other way around, like getting rid of prototypes and so on... Even though -- I think that a prototype as such should be a thing of plugins, not stock code -- stock code should have this.function instead of object.prototype.function... Anyway.)
I still don't understand the point of Node.js, though. (Or perhaps, even more fittingly, the point of being force to use it to compile LESS scripts when WeCSS proves that it's perfectly easy to do the same in PHP....)
5280
Archived fixes / Re: Long cache keys make the cache fail.
« on May 2nd, 2012, 08:09 AM »
My opinion on cache keys is that it's the responsibility of the programmer to ensure they're not too long.
Here we had a key that could definitely be way too long, and benefited from being md5'd. Thankfully, any key that's too long will be logged in the error log and thus it makes it easier to fix it. Worst case scenario, anyway, is that the cache isn't used for that particular key ;)
Here's my code... Any weaknesses? I'm just curious. Or maybe I should use \[url[]=]([^][]+) for the pattern...? Don't remember if these formats are used as well. I guess so...
Code: [Select]
(Originally, $key = $item_data['embed_url'], if you will.)
Here we had a key that could definitely be way too long, and benefited from being md5'd. Thankfully, any key that's too long will be logged in the error log and thus it makes it easier to fix it. Worst case scenario, anyway, is that the cache isn't used for that particular key ;)
Here's my code... Any weaknesses? I'm just curious. Or maybe I should use \[url[]=]([^][]+) for the pattern...? Don't remember if these formats are used as well. I guess so...
preg_match('~\[url=([^]]+)~', $item_data['embed_url'], $match);
$key = md5($match[1]) . '-' . md5($item_data['embed_url']);(Originally, $key = $item_data['embed_url'], if you will.)