AndrewD |
08-05-2007 05:35 PM |
Quote:
Originally Posted by itsblack
(Post 1310374)
Yes, I've uploaded the newset version. I guess maybe it has someting to do with the language? Because I found that you use word "Dicussion" to check the threadid, but unfortunately I've translated it into chinese. What surprised me is, a) after the codes in local_links_actions.php, when there is already $row['linkthread' (I checked the database, some items have this), it should work without check the phrase, but it doesn't; b) Sometime before it works for me, although I use the chinese version all the time.
I have also tried to delete "Dicussion" in the code (local_links_actions.php, line 2232), but it doesn't work.
|
I recall how all this developed now.
In the earlier versions of the 'extra', there was no special database field for the associated thread, so the code had to check for the relevant text (threadid=..) in the body of the link description. In 2.2.7, I realised that this was definitely a kludge, so added a an extra column in the database.
I imagine that you'll find that comments work with those entries where the linkthread column is set, and don't work where it is blank. But (on the assumption that you haven't got a load of threadid bb codes in your LDM descriptions, it should be ok to modify the regular expression, as follows. Instead of
Code:
elseif ($forumid>0 and preg_match("/\[thread=(\d+)\]Discussion/", $row['linkdesc'], $match)) {
try
Code:
elseif ($forumid>0 and preg_match("/\[thread=(\d+)\]/u", $row['linkdesc'], $match)) {
(there's an extra 'u' after the second slash)
Can you let me know if this solves it, and if my theory is correct about the linkthread field?
|