Page 1 of 1

135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 21, 2007 8:38 pm
by milosz.lewandowski
Hi,
this is my second GHOP task. Details of the task:
One line summary

Create a Joomla! v 1.5 Module to implement Technorati searchlet.
Describe the task.

The Technorati searchlet enables site-specific and weblog search across
Technorati's entire database of posts. The module must allow the site
developer to customize a Technorati searchlet and add Technorati's search
capability to your site's existing search options. Allow the site developer
to configure options identified in the "Walk-through" section.

Resources:

    * Technorati

  # Searchlet - http://www.technorati.com/developers/he ... chlet.html

    * To install Joomla! on an XAMPP localhost:

  # XAMPP - http://www.apachefriends.org
  # Download Joomla! - http://help.joomla.org/content/view/1942/302/
  # Install Joomla! on a localhost -
http://help.joomla.org/content/view/1947/306/

    * Coding resources:

  # The core code! :-)
  # Plugins - http://forum.joomla.org/index.php?topic=233628
  # Model View Controller -
http://dev.joomla.org/component/option, ... orld_mvc1/
  # Modules and Components - http://www.jlleblanc.com/blogcategory/0/
  # Internationalization -
http://forum.joomla.org/index.php/topic ... msg1102267

    * IRC #joomlaGHOP on freenode

Skills needed

    * Knowledge of PHP
    * Knowledge of Joomla! v 1.5 Extension Development
    * Creativity and problem solving skills

Difficulty

Basic
Work Product

    * Installable Joomla! v 1.5 extension(s) with internationalization
support.

Licensing

All code must be created using the GNU General Public License version 2.
http://www.gnu.org/licenses/old-license ... .html#SEC4

Documentation written for this task must be made available under the
Joomla! Electronic Documentation License.
Extra Credit (Optional)

1. Register your project at Joomlacode
2. When you are ready to release, submit your extension to the Joomla!
Extensions Directory.

Time Limit

2 weeks.

Milosz

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sat Dec 22, 2007 7:26 am
by AmyStephen
Thanks, Milosz - great task! Looking forward to seeing what you accomplish! Ask questions, if you have them.

Good luck,
Amy :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 5:59 am
by AmyStephen
How are things coming, Milosz?

An update would be appreciated (code would be thrilling ;) )

Amy :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 2:45 pm
by depresz
If you need help Mi³osz, I am open  :pop
we can talk by PM, gadu or something like that.

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 3:55 pm
by milosz.lewandowski
Modules for Joomla! are quite easy. However, I would like to write full code and then send it. I suppose it will be on Monday :)

I don't have questions. I found all informations about Joomla! Modules which I needed :)

Milosz.

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 4:27 pm
by milosz.lewandowski
IMPORTANT QUESTION:

I noticed that Technorati changed their search method. Searchlet don't work and I'm afraid that it isn't easy to build new searchlet by html form. URL after change ('test' is a query): http://technorati.com/search/test?autho ... anguage=pl

Amy, should I try to write new searchlet code, write to the Technorati and ask about it or something else?

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 8:47 pm
by shantanubala
I'm sorry if I'm not completely understanding the technorati searchlet, but after looking at the code

Code: Select all

<form method="get" action="http://technorati.com/search.php">
<fieldset>
<legend><a href="http://technorati.com/">Technorati</a> search</legend>
<input type="hidden" name="sub" value="searchlet" />
<input type="text" name="s" maxlength="255" value="" />

<label for="ts_yb" title="BLOG TITLE">
 <input type="radio" checked="checked" name="from" id="ts_yb" value="BLOG BASE URL" />
 this blog</label>
<label for="ts_www">
 <input type="radio" name="from" id="ts_www" value="" /> all blogs</label>
<input type="submit" value="Search" />

</fieldset>
</form>
A module would need to implement that code onto the page's sidebar (or wherever the module is placed) by allowing the user to change the blog title, blog url, and other information required by the searchlet through a interface in the Joomla! backend. The module itself may need to create database tables or otherwise use some method of storing that information. Just a thought. Pardon if I'm misunderstanding the goal of this task.

-Shantanu

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 8:58 pm
by milosz.lewandowski
Oops. They fixed it :) Few hours ago it didn't work ??? So, I go back to work :)

Milosz :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 10:24 pm
by AmyStephen
Excellent! Thanks Shantanu, glad to see you "walking around" and seeing what else is going on, very cool.

Amy :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Dec 28, 2007 11:39 pm
by shantanubala
AmyStephen wrote: Excellent! Thanks Shantanu, glad to see you "walking around" and seeing what else is going on, very cool.

Amy :)
I'm also scouting the boards for other people's works that may make good additions to my task. The more the merrier, and I'll gladly help along the way!

As far as the technorati goes, there are multiple ways to configure the searchlet since the code seems very, very, customizable.

A good idea is to give users different layout options and configurations - allowing a user to customize the search box similar to Google's method --> Image

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sat Dec 29, 2007 10:38 am
by milosz.lewandowski
Yes, Shantanu, I'm going to add to this module so many configuration options as it is possible. Not only mentioned in the "Walk-through" section, but also - as you said - style configuration, or, for example, searching only particular, other blog.

Please, Amy, Shantanu, or somebody, check the searchlet. Today it don't work again. Yesterday it redirected from /search.php to /search/searchlet or something like that. It's available at http://www.oczyszczalnieogrodowe.pl/lew ... orati.html.

Edit 12:00: Searchlet worked again minutes ago, but it don't work now. I suppose they are changing their search engine, but I think that it will work stable soon. I'll work with searchlet code without changes.

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sat Dec 29, 2007 4:00 pm
by shantanubala
Hmm. It didn't work completely - I entered in "Bhutto" as in the Pakistani official who was assassinated... I know it would've been in at least one blog on the Technorati network.

It simply redirected me to Technorati.

After searching on Technorati's actual site, it returned results....

The searchlet doesn't seem to work. It's very erratic in its behavior.

If you need any more help, just PM me or post in this thread. I'm interested to see how this turns out.
-Shantanu

EDIT - Corrected a typo

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sun Dec 30, 2007 3:44 pm
by depresz
Seems that everything work now.

Code: Select all

http://technorati.com/search/XXX(?from=XXX)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sun Dec 30, 2007 8:34 pm
by milosz.lewandowski
Technorati Searchlet Module coming soon - tomorrow I think 8) But I have one question: is there possibility to install module language file automatically? I have language file in the /language/en-GB/ folder of my zipped module and in the mod_technorati_searchlet.xml file this code:

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<install type="module" version="1.5.0">
...
<files>
...
	<filename>language/en-GB/en-GB.mod_technorati_searchlet.ini</filename>
...
</files>
Thank you :)
Milosz

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sun Dec 30, 2007 8:39 pm
by depresz
In xml you have path language/en-GB.
Place your en-GB.mod_technorati_searchlet.ini file inside en-GB folder, not language.
In language you have to create first additional dir called en-GB.

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sun Dec 30, 2007 8:41 pm
by milosz.lewandowski
Sorry, I've maid a mistake in my post, it is as you said and it don't work.

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Mon Dec 31, 2007 11:28 am
by milosz.lewandowski
MOD.TECHNORATI_SEARCHLET - First beta version

Hi,

attached beta version of my module. Please check it for errors. Suggestions are also needed ;)

This version contains layout and features functions, but without style functions. It will be finished in a few days. Available languages are English and Polish, however it don't seem to install automatically. There are in /language/ directory.

Tested on Joomla 1.5 RC4 Karibu.

Milosz :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Mon Dec 31, 2007 11:46 am
by depresz
According to languages:

In XML file you should place language file inside :

Code: Select all

    <languages>
	<language tag="en-GB">language/en-GB/en-GB.mod_technorati_searchlet.ini</language>
	<language tag="pl-PL">language/pl-PL.mod_technorati_searchlet.ini</language>
    </languages>
not in

Code: Select all

		<filename>language/en-GB/en-GB.mod_technorati_searchlet.ini</filename>
		<filename>language/pl-PL/pl-PL.mod_technorati_searchlet.ini</filename>
Therefore you don't have language support!

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Mon Dec 31, 2007 12:00 pm
by milosz.lewandowski
Thanks depresz ;) So attached:

MOD.TECHNORATI_SEARCHLET Beta 1.1

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Tue Jan 01, 2008 5:30 am
by AmyStephen
This is very, very good. There are only a few *minor* issues I want to point out.

1. In general, I think you will want to add the JURI::base() to your file references (images, module files, CSS, JS, etc.).

If you are installed on http://localhost/Joomla, then JURI::base() returns Joomla and is needed to directly link to these files.

2. I wonder about the getSiteBaseURL function in modules/mod_technorati_searchlet.

Check out what depresz did in his Twitter plugin.

3. Searching a specific blog does not appear to work (i.e., it doesn't carry forward the blog name into Technorati.)

4. Layout odd - when a) show fieldset NO b) default for query box and size c) yes other blog - title and URL d) image button with Go! and e) no graphic.

Very, very nice.
Amy :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Jan 04, 2008 7:17 pm
by milosz.lewandowski
I remember that this evening is the end of my time limit ;) So attached:

MOD.TECHNORATI_SEARCHLET RC1

Updates:
  • JURI::base() in file references and getSiteBaseURL function
  • new layout function - show graphic and button in the same line (table)
  • you can change align of button and graphic when it is in the separate line
  • selection this site/other blog has now 'small' css class
  • default values (in .xml file) of fieldset legend and button text are in English. Strings from language file don't work in default="" argument
TODO (mod final version, this evening at 23:00):
  • advanced style options. It will be style="" content for few elements. Amy, is it good to keep this CSS informations in the searchlet code, not in CSS stylesheet file? I have no ideas about dynamic CSS stylesheet.
AmyStephen wrote: 3. Searching a specific blog does not appear to work (i.e., it doesn't carry forward the blog name into Technorati.)
The blog name isn't forwarded to Technorati, only base url. By the way, searchlet only sometimes works, as I mentioned few days ago.
AmyStephen wrote: 4. Layout odd - when a) show fieldset NO b) default for query box and size c) yes other blog - title and URL d) image button with Go! and e) no graphic.
If you meant that button isn't vertically aligned to center, it won't work when the button isn't in the table. I can put the button in the table, but it won't be in the same line...


Milosz

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Fri Jan 04, 2008 10:20 pm
by milosz.lewandowski
And here it is! :)

MOD.TECHNORATI_SEARCHLET FINAL VERSION

Please check it and post your questions.

Milosz :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sun Jan 06, 2008 6:28 am
by AmyStephen
Milosz -

This is excellent! The way that you did the CSS is very, very flexible and easy for people to update.

This extension worked great for me. It has a rich array of options to choose from. It's a great blogger type of extension and very much needed for Joomla! v 1.5. I hope you will make certain to add it to the JoomlaCode and Joomla! Extensions Directory. I hope it gets lots of good use!

Please post your final version on the Google Task page. As an FYI, Elin just added 10 new testing tasks that must be done in two days. You might want to consider taking one after I finalize your Google task.

Thanks for your contributions to our community - you are very talented! Task complete.
Amy :)

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Sun Jan 06, 2008 9:53 am
by milosz.lewandowski
Hi all :)

Amy, Shantanu, Depresz - thanks for your help in my task.

I've uploaded my module at the task site. I'll upload it at JoomlaCode and Joomla Extensions Directory ASAP and inform you by this thread and GHOP Issue 135 site.

Best wishes,
Milosz

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Mon Jan 07, 2008 8:35 pm
by milosz.lewandowski
Joomla Code site: http://joomlacode.org/gf/project/mod_technorati/frs/
Joomla Extensions Directory: pending for administrators approval.

EDIT: Joomla Extensions Directory: http://extensions.joomla.org/component/ ... Itemid,35/

Re: 135 - Create a Joomla! v 1.5 Module to implement Technorati searchlet.

Posted: Mon Jan 07, 2008 11:36 pm
by AmyStephen
Wonderful!!!!  8)

Again, thank you for your contributions to the Joomla! community!
Amy :)