How to limit feeds module items to import to e.g. 10 in Drupal?
I have successfully imported xml in my Drupal content type using feeds and xpath module. However, I am unable to set the numbers of nodes theat are created.
It is a problem becasue in the xml file there are 200 items, so it is slow. I would like to limit it to 30 items, 开发者_开发知识库so each time it updates only 30 nodes are created not 200.
Where to set this?
Thanks in advance for any advice.
I didn't see any configurations for this either. But Drupal 7 provides aggregator hooks that will allow you to override these.
Check out: http://api.drupal.org/api/drupal/modules--aggregator--aggregator.api.php/function/hook_aggregator_fetch/7
I think the question was about feeds module, not aggregator module.
In your settings.php file you can try setting $conf['feeds_process_limit'] = 50; and then clear your caches.
However, the above method didn't work for me. If you are just looking for a quick limiter (during development of a custom importer, for example) you can try the tip here: https://drupal.org/node/1909974
精彩评论