Doesn't work when content type name has underscores
Libriana - March 19, 2009 - 01:07
| Project: | UC Node Checkout |
| Version: | 6.x-2.0-beta3 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Description
When a related content type has underscores on its name, i.e. company_type, clicking "Add to cart" button on the product does not take you to the new node form of its related content type. Instead, it shows a page containing a list of content types to choose from. The new node "Save" button is not replaced with "Add to cart" either.
This is solved when underscores are removed from the content type name (and node_checkout relationship with the same product is re-created).

#1
That behavior sounds like the same problem I get when using a View to select the node type. Are you using views, or are we just experiencing the same failure mode?
#2
When the module redirects it should be replacing underscores in the $type label with - (minus signs). Attached patch fixes 3 redirects within the module. This prevents the infinite redirects / page listing all content types that the user can create.
#3
omerida, when you post a patch make sure to set the status accordingly or often times a useful patch like this will go over looked.
tested this patch and it fixed the issue on my site.
#4
looks like this is the same problem as #365546: Incorrect node/add links via anonymous node creation
#5
i think that #416702: Use of View to select product associated with node does not work might be a duplicate.
#6
Worked like a charm - will see if that other issue goes away with the next beta.
#7
Automatically closed -- issue fixed for 2 weeks with no activity.