Website Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • August 30, 2015, 11:45:35 PM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Last post Author Topic: DC SMF Search Mod - an improvement search for smf forum (codename Zillarank)  (Read 44740 times)

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,933
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Here's the description by smf of their licensing choices, which always seemed pretty reasonable to me, and it's why i never worried about this issue:
http://www.simplemac...about/opensource.php

I can understand their expressed desires and don't have a problem with them.

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Philosophy is philosophy, a good read it may be; terms are terms, that we have to abide by.  :)

Read: Microsoft and Open Source

I dont see any part of the above SMF and Open Source write-up that cannot be justified with "we're closing source and charging for it because only experts are coding it and there's no fork to confuse users -- a win-win situation".

tinjaw

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 1,927
    • View Profile
    • Read more about this member.
    • Donate to Member
I AN NOT A LAWYER blah, blah, blah

Wordzilla,

Whenever I try to explain something like this, it always seem to come out as criticism, so I apologize as it is not intended to be such. However, since there are many readers of DonationCoder.com that may be new to these types of legal issues, I just wanted to mention that you should not have any problem with the code being copyrighted, per se. Even software from FSF, Apache, etc. is copyrighted. The copyright shows ownership, and the license tells you how you can use it. Without copyright, you have no ownership, and without ownership nobody would have to right to license the code. So, even if you write code yourself, you would not be able to put a license on it, not be able to tell people how they could use is it, nor could you tell them how they could not use it, *unless you claimed it as yours via copyright*. (Which under US law you can do to anything you create by simply affixing the copyright logo and/or the words copyright year whoever. If it is important enough, you should consult a lawyer after that. Because that is just the first step. There are more if you want it to be enforceable.)

So 1) always copyright what you write (as you can always release it to the public domain later, but it doesn't work the other way around.) 2) If you want it to stick in court, consult a lawyer.

Then, after you claim ownership, you can license it to others, for example, under the GPL v3, or the Apache license, or BSD, or any of the other gazillian licenses out there.

I am not an expert. There is a great deal more material out there on the Net and elsewhere, so if anybody is interested they should read further.

I just didn't want some of the people new to the issues at hand here to start out with a skewed concept that all copyright is evil.

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Read more about this member.
    • Donate to Member
So I'm saying it pays to study smf alternatives like phpbb3 (I'll try) and design our site components to be less reliant on SMF forum software.
Even though i do agree with what you're saying, i'm very sorry to hear it.
SMF forum software is miles away from any forum software i've used, and this means that a change would be a huge step backwards.

I have a doubt: are smf updates that important?
I mean, if they go payware, aren't we allowed to keep using an older version? And if we would do that, would we miss out on anything important?
From what i can see, if they don't even update their crappy search, i don't think we need them at all.

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,933
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Speaking just for myself:

I like smf.
We have donated to smf repeatedly.
I do not have a problem with paying for smf if they go to a pay model that is reasonable.

My concerns in this case are not about paying for stuff - i'm just objecting to what i perceive as an inappropriate attitude and approach from smf management, which i fear may be a sign of them moving in wrong direction in terms of management and maintenance.

Having said that, i agree with wordzilla that it is unwise to be so dependent on software that could overnight move to a license that would make it unusable.  But i think jgp's point is also valid -- we could always just stick with our current version if they did that.
« Last Edit: July 10, 2007, 03:52:48 PM by mouser »

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Quote
I am not an expert. There is a great deal more material out there on the Net and elsewhere, so if anybody is interested they should read further.
I just didn't want some of the people new to the issues at hand here to start out with a skewed concept that all copyright is evil.

Thx tinjaw, that makes up for my lackluster business law class ;)

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Yes I have no problem with SMF and I dont doubt it's the best forum software on the planet...so far.

I guess I'm just not a fan of meritocracy/elitism, which is SMF dev about, IMO.  :)

cranioscopical

  • Friend of the Site
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,300
    • View Profile
    • Read more about this member.
    • Donate to Member
Quote
A reply i posted which addresses some of the "why" issues that cranioscopical suggested i tackle...
and
Quote
My concerns in this case are not about paying for stuff - i'm just objecting to what i perceive as an inappropriate attitude and approach from smf management, which i fear may be a sign of them moving in wrong direction in terms of management and maintenance.

A lot of heat's been generated by a rude and ungrateful response from SMF. 'Un-words' abound for such behaviour, without a doubt; unintelligent, uncouth, uncooperative, unimaginative...

Even so,
Are you sure that, had you first sought a written permission it would not have been granted?
And are you sure that nobody in the SMF hierarchy is both senior enough to waive the requirement and intelligent enough to see the advantage in what you offer?

Anyway, many thanks -- again -- to you and Wordzilla for the very significant inprovements to the search function here.  Boy, what a difference!

spottedhog

  • Participant
  • Joined in 2007
  • *
  • gravatar avatar
  • Posts: 1
    • View Profile
    • Donate to Member
Hi,

I was "playing" online and came across your site.  With great interest I read this thread.  I have had similar experiences with SMF, however, I do understand their position.

Firstly, not to offend anyone here, but I think both sides are overreacting.  SMF's policy is showing, especially after the recent Joomla nonsense.  But SMF has been firm and never swayed in their position, since forever.  This is their way of keeping control and quality.  It is just the way it is. 

All SMF is saying is you must have permission to distribute their code.  Will they give you permission? Very highly unlikely....  Do they give you the tools and support to be able to make modifications to their code?  A resounding YES!

Do I like the idea of the package installer? Not really.... pain in the butt versus straight file replacement.  However, using the package installer has benefits if other Mods had change a specific file. 

Actually you have 2 choices here in distributing changes to their code. 
1. Is to somehow get the uninstall to work, and I feel confident someone on SMF could help. 
2. List the file modifications on your site here noting how to make changes.  In theory, you could list the entire file contents in a forum board where people can copy it and use it, as long as you do not remove the Copyright.

At this link:
http://www.simplemac...about/opensource.php
...there is a largely displayed, highlighted line that says:
Quote
You can modify the source code, distribute instructions to modify it, you can view the code and suggest improvements to it.

I have not seen nor used any of your SMF Mods, and right now I cannot see any of them.  I was hoping I could see them, hence, why I am here.  If you cannot get the package manager to properly uninstall, again, you could ask on SMF what to do, or you could maybe create a new board here, where only postings or comments could be made by the Mod developers.  Then the Mod developer could list the code, or sections of modified code.  Then members/visitors here could copy/paste the modifications.

.....just a thought.

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
OK guys, feel free to try latest mod 1.1.0.0 (uploaded)

Works with SMF 1.1.3

TjaMe

  • Participant
  • Joined in 2007
  • *
  • Posts: 2
    • View Profile
    • Donate to Member
Thanks a million 'zilla, your search mod is awesome! :D

I was trying to improve on the standard search myself, but got lost somewhere in between regexps & sql statements... I'm well impressed with what you've done in such a short period of time! More than well impressed, actually!  :D


I just couldn't resist modifying some of your code: I changed the following:


Code: PHP
  1.         if (!isset($search_params['match_mode']))
  2.                 $search_params['match_mode'] = empty($_REQUEST['match_mode']) ? 'smart' : $_REQUEST['match_mode'];
  3.                
  4.         if (!empty($search_params['match_mode']))
  5.                 {
  6.                         switch ($search_params['match_mode']) {
  7.                         case 'whole':
  8.                             break;
  9.                         case 'smart':
  10.                             break;
  11.                         case 'any':
  12.                             break;
  13.                         default:
  14.                                 $search_params['match_mode'] = 'smart';
  15.                             break;
  16.                         }
  17.                 }
  18.         else
  19.                 $search_params['match_mode'] = 'smart';
  20.  

to:

Code: PHP
  1.         if (!isset($search_params['match_mode']))
  2.                 $search_params['match_mode'] = $_REQUEST['match_mode'];
  3.                
  4.         switch ($search_params['match_mode']) {
  5.                 case 'whole':
  6.                 case 'smart':
  7.                 case 'any':
  8.                         break;
  9.                 default:
  10.                         $search_params['match_mode'] = 'smart';
  11.         }
  12.  

then copied it to PlusSearch1. It took me a while to notice that $context['search_params']['match_mode'] != $search_params['match_mode']

... maybe I should have resisted the temptation...  ;D

Thanks again for such a superb search engine. I seriously hope all the smf community try out your mod and realize what they've been missing all these years.

Credit where it's due. Wordzilla, you're a scholar & a gentleman, and I salute you, sir!
« Last Edit: August 07, 2007, 09:28:53 AM by TjaMe »

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Code: PHP
  1.         if (!isset($search_params['match_mode']))
  2.                 $search_params['match_mode'] = $_REQUEST['match_mode'];
  3.                
  4.         switch ($search_params['match_mode']) {
  5.                 case 'whole':
  6.                 case 'smart':
  7.                 case 'any':
  8.                         break;
  9.                 default:
  10.                         $search_params['match_mode'] = 'smart';
  11.         }
  12.  

Your code does look v neat, thanks for sharing.  :Thmbsup:

I have a question, thou:

What if $_REQUEST['match_mode'] isn't set (undefined index) before usage? Doesn't it generate a warning in forum log?

Code: PHP
  1.         if (!isset($search_params['match_mode']))
  2.                 $search_params['match_mode'] = $_REQUEST['match_mode'];
  3.  



I'm so happy it's working for you TjaMe!  :Thmbsup:

Care to post us the url to your forum here?  :)

TjaMe

  • Participant
  • Joined in 2007
  • *
  • Posts: 2
    • View Profile
    • Donate to Member
Ooops! :-[ You're absolutely right about the warning on the forum log!

I was in 'trim lines mode' & got carried away...   

:-\ I suppose that

Code: PHP
  1. if (!isset($search_params['match_mode']))
  2.     $search_params['match_mode'] = empty($_REQUEST['match_mode']) ? '' : $_REQUEST['match_mode'];
  3.  

is the smallest that snippet can ever get without generating a warning.

Drats!  :o

Our forum is behind a firewall on an intranet & deals with very, very boring stuff, but if we ever have a public side to it I'll post the url, I promise!

Thank you again for sharing your really excellent code!  :D
« Last Edit: August 08, 2007, 10:21:05 AM by TjaMe »

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Just uploaded the latest mod 1.1.1

Quote
Cleaned up code. Minor bug fixes. Added no single character search. Thanks to Aaron: http://custom.simple...ds/index.php?mod=884

Folks at SMF carefully reviewed the mod and offered me some constructive ideas yesterday, now the new mod is in better compliance with SMF coding guidelines. Hopefully it will be officially approved by SMF very soon.


To upgrade from an earlier version:
   1. go to the package manager and UNINSTALL previous version
   2. Upload new package zip
   3. install new version

cranioscopical

  • Friend of the Site
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,300
    • View Profile
    • Read more about this member.
    • Donate to Member
Quote
Folks at SMF carefully reviewed the mod and offered me some constructive ideas yesterday, now the new mod is in better compliance with SMF coding guidelines. Hopefully it will be officially approved by SMF very soon.

A glimmer of intelligence at the end of the tunnel?

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Yay, finally it's approved by SMF! :D :D

http://custom.simple...ds/index.php?mod=887

cranioscopical

  • Friend of the Site
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,300
    • View Profile
    • Read more about this member.
    • Donate to Member
Quote
Yay, finally it's approved by SMF!

Congratulations!  Both you and Mouser deserve credit for seeing this through.
Frankly, I don't much care about the SMF community as long as I benefit from your hard work.  :)
It is nice to share, though, and very much in keeping with the philosophy round here.

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,933
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
wordzilla is a true gentleman, he really worked hard to get it in shape so others could benefit from it.

iphigenie

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 1,169
    • View Profile
    • Read more about this member.
    • Donate to Member
ironically, i tried installing the package and it detects a conflict (probably with tinyportal)

 :-\

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Most likely. If possible send me a copy of your Sources/Search.php and I'll have a look. :)

MatthewSchenker

  • Participant
  • Joined in 2007
  • *
  • gravatar avatar
  • Posts: 24
    • View Profile
    • Festool Owners Group
    • Donate to Member
Does this modification work with 1.1.4?  I tried to install it but got errors, including a message that it not compatible with this version of SMF.
I realy like the work you have done and want to keep using this modification on my 1.1.4 site.
Thanks!

Wordzilla

  • Forum Search Daemon
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 470
  • Two there should be; no more, no less.
    • View Profile
    • FreeThesaurus.net - The Free Online Synonym Finder
    • Donate to Member
Does this modification work with 1.1.4?

Yes it's tested to work with SMF 1.1.4. What error messages did you get (exactly)?

MatthewSchenker

  • Participant
  • Joined in 2007
  • *
  • gravatar avatar
  • Posts: 24
    • View Profile
    • Festool Owners Group
    • Donate to Member
I think it was my fault.  After installing this modification, my entire site crashed.  But I have a feeling it was because I changed something in the post.template.php or index.template.php file.  I reinstalled my forum software, then reinstalled the search modification, and everything is working fine now.
Thanks for all the great work!!

Eddy Matthews

  • Participant
  • Joined in 2008
  • *
  • gravatar avatar
  • Posts: 3
    • View Profile
    • Donate to Member
Would it be possible to modify DCSMFSearch so that it also searches for attached files?

At the moment there is no way to search for any attached filenames etc, and it would be a great addition if it could be done?

Many thanks
Eddy

spismf

  • Participant
  • Joined in 2008
  • *
  • Posts: 2
    • View Profile
    • Donate to Member
Hi there,

Im a BIG fan of this search mod and have been using it for slightly over 7 months. now that 1.1.6 is out any chance you can upload an update? and will we have this awesome mod for 2.0?

-Jeff