5
I have just hooked into the search function of each module and added a table to the News module with the following appearance:
CREATE TABLE `news_link` (
`linkid` int(12) unsigned NOT NULL auto_increment,
`storyid` INT(12) NOT NULL,
`link_module` INT(12) NOT NULL,
`link_link` varchar(120) NOT NULL default '',
`link_title` varchar(70) NOT NULL default '',
PRIMARY KEY (`linkid`)
) TYPE=MyISAM;
there are some shortcomings such as:
1. If the linked item is deleted, the link persists as everything is duplicated (title and link) in this table (I can put in something extra in the deletion process of a News article, but I cannot do the same with e.g. forum threads or weblinks)
2. If the linked item's module is deactivated or uninstalled, I assume that it will break things (I haven't tested this yet, but I guess I will get some calls to non-member functions because the module object will not exist)
3. A story can be linked to itself (but I'll put in a chek for that)