Page 1 of 3

141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 03, 2008 7:44 pm
by SanderKromwijk
Hi,

I have already done tasks 127 and 130, so no need to introduce myself  ;D

Sander Kromwijk

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 03, 2008 9:06 pm
by SanderKromwijk
Hi,

JWChat needs http polling or http binding to work. The programs who can do this require access to the apache config file, and some need tomcat or python installed. If I write an extension, it will only work for people who have their own server or at least one where they can install programs (-> root access), which makes it impossible to use for most poeple who have a virtual web server.

Sander Kromwijk

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 03, 2008 11:17 pm
by AmyStephen
Ew. Not good.  :P

This is the second "wish list" item that didn't turn out well.

What about Jabber integration?

http://www.phpclasses.org/browse/package/995.html

http://www.phpbb.com/community/viewtopic.php?t=43942

What do you think?

Amy

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 04, 2008 3:14 pm
by SanderKromwijk
What do you mean? Do you want a button that brings you to a vcard of the author in Jabber (as in the phpBB conversation) or a Jabber client using the jabber.class.php class?

Sander Kromwijk

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 04, 2008 3:19 pm
by AmyStephen
I just did a quick search on what I hoped might be a workable extension to provide chat ability on a site.

No button for vcard.

What are your thoughts on the jabber.class.php class? What could you provide with that? What is your interest in doing so?

We are reinventing your task, here, so please let me know what is of interest. You could also look around - see what you think might be good. Do not hesitate to recommend something.

Thanks!
Amy :)

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 04, 2008 3:53 pm
by SanderKromwijk
I've looked at the classes, but a jabber or a XMMP server is always necessary. The only way I could make a chat program, is if the user has such a server installed or can install programs on the server.

Sander Kromwijk

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 04, 2008 4:09 pm
by AmyStephen
Sander -

One thing people ask about a lot is a Private Messaging System for J! v 1.5.

What if you designed a way that users on a Joomla! website could message one another? It could be like the forum's private mail, add email capability, if they choose?

Kevin Devine has a User Meta System Plugin that allows you to define parameters for the User that might be helpful too.

Just brainstorming - but if you are up for this challenge - it WOULD get use.

Amy :)

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 04, 2008 4:27 pm
by SanderKromwijk
Ok, I think I can try. What kind of extension should it become (component or a module, I haven't understood the difference yet)?

Sander

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Sun Jan 06, 2008 6:42 am
by AmyStephen
Cool! Thanks Sander. I look forward to watching your progress!

Amy :)

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Sun Jan 06, 2008 2:07 pm
by SanderKromwijk
Hi,

Here's my first version.

Sander

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Sun Jan 06, 2008 7:59 pm
by SanderKromwijk
Hi,

Here's my second version. It is now possible to send the same message to multiple users by seperating their names by a comma (no space after the comma).

Sander

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Sun Jan 06, 2008 8:12 pm
by AmyStephen
I sure do love what you have so far. It made me SMILE and I really needed a smile today, so thanks so much.

This is a very advanced task!

The send and receive worked great - I can send a member a note - and they can get it. Woot!!!!

Now, I assume as you continue, you will break that apart into a MVC framework, create a router for your component and hook into the core router so that all the various types of URLs work. For example, getting the display put into a layout file will make this component ready for template overrides - for those who don't want tables.

It would also be nice to have a user list to choose from, if possible.

There are things that could be offered using Kevin's User Meta Plugin, too, where someone could request PM's are emailed or not, or that they are even possible, or not.

But, I am guessing you are already thinking of such things and it is *very* impressive to see what you have accomplished in such a short period of time.

In terms of popularity, this will be RED HOT. There are CONSTANT posts in the forums looking for a J! v 1.5 Private Messaging System. Amazing work already.

Thanks so much,
Amy :)

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Sun Jan 06, 2008 8:15 pm
by SanderKromwijk
AmyStephen wrote: Now, I assume as you continue, you will break that apart into a MVC framework, create a router for your component and hook into the core router so that all the various types of URLs work. For example, getting the display put into a layout file will make this component ready for template overrides - for those who don't want tables.
??? I haven't quite understood the part about the MVC framework and the router part.

Sander

Re: 141 - Implement JWChat as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Sun Jan 06, 2008 8:47 pm
by AmyStephen
Look closely at com_weblinks and still if the structure makes sense.

Also, Ian put together a tutorials series on MVC. (Hello World MVC 1 Component through Hello World MVC 4 Component).

We might be able to get his assistance if you have specific questions, too. Given your obvious skill and since I believe this will be very popular, I recommend you look at this framework for this component.

Do not hesitate to ask questions as you go along, too. It will also help others learn as they follow along.

Amy :)

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Mon Jan 07, 2008 8:40 pm
by SanderKromwijk
Hi,

Does the MVC framework also work with editing on the "client" side, which is necessary for my program? Because then the toolbar buttons don't exist, so I think it will be a bit harder. Would it also be OK if I make my own code without controller, but which supports templates?

Sander

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Mon Jan 07, 2008 8:45 pm
by SanderKromwijk
Hi,

Is it possible to merge two extensions? For example, put the UserMeta extension in the extension so it installs with only one file. Or put a module and a component in one package.

Sander

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Mon Jan 07, 2008 9:14 pm
by ianmac
SanderKromwijk wrote: Hi,

Does the MVC framework also work with editing on the "client" side, which is necessary for my program? Because then the toolbar buttons don't exist, so I think it will be a bit harder. Would it also be OK if I make my own code without controller, but which supports templates?

Sander
Yes, you can do anything with the MVC framework that you can do in a component using the old design pattern.

How are you calling your component from the frontend now?

We would like to see the component designed in MVC.

Ian

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Mon Jan 07, 2008 9:15 pm
by ianmac
SanderKromwijk wrote: Hi,

Is it possible to merge two extensions? For example, put the UserMeta extension in the extension so it installs with only one file. Or put a module and a component in one package.

Sander
No, that is not possible in the current release.

Ian

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Mon Jan 07, 2008 9:29 pm
by AmyStephen
Sander -

On the UserMeta extension, it's best to add instructions for the site developer to install it and how to add specific parameters you require. It is a good extension to create a group blog/social networking app using Joomla! and your component will likely be just one of many extensions configured "per person."

I agree with Ian on the MVC preference and, given the resources mentioned, and with Ian's help, I absolutely believe you are capable of doing that. There are lots of benefits to doing it that way, one of which I already mentioned with the ability to define different layout files.

This is already looking like an amazing extension, Sander. Good work!
Amy :)

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Wed Jan 09, 2008 6:19 pm
by AmyStephen
Sander -

Want some assistance thinking through how best to split this into an MVC component - and module. Or, are you doing okay? Don't forget, we are here to help you be successful with your task. It holds much value for the community.

Thanks, again!
Amy :)

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Wed Jan 09, 2008 8:24 pm
by SanderKromwijk
Hi,

I haven't managed to rewrite the component in the MVC framework yet. I've been trying to start off from the Hello World tutorial, but now each time I try to install, the program tells me it can't find the install file.

Sander

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Wed Jan 09, 2008 9:00 pm
by SanderKromwijk
Hi,

The problem I mentionned above was an error I made. I forgot to close an xml tag.  :-[
But now I have another problem. When I try to install, the installer returns the following error message: "# Component Install: SQL error or missing or unreadable SQL file. DB function reports no errors". I've checked the mysql files in phpmyadmin, but they work. Could someone help?

Sander

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 10, 2008 6:53 pm
by SanderKromwijk
Hi,

For some reason the install works fine now. I really don't understand this as I haven't changed the file since the last time I tried, but it works. I'll have to debug it a little, then I'll post it.

Sander

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 10, 2008 6:59 pm
by AmyStephen
Sorry, Sander!  :-[

I'm glad you are moving forward, though. Thanks!

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 10, 2008 7:38 pm
by SanderKromwijk
Hi,

How can I insert an entry into a mysql table? I took the code from the HelloWorld tutorial, but it won't work. It returns "Table message not supported. File not found.", but the class TableMessage exists and is declared. The file is also at the right place (tables/message.php). What could the problem be?

Sander

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 10, 2008 7:41 pm
by AmyStephen
Sander -

Can you link me to the tutorial you are using, and I will try to catch up and go through it as you are going through it? That way, I'm not so lost when you have a question.

Did you start on the Developing a Model-View-Controller Component - Part 1 page? And, if so, what step are you now on?

Thanks!
Amy :)

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Thu Jan 10, 2008 8:03 pm
by SanderKromwijk
Hi,

I was using the Model-View-Controller Component tutorial. I'm currently using the code of the 4th part. (http://dev.joomla.org/component/option, ... orld_mvc4/)

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 11, 2008 6:34 pm
by SanderKromwijk
Hi,

I converted a part of the messaging program into the MVC framework. But there are parts that won't work:
- When sending a message, it reports it doesn't find the table file.
- When you click on a message, you should be brought to a view of the message. But the program returns the new message form. It doesn't even seem to call the ViewMessage model.

So here is the program with these (very slight  :P) bugs. Could someone help me?

Sander

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 11, 2008 9:13 pm
by depresz
It's so interesting extension. I have to take a look on it.
Tommorow I'll give you an anserw.

Re: 141 - Implement Private Messaging as a Joomla! v 1.5 extension(s) (Advanced)

Posted: Fri Jan 11, 2008 10:10 pm
by SanderKromwijk
Hi,

Thanks for offering help depresz! But I've found a way to work around the problem. It now works. Here is the new version. It is possible to send messages and to read them. I will now work on the possibility to delete messages.

Sander