Module BBCode Tag Search
Posted by Usatyj
All files from this thread
File Name | File Size | Posted by | Date | ||
---|---|---|---|---|---|
bbcode_tag_search.zip | 2.3 KB | open | download | Usatyj | 02/20/2012 | Read message |
image1.jpg | 57.1 KB | open | download | Ispau | 12/11/2014 | Read message |
image2.jpg | 103.9 KB | open | download | Ispau | 12/11/2014 | Read message |
Module BBCode Tag Search February 20, 2012 06:50AM |
Registered: 12 years ago Posts: 3 |
Hi!
Tis is my little mod to make tags in messages.
It makes tags marked with # before as link to the search page.
Source copied from module BBCode Video from Maurice Makaay <maurice@phorum.org>.
Example:
becomes:
Hello #world!
This is #tag to search.
Just #click me.
[/code]
Real page example:
[kazanauto.ru]
Tis is my little mod to make tags in messages.
It makes tags marked with # before as link to the search page.
Source copied from module BBCode Video from Maurice Makaay <maurice@phorum.org>.
Example:
Hello #world! This is #tag to search. Just #click me.
becomes:
Hello #world!
This is #tag to search.
Just #click me.
[/code]
Real page example:
[kazanauto.ru]
Re: Module BBCode Tag Search December 09, 2014 09:24AM |
Registered: 10 years ago Posts: 5 |
Hi Usatyj,
I was just looking for something like this. I think it's really useful. I have one question, maybe you can helpme with this... When I use the bbcdoe tag search, the Search returns me all messages that contains the tag, but without the character "#".
I mean if I have posted #test, I can find all messages that contains the word "test". But I would like to find all messages that contains the word with the hashtag like "#test" (as a mark). Not only "test". I tried to modify the php code but I can't find characters like "#" in the phorum. Could you have some idea?
Thanks!!
I was just looking for something like this. I think it's really useful. I have one question, maybe you can helpme with this... When I use the bbcdoe tag search, the Search returns me all messages that contains the tag, but without the character "#".
I mean if I have posted #test, I can find all messages that contains the word "test". But I would like to find all messages that contains the word with the hashtag like "#test" (as a mark). Not only "test". I tried to modify the php code but I can't find characters like "#" in the phorum. Could you have some idea?
Thanks!!
Re: Module BBCode Tag Search December 10, 2014 10:07AM |
Registered: 10 years ago Posts: 5 |
The tag color is not working... with this module. Any idea?
Instead of this:
Test of red color
The message show this:
I tried to apply the solution of Maurice Makaay in threath [www.phorum.org] but it doesn't work...
Note: I have the versión Phorum 5.2.14
Edited 3 time(s). Last edit at 12/10/2014 11:59AM by Ispau.
Instead of this:
Test of red color
The message show this:
Quote
[color=#990000] Test of red color[/color]
I tried to apply the solution of Maurice Makaay in threath [www.phorum.org] but it doesn't work...
Note: I have the versión Phorum 5.2.14
Edited 3 time(s). Last edit at 12/10/2014 11:59AM by Ispau.
Re: Module BBCode Tag Search December 10, 2014 04:49PM |
Admin Registered: 22 years ago Posts: 9,240 |
Re: Module BBCode Tag Search December 11, 2014 09:05AM |
Registered: 10 years ago Posts: 5 |
Hi Tomas,
First of all, thanks for your response. So, I will try to explain better.
I have enabled "BBcode" module, in fact I've never disabled it. You can see it in the attached file "image1.jpg".
The point is when I enabled the module "BBCode Tags Search" it works almost perfectly, but it causes that all texts that I have with some tags, specifically the tag "color" do not display correctly in all messages. But BBcode is still enabled! And if I disable "BBCode Tags Search" again, the tag color is shown correctly as before! It's very strange no??
Then, I have checked which part of the code "BBCode Tags Search" in bbcode_tag_search.php causes this problem. And I have detected that the next lines causes this problem. (I suppose that are the same lines which gives the format "#" to the URL)
if (isset($message["body"]) && strstr($message["body"], "#")) {
$data[$id]["body"] = preg_replace_callback($search, "search_str_encode", $message["body"]);
}
Ok, after that I was looking for a solution and I read in another post that exist a possible problem related with the modules "order" (the module might run after the bbcode module and causes this problem in the tags) You can see it in the attached file "image2.jpg" file.
Then I tried to apply this solution of Maurice Makaay (enabling the module "BB Code always as last formatter" as you can see in "image1.jpg" as well) but it was not successful and at the moment I don't know how to fix the problem.
I hope I explained better, but if you have any question I will answer quickly.
Thanks and best Regards,
Isaac
Edited 1 time(s). Last edit at 12/11/2014 09:07AM by Ispau.
First of all, thanks for your response. So, I will try to explain better.
I have enabled "BBcode" module, in fact I've never disabled it. You can see it in the attached file "image1.jpg".
The point is when I enabled the module "BBCode Tags Search" it works almost perfectly, but it causes that all texts that I have with some tags, specifically the tag "color" do not display correctly in all messages. But BBcode is still enabled! And if I disable "BBCode Tags Search" again, the tag color is shown correctly as before! It's very strange no??
Then, I have checked which part of the code "BBCode Tags Search" in bbcode_tag_search.php causes this problem. And I have detected that the next lines causes this problem. (I suppose that are the same lines which gives the format "#" to the URL)
if (isset($message["body"]) && strstr($message["body"], "#")) {
$data[$id]["body"] = preg_replace_callback($search, "search_str_encode", $message["body"]);
}
Ok, after that I was looking for a solution and I read in another post that exist a possible problem related with the modules "order" (the module might run after the bbcode module and causes this problem in the tags) You can see it in the attached file "image2.jpg" file.
Then I tried to apply this solution of Maurice Makaay (enabling the module "BB Code always as last formatter" as you can see in "image1.jpg" as well) but it was not successful and at the moment I don't know how to fix the problem.
I hope I explained better, but if you have any question I will answer quickly.
Thanks and best Regards,
Isaac
Edited 1 time(s). Last edit at 12/11/2014 09:07AM by Ispau.
Re: Module BBCode Tag Search December 18, 2014 01:57PM |
Registered: 10 years ago Posts: 5 |
Sorry, only registered users may post in this forum.