[Zope-PTK] CMF Advise in migrating existing PHP - MySQL site to Zope CMF and MySQL

Tres Seaver tseaver@digicool.com
Mon, 19 Mar 2001 13:04:19 -0500


Norman Khine wrote:

> Hello ALL,
> Having build my site using PHP and MySQL, I feel that what is needed would
> MOST probably suffice with CMF. The site can be found at
> www.buildersmerchants.co.uk/alpha/
> 
> It is not much to look at as there is no content, but I think the
> functionality is there ie registration of user, able to browse news items
> and link to manufacturers' pages
> 
> If you use username: adv1 password: adv1, you would be loged in. And be able
> to navigate arround. This is the "front-end" where the users can see their
> entries etc etc, to go to the back-office where a particular user can access
> their data and update, modify etc is at
> www.buildersmerchants.co.uk/alpha/adadmin/, again you can use adv1 for
> username and password.
> 
> Once there the user is able to add company datails, products, logo's and so
> on.
> 
> This application is written in PHP and MySQL, but I feel it will be better
> suited to CMF, this is why I am currently building a copy of the site using
> Zope and CMF, but being a novice in zope and python, I would like your help
> in transferring this site to Zope/CMF.
> 
> The idea of the portal would be for Manufacturers to be able to add their
> company details and products the provide, while the Merchants would be able
> to view them and make enquiries and so on for a particular product.
> 
> My questions would be:
> 
> 1.	When the user registers, using the current registration form, how
> can I add the additional PROFILE data required within the CMF. Will it be
> better to include this after the user has loged in? One thing though is that
> what I am trying to achieve is to be able for the user to specify the type
> of user they are, this will determine the type of account they end up being
> ie Merchant, Manufacturer
> 
> If I recreate the user registration form in the PREFERENCES link, so that if
> the user wishes to be listed they would be able to select yes and be able to
> enter the PROFILE data about themselves. 
> 
> How can I put the user details into the db?
> 
> Would I need to use a different login/authentication procedure?
> 
> Do you think, speaking from previous experience of course, that this is the
> correct way to proceed?
> 
> Or should I leave authentication entirely to Zope/CMF?
> 
> 2.	In the adamin module the manufacturer is able to update their
> company profile and ADD products with further breakdowns for each particular
> product ie product pic, description, the difficulty here is being able to
> link Product Group and Product Type that this particular "object" belongs
> to, from the CMF?
> 
> An E-R schema of the database can be found at
> http://www.buildersmerchants.co.uk:8080/BMPub/Dezign/ 
> 
> The way I am thinkg of going through this is to create a "GLOBAL"  portal
> where ALL users login, then depending on the BuisnessFunction to direct them
> to a sub-portal, then within this sub-portal the user is able to do whatever
> they need to do, but is then reflected back into the GLOBAL portal?!?!
> 
> OR should it be the other way around, where I would create an individual
> portal for each type of user, and then "pull" all their bits and pieces into
> a "global" sub-portal - can this be done?
> 
> Portal A and Portal B to "talk" to Portal C?
> 
> 
> Thanks for being so patient and reading thus far, and thanks to Zope for
> providing an os that truly is pure objects ;^)

Norman,

One quick way to achieve what you want is to have different skins for 
Manufacturers and Merchants;  the skins control the visula presentation
of the site, so if the user selects the preferred skin at the time they
join, you can then control what shows up on the "Preferences" etc. forms
later.  You can then store the preferences data using the
'portal_memberdata' tool.

I'm swamped today and can't look at your site in more detail;  hope this
helps!

Tres.


-- 
===============================================================
Tres Seaver                                tseaver@digicool.com
Digital Creations     "Zope Dealers"       http://www.zope.org