Hash tag support
- Wodan
- ISO Advocate
- Location: ISO-DE
- Main keyboard: Intense Rotation!!!
- Main mouse: Logitech G903
- Favorite switch: ALL OF THEM
- DT Pro Member: -
Did some more testing. Seems like the search has a degree of fuzzyness and will find matches without the hashtag as well. Clicking on #phpBB will pop up lots of phpbb URLs
Maybe it's possible to add a parameter to the search to only show exact matches
Maybe it's possible to add a parameter to the search to only show exact matches
-
- Location: Germany
- Main keyboard: G80-3000LQCDE-2 w/ SKIDATA+
- Main mouse: Logitech B100
- Favorite switch: M Buckling spring, so far
- DT Pro Member: 0247
Same problem Wodan. You can't search for any special characters.Ray wrote: ↑actually doing your own tagging system and use the search-function for it isn't that easy in phpbb, because search replaces any non-alphanum with spaces (i.e. word seperator).
If this wasn't the case it would be easy (I guess) to do an autocorrection for anything starting e.g. with # with a link to searchresults for that tag.
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
Did some fixes with the German links I found at the last page of the mod for that. Re-creating the search index. This might take a while...
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
Search index is about 10% filled now...217.3 posts per second.
- Ratfink
- Location: North Carolina, USA
- Main keyboard: IBM Displaywriter
- Main mouse: CST L-Trac
- Favorite switch: Beam Spring
- DT Pro Member: -
Okay, here's my proposal. Make the tags by writing a # before the word in your post as it currently works, but hide the # when actually displaying the post. That would fix my major complaint, which is that all those # characters are an eyesore.
Hell, if people actually want to see them, then do what I said above, but give the tag links a class like .hashtag, and add a CSS rule like:
Then I could remove them with a custom stylesheet, but everyone who isn't a crotchety young man can leave them in place.
Hell, if people actually want to see them, then do what I said above, but give the tag links a class like .hashtag, and add a CSS rule like:
Code: Select all
a.hashtag::before {
content: "#";
}
-
- Location: Germany
- Main keyboard: G80-3000LQCDE-2 w/ SKIDATA+
- Main mouse: Logitech B100
- Favorite switch: M Buckling spring, so far
- DT Pro Member: 0247
It's starting to work again. The bad news is: It's working too good. It recognises # in code blocks. I'm not sure we want threads about firmware tagged with #ifdef and similar hashtags...
EDIT: Ratfinks suggestion could also cause issues with code or urls containing anchors.
EDIT: Ratfinks suggestion could also cause issues with code or urls containing anchors.
Last edited by Rimrul on 22 Nov 2016, 22:33, edited 1 time in total.
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
Yeah I was afraid of that. I'm not sure that can be prevented. It's all or nothing. But feel free to submit patches to that mod to exclude code for example.
-
- Location: Germany
- Main keyboard: G80-3000LQCDE-2 w/ SKIDATA+
- Main mouse: Logitech B100
- Favorite switch: M Buckling spring, so far
- DT Pro Member: 0247
It also affects urls with anchors, i.e.
https://www.phpbb.com/community/viewtop ... #p13329580
https://www.phpbb.com/community/viewtop ... #p13329580
- Ratfink
- Location: North Carolina, USA
- Main keyboard: IBM Displaywriter
- Main mouse: CST L-Trac
- Favorite switch: Beam Spring
- DT Pro Member: -
Well, does the current situation change links that have anchors in them?Rimrul wrote: ↑It's starting to work again. The bad news is: It's working too good. It recognises # in code blocks. I'm not sure we want threads about firmware tagged with #ifdef and similar hashtags...
EDIT: Ratfinks suggestion could also cause issues with code or urls containing anchors.
deskthority-f17/hash-tag-support-t15163-30.html#p340470
EDIT: it seems only long ones get messed with.
Does it mess with text in code tags?
Code: Select all
#ifndef TESTING_H
#define TESTING_H
...blah...
#endif
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
The mod should take anchors and css colors into account.
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
I guess the bug in someone in here:
Lovely, lovely. Let's get to it, people!
Edit: re-indexing has finished. Test: #phpBB
Code: Select all
$text= preg_replace_callback( '/(^|style="[^"#]+|[^\\s]*[\\s]+|>)#([\\p{Lu}\\p{Ll}\\p{N}\\w\\d]+)\\b/um', 'hashtag_callback', $text );
Edit: re-indexing has finished. Test: #phpBB
-
- Location: Germany
- Main keyboard: G80-3000LQCDE-2 w/ SKIDATA+
- Main mouse: Logitech B100
- Favorite switch: M Buckling spring, so far
- DT Pro Member: 0247
I think I figured out the part that damages the shortened links and shortened the match, but can't quite figure out how to exclude it from matches.
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
Fixed that, but not historically. I cheated by replacing # with ⌗ (viewdata square) in the url shortener code. But that is invoked upon save of a post, not render.Rimrul wrote: ↑It also affects urls with anchors, i.e.
https://www.phpbb.com/community/viewtop ... #p13329580
- Ratfink
- Location: North Carolina, USA
- Main keyboard: IBM Displaywriter
- Main mouse: CST L-Trac
- Favorite switch: Beam Spring
- DT Pro Member: -
Could you maybe just make the URL get shortened to something like this (no spaces around the ellipsis)? https://www.phpbb.com/community/viewtop…#p13329580webwit wrote: ↑Fixed that, but not historically. I cheated by replacing # with ⌗ (viewdata square) in the url shortener code. But that is invoked upon save of a post, not render.Rimrul wrote: ↑It also affects urls with anchors, i.e.
https://www.phpbb.com/community/viewtop ... #p13329580
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
- kbdfr
- The Tiproman
- Location: Berlin, Germany
- Main keyboard: Tipro MID-QM-128A + two Tipro matrix modules
- Main mouse: Contour Rollermouse Pro
- Favorite switch: Cherry black
- DT Pro Member: 0010
Ratfink wrote: ↑Okay, here's my proposal. Make the tags by writing a # before the word in your post as it currently works, but hide the # when actually displaying the post. That would fix my major complaint, which is that all those # characters are an eyesore.
Hell, if people actually want to see them, then do what I said above, but give the tag links a class like .hashtag, and add a CSS rule like:
[…]
Then I could remove them with a custom stylesheet, but everyone who isn't a crotchety young man can leave them in place.
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
I see your point, but the # is also an indicator that it leads to a search of the keyword following it. Otherwise it could be any link. It's also now sort of a standard interface element to denote such links, so to change it to a grey link or something would not work either. It's all or nothing basically. If you or some other club member feels strongly about it, start a club vote, "hash tags, yes or no."Ratfink wrote: ↑but hide the # when actually displaying the post.
#complaintdepartment
- ohaimark
- Kingpin
- Location: USA
- Main keyboard: Siemens G80 Lookalike
- Main mouse: Logitech G502
- Favorite switch: Blue Alps
- DT Pro Member: 1337
Is there any way to resolve numbers with the pound sign, such as #14, being transformed into searchable links?
Perhaps you could limit the feature to strings that have alphanumeric characters, not just numeric characters?
Perhaps you could limit the feature to strings that have alphanumeric characters, not just numeric characters?
- webwit
- Wild Duck
- Location: The Netherlands
- Main keyboard: Model F62
- Favorite switch: IBM beam spring
- DT Pro Member: 0000
- Contact:
It would be possible, but someone would then complain their #1337 hashtag or whatever isn't working.