Long-billed Curlew birds by mikebaird
Hi ATG Support,
I noticed a bug in how ATG’s ProfileFormHandler (ATG Java API) handles confirm passwords when creating a new profile. Note that this bug happens only if you persist anonymous profiles.
During registration when you call handleCreate it calls createProfileItem and then updateProfileAttributes. In updateProfileAttributes it checks if the password matches the confirm password. If they don’t match it adds a form exception.
However at this point it has updated the profile attributes including the login. Therefore after the user sees the error about the passwords not matching, corrects it and resubmits the form she will see an error that the login is already taken.
The work around is to set creatNewUser to true but since the default value is false most developers will see this bug.
Update 12-22-2010: ATG confirmed this is a bug.
Thanks for the information and details. I’m glad that using ProfileFormHandler.createNewUser=true works for you. You might want to periodically check the size of the dps_user table and purge the anonymous profiles, if needed.
For your reference, I have created PR#DPS-167714 “ProfileFormHandler Confirm Password” to track the issue.
Isn’t it iconic? by Mykl Roventine
eCommerce sites want to make their users’ experience as convenient and intuitive as possible. One convenience found on most major eCommerce sites is remembering what the user put in his shopping cart, even if that person didn’t log in. Therefore when the user returns to the site he will see what he left in his shopping cart.
ATG makes it relatively simple to do this by:
- creating a profile in the repository (database) for all users that visit the website
- automatically logging in users by cookie
Therefore if a user returns, she/he will be automatically logged in and if there were any items in his cart they will be added to the current cart.
- Turn on persisting anonymous profiles in the ProfileRequestServlet.
- Turn on auto-login by cookie and turn off auto-login by basic authentication.
- Make all profile properties not required except for login and password in userProfile.xml. Also make autoLogin true.
When a profile is created for an anonymous user the login and password are set to the user’s ID (i.e. the profile’s repository ID).
If you are adding this functionality to an existing up and running site you may have to modify your user tables so that there no “not null” columns except for the id, login and password columns, you can leave those as how they were. Also you will need to set auto_login to true for all your existing users.
update dps_user set auto_login = 1;
To determine when the anonymous user was created look at the registrationDate profile property. To determine when was the last time the anonymous user logged in look at the lastActivity profile property. Both of these are updated by ATG’s TrackActivity scenario which is in the DSS folder.
Finally do not turn on persistent anonymous profiles in the BCC. It will stop working if you do that.
For further reading please see Tracking Guest Users and Tracking Registered Users in the ATG 9.1 Personalization Programming Guide.
Typically after you create a category in your catalog you then add products to the category. The simple way to do that in ATG eCommerce is to use the ACC and add products to the child products property of the category. However there is another way.
In the ATG Commerce Guide to Setting Up a Store documentation you can see in the Viewing the Product Catalog section that a category can have child products but also child product groups.
Child product groups are actually content groups which are described in the Creating Content Groups chapter of the ATG Personalization Guide for Business Users.
Though the documentation shows a content group composed of features you can easily create a content group using the ProductCatalog as a content source and product as a content type.
To create a content group follow the steps in the ATG documentation for Creating New Content Groups except use an item from the ProductCatalog when specifying the Content Type. Then create the targeting rules for this Content Group. Now you can specify this group in the Child products (group) property of a category.
In the ATG logs you may see warnings about a slot being session scoped not global.
[STDOUT] Invalid attempt to resolve component /atg/registry/Slots/ActivationFlowSlot in scope global. It is defined in scope session
Most of the time you can safely ignore these warnings because these warnings are most likely coming from the ACC.
When browsing slots using the ACC the ACC tries to look up the slot as a global component and complains it’s a session scoped component. In other words it’s an ACC bug that will probably never be fixed since ATG is moving away from the ACC.
Though I have a distaste for scenarios on occasion there will be a time when I want to create a new scenario. On such an occasion I still start up the ACC, go to Scenarios > Scenarios and discover I can’t create a scenario because the New Scenario box is grayed out.
The issue is often because the process editor server is configured incorrectly. ATG documents how to configure the process editor server.
For example today I found I could not create a new scenario. After putting this
localconfig/atg/scenario and then restarting ATG I was able to create new scenarios again.
Note that the server name must be the same as the one found at
/atg/dynamo/service/ServerName.serverName. For more information about the atg.service.ServerName class, see Referring to Dynamo Servers in the Nucleus: Using Nucleus section of the ATG Programming Guide.