By ShawnNYC on
Hi, thanks for reading.
I have a D7 install. I'm trying to use Rules to enter data into a field that is not a core field. The field is created by the Feeds Module, and it is the URL of the feed source.
In the Database, the table is called "feeds_source" and the field is called "source".
The Rule Type is "Execute PHP Code". I've confirmed in the debug that the rule is firing.
The non-working php code is as follows:
$entity->feeds_source->source = "http://example.com";
I'm a novice at php so I'm not sure if I have to enhance my code to be a function, do a db_query, or if my syntax is wrong.
Please help point me in the right direction. Thanks
Comments
bump
bump
try this -install and enable
try this
-install and enable the Devel module. this will allow you to see the structure of the arrays and objects that make out the node you are trying to override.
-replace your php code with
from here you will be able to see what your node is made out of
-adapt the following code to your specific use case
... or something
Great thank you so much.
Great thank you so much. I'll try it asap.