Pay-per-node don't seem to work on installs where i18n is active.
On a fresh install of drupal-7.18 these modules are enabled : Content translation 7.18, Locale 7.18, Chaos tools 7.x-1.2, i18n 7.x-1.7, Variable 7.x-2.1 and Views 7.x-3.5.
After enabling pay-per-node 7.x-1.0, when I execute admin/content/Add content, I get this fatal error : require_once() [function.require]: Failed opening required 'C:\wamp\www\drupal-7.18/modules/node/i18n_node.pages.inc' (include_path='.;C:\wamp\bin\php\php5.3.13\pear') in C:\wamp\www\drupal-7.18\includes\menu.inc on line 515.
When Ubercart is active, I have the same problem reported at http://drupal.org/node/1220936.
Comments
Comment #1
maurizio.ganovelliAfter i tried this configuration (same version for all modules), i discovered that this issue can be solved by commenting line 102 on paypernode.module file. Try to do this and let me know, the line in question is
i think that this solves also the other problem with Ubercart (http://drupal.org/node/1220936).
Comment #2
Ted51 CreditAttribution: Ted51 commentedCommenting line 102 of paypernode.module file produces this new fatal error : Call to undefined function node_add_page() in C:\wamp\www\drupal-7.18\sites\all\modules\paypernode\paypernode.module on line 248
Comment #3
maurizio.ganovelliYou're right, this happens when user has rights to create node with normal permission system.
In this case the solution is to add this line:
at the begin of paypernode_node_add_page() function (right after "global $user;").
After this i can correctly create nodes without errors (as administrator or normal user through ppn): let me know, i will provide and commit a patch if it works.
Comment #4
Ted51 CreditAttribution: Ted51 commented#3 corrects the fatal error when creating a node as administrator or normal user.
When I delete the node through ppn, admin/settings/paypernode/Overview still indicates that the node is ceated. After that, I can create many nodes like I want.
Comment #5
maurizio.ganovelliThis behaviour is "by design": once deleted, node is not automatically re-charged in ppn user balance. However this is possible because nodes created with ppn are tracked in a db table, but is more like a feature request, not a real bug.
Please note that the user that creates a new content with ppn must not have the permission to create that content type. In this case, ppn system check will be skipped (since user can create unlimited number of contents of this type).
Comment #6
Ted51 CreditAttribution: Ted51 commentedI agree with you. Very usefull module ! Thank you.
Comment #7
Ted51 CreditAttribution: Ted51 commentedAnother bug. Consider this case : the role authenticated user has no permission on the content type "Article" but has permissions on the content type "Basic page". Execution of node/add by an authenticted user which can use ppn to create an article generates this fatal error : Call to undefined function node_get_types() in C:\wamp\www\drupal-7.18\sites\all\modules\paypernode\paypernode.module on line 253
Comment #8
Ted51 CreditAttribution: Ted51 commentedHi blackice78,
Have you a solution for the fatal error reported at #7 ?
Thanks for your help.
Comment #9
maurizio.ganovelliHi Ted51, please check the new dev snapshot (7.x-2.x-dev, you can take it from http://drupalcode.org/project/paypernode.git or wait that it become available on project page) and let me know if it solves this issue.
Comment #11
xamount CreditAttribution: xamount commentedRegarding comment #7, I tried the solution suggested at #9 and it did not solve the problem. After trying #9 and I try to create a node, I get the following page "You have not created any content types yet. Go to the content type creation page to add a new content type."
Comment #12
maurizio.ganovelliHi xamount, i've tested paypernode version 2.x with Drupal 7.28 and Internationalization 1.11. On a fresh install i downloaded and enabled paypernode and all i18n modules.
After this, once enabled allowed content types (admin/settings/paypernode/allowed) and created a new user with assigned some articles, i'm able to create nodes with ppn using the new account.
The node/add page give me no errors or warnings.
Can you explain me the steps to reproduce and post some info (module version, error returned ...)?