From: Verdon V. <ve...@ve...> - 2005-05-04 14:38:01
|
Hi :) Previously I've done a lot of serious hacking to other people's mods, I'm now in process of trying to write one of medium sophistication completely from scratch (well, more or less ;). One thing I'm not sure of is when I should make a class an extension of PHPWS_Item and when I should not, or if there is any hard-set rule. In my specific case, I am writing a mod that facilitates online petitions. I have written one class for the actual petitions, which does extend PHPWS_Item. I am now working on the class for signatures and it is that one that I am unsure of how to handle. The signatures are not items that will ever be directly manipulated by a logged in user, per say. Basically, an annon visitor can fill in a form to sign the petition. They will then get an e-mail with a link to click, which when they do so, the signature record is updated to indicate status as verified. At any time, an admin will be able to go in to the site and get stats on the number of verified signatures, print lists, and so on. So, I guess what I'm asking is, is there any hard-set rules as to when it is best to make a class an extension of PHPWS_Item or not? I've read through many core and 3rd party mods, and although I see some similarities in approach, I don't really see a pattern. TIA for any advice. Best regards from Northern Ontario, Canada, verdon vaillancourt |
From: Eloi G. <el...@re...> - 2005-05-06 20:03:10
|
Maybe I missed something in your description, but I don't think you need a Signature class. The signatures themselves have no behavior - they're just (un)verified email addresses. The methods should stay on the Petition and the Petition Administration levels. Code reuse issues aside, you should try to keep the amount of classes used to a minimum. Web applications require a more performance-centric approach to design than desktop apps. If it can do really cool things, but only for 5 people at a time then its worthless on the 'net. There's no concrete rule on when to use PHPWS_Item. It's all a matter of your personal preferences and programming style. In my opinion, PHPWS_Item should only be used when you don't care about memory usage or execution time, and the class that you're making isn't so simple that you're not using at least 70% of PHPWS_Item's methods, and not so complex that you find yourself superclassing existing PHPWS_Item methods to get it to work the way you need it to. Other opinions may differ. -Eloi- |
From: Verdon V. <ve...@ve...> - 2005-05-07 03:18:55
|
Hi Eloi Thanks for the informative reply :) On 6-May-05, at 5:07 PM, Eloi George wrote: > Maybe I missed something in your description, but I don't think you > need a Signature class. The signatures themselves have no behavior - > they're just (un)verified email addresses. My description was oversimplified, there's a little more to them than that. Such as name, address, affiliation, comments, flags for 'may the signer be contacted' and 'allow signer's name to be public, id of petition the signature is related to'. The signatures have no behaviours per say, but it will be possible to get stats on # of verified, unverified, # per day. There will also be mechanisms for printing lists of name/address of verified signers, as well as sending one-time reminders to aged, unverified signatures. I'm also loosely thinking ahead to methods to send campaign letters and such. > The methods should stay on the Petition and the Petition > Administration levels. Code reuse issues aside, you should try to > keep the amount of classes used to a minimum. Web applications > require a more performance-centric approach to design than desktop > apps. If it can do really cool things, but only for 5 people at a > time then its worthless on the 'net. I'm all for bloat-free code and realize I may need to re-think my approach. I'm hoping to get off to as good a start as possible. > There's no concrete rule on when to use PHPWS_Item. It's all a matter > of your personal preferences and programming style. In my opinion, > PHPWS_Item should only be used when you don't care about memory usage > or execution time, and the class that you're making isn't so simple > that you're not using at least 70% of PHPWS_Item's methods, and not so > complex that you find yourself superclassing existing PHPWS_Item > methods to get it to work the way you need it to. Other opinions may > differ. Thanks for your opinion. It's appreciated and respected. I've tried writing both ways, and have read through a lot of other mods. It's good to hear the thoughts of others with a deeper experience than my own. regards, verdon > > -Eloi- |
From: Verdon V. <ve...@ve...> - 2005-07-19 17:48:27
|
Hi :) I'm in final stages of writing a mod for phpws, for podcasting. It will be released soon. I have some uncertainty what to do with categories and would welcome any opinions. Currently, with my mod, you can have 'channels' which have 'podcasts' (episodes) attached to them. The channels use fatcat categories. As far as I can tell from researching podcasting RSS, 'category' is an optional rss tag, in channels and/or items, as is 'itunes:category' of the subset itunes: which I am supporting to some extent. Many popular podcast feeds use no category tags at all though. Where my uncertainty comes in is that, AFAIK, I can use whatever I want for the rss <category> tag, so I'll use the fatcat category. However, if I want to support the <itunes:category> tag, there are specific itunes categories that must be adhered to. At this time, I have just hard-coded the <itunes:category> tags in the .tpl file. My questions are, does anyone know if my assumption about the wide-open nature of the rss <category> tag is correct, or should it be limited to specific categories like the itunes:category? Would using the fatcat category be appropriate here in a feed? And, do you have any other thoughts about the importance of using <category> and <itunes:category> in a rss feed in general? I don't really feel like building some kind if itunes:category support into the gui of the mod, and am beginning to feel that a note about using them in your .tpl files, if you wish to, may be all I should bother with ;) Thanks, verdon |
From: Shaun M. <sh...@ae...> - 2005-07-19 19:12:09
|
Maybe have some kind of fatcat to itunes category mapping so in phpWebSite you can have any categories you want but you can map specific categories onto specific music categories as required by the iTunes podcast directory? May as well use the same iTunes categories for the non itunes tags too. Or just stick a list box with all the itunes categories in the interface and let people pick the one they want as well as fatcat category. I presume you've read the updated specs... http://phobos.apple.com/static/iTunesRSS.html Shaun aegis design - http://www.aegisdesign.co.uk |
From: Verdon V. <ve...@ve...> - 2005-07-19 19:41:26
|
On 19-Jul-05, at 3:12 PM, Shaun Murray wrote: > Maybe have some kind of fatcat to itunes category mapping so in > phpWebSite you can have any categories you want but you can map > specific categories onto specific music categories as required by the > iTunes podcast directory? May as well use the same iTunes categories > for the non itunes tags too. That could be challenging :) > Or just stick a list box with all the itunes categories in the > interface and let people pick the one they want as well as fatcat > category. I was thinking along this kind of line. Other than laziness, it may be the best solution. I was thinking if the values for that list box were an array in the config file, it would be easiest to keep up to date. > > I presume you've read the updated specs... > > http://phobos.apple.com/static/iTunesRSS.html Not from that URL, but I'm pretty sure I've read that document. Thanks :) verdon > > > Shaun > aegis design - http://www.aegisdesign.co.uk > > > > ------------------------------------------------------- > SF.Net email is sponsored by: Discover Easy Linux Migration Strategies > from IBM. Find simple to follow Roadmaps, straightforward articles, > informative Webcasts and more! Get everything you need to get up to > speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click > _______________________________________________ > Phpwebsite-developers mailing list > Php...@li... > https://lists.sourceforge.net/lists/listinfo/phpwebsite-developers > > |
From: Babul G. <bab...@ho...> - 2005-07-20 12:16:58
|
Hi in my installation of phpwebsite, new user registration is not done saying the following error: SQL: insert mod_users (username, password, email, user_id) values ('sdada', '94786e1dff56760d254b631502779b21', 'adsa@fdghd.lo', 2) unknown error can someone pls let me know how to fix this problem? phpwebsite 0.10.1 is installed regards Babul |
From: Matthew M. <ma...@tu...> - 2005-07-20 12:24:28
|
Please direct technical questions to our Sourceforge forum or IRC chat room. On Wed, 2005-07-20 at 17:46 +0530, Babul Gogoi wrote: > Hi > > in my installation of phpwebsite, new user registration is not done saying > the following error: > > SQL: insert mod_users (username, password, email, user_id) values ('sdada', > '94786e1dff56760d254b631502779b21', 'adsa@fdghd.lo', 2) > unknown error > > can someone pls let me know how to fix this problem? > > phpwebsite 0.10.1 is installed > > regards > > Babul > > > > > ------------------------------------------------------- > SF.Net email is sponsored by: Discover Easy Linux Migration Strategies > from IBM. Find simple to follow Roadmaps, straightforward articles, > informative Webcasts and more! Get everything you need to get up to > speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click > _______________________________________________ > Phpwebsite-developers mailing list > Php...@li... > https://lists.sourceforge.net/lists/listinfo/phpwebsite-developers -- Matthew McNaney Electronic Student Services Appalachian State University http://phpwebsite.appstate.edu |
From: Yves K. <ph...@fi...> - 2005-07-20 17:05:23
|
Matt is completely right; and try to change the value in mod_users_seq to a value, higher than the amount of allready installed users. Yves (ykuendig) -----Urspr=FCngliche Nachricht----- Von: php...@li... [mailto:php...@li...]Im Auftrag von Babul Gogoi Gesendet: Mittwoch, 20. Juli 2005 14:17 An: php...@li... Betreff: [Phpwebsite-developers] new user register error Hi in my installation of phpwebsite, new user registration is not done sayin= g the following error: SQL: insert mod_users (username, password, email, user_id) values ('sdada= ', '94786e1dff56760d254b631502779b21', 'adsa@fdghd.lo', 2) unknown error can someone pls let me know how to fix this problem? phpwebsite 0.10.1 is installed regards Babul ------------------------------------------------------- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies =66rom IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=3D7477&alloc_id=3D16492&op=3Dclic= k _______________________________________________ Phpwebsite-developers mailing list Php...@li... https://lists.sourceforge.net/lists/listinfo/phpwebsite-developers |
From: Babul G. <bab...@ho...> - 2005-07-22 11:56:57
|
Hi Yves THANK you very much for teh solution.. ye, in fact it was solution.. the total nu of users are: 90. SO I changed the value of mod_users_seq to 91 and it solves teh problem.. u r a genious! very warm regards Babul >From: "Yves Kuendig" <ph...@fi...> >Reply-To: php...@li... >To: <php...@li...> >Subject: AW: [Phpwebsite-developers] new user register error >Date: Wed, 20 Jul 2005 19:05:05 +0200 > >Matt is completely right; >and try to change the value in mod_users_seq to a value, higher than the >amount of allready installed users. > >Yves (ykuendig) > >-----Ursprüngliche Nachricht----- >Von: php...@li... >[mailto:php...@li...]Im Auftrag von >Babul Gogoi >Gesendet: Mittwoch, 20. Juli 2005 14:17 >An: php...@li... >Betreff: [Phpwebsite-developers] new user register error > > >Hi > >in my installation of phpwebsite, new user registration is not done saying >the following error: > >SQL: insert mod_users (username, password, email, user_id) values ('sdada', >'94786e1dff56760d254b631502779b21', 'adsa@fdghd.lo', 2) >unknown error > >can someone pls let me know how to fix this problem? > >phpwebsite 0.10.1 is installed > >regards > >Babul > > > > >------------------------------------------------------- >SF.Net email is sponsored by: Discover Easy Linux Migration Strategies >from IBM. Find simple to follow Roadmaps, straightforward articles, >informative Webcasts and more! Get everything you need to get up to >speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click >_______________________________________________ >Phpwebsite-developers mailing list >Php...@li... >https://lists.sourceforge.net/lists/listinfo/phpwebsite-developers > > > >------------------------------------------------------- >SF.Net email is sponsored by: Discover Easy Linux Migration Strategies >from IBM. Find simple to follow Roadmaps, straightforward articles, >informative Webcasts and more! Get everything you need to get up to >speed, fast. http://ads.osdn.com/?ad_idt77&alloc_id492&op=click >_______________________________________________ >Phpwebsite-developers mailing list >Php...@li... >https://lists.sourceforge.net/lists/listinfo/phpwebsite-developers |