• I really like this plugin, but i have a small request or modification i would like to make.

    When i use the import to post, a custom field is generated with a value according to the url of the original post (from the authors site).
    What i would like is for the importer to also generate a custom field for the name of the author, and the url to his/her frontpage.

    I’ll try to give you an example:

    Author, writes a post -> I import the post (feed to post) -> Importer generates Custom field 1, the post url (www.author1.com/post) -> importer generates field 2 (key=author, value= author name) -> importer generates field 3 (key=source, value=www.author1.com)

    When those fields are generated, i believe i can use the custom fields to make my frontpage show the posts in the specific way i want to.

    Featured pic
    Title (links to custom field 1)
    Excerpt
    By “author” (custom field 2) – links to author url (custom field 3)
    Date+time of the post (still working on that)

    Hope you kind of get the idea of what i want and that you can point me in the right direction in how to achieve it.

    My site

    https://www.ads-software.com/plugins/wp-rss-multi-importer/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Allen

    (@amweiss98)

    you would have to change a lot of code in the plugin to make this work..the fields are there to do this (e.g., $items[‘myauthor’], etc, which you see in the default template (in the templates folder).

    Thread Starter j4ze

    (@j4ze)

    There must be somewhere i can see how the existing custom field for the source link, is created, and then copy-paste that, swapping the $thisLink parameter with $myAuthor or something like that?

    Plugin Author Allen

    (@amweiss98)

    I’m not sure..you can create your own template and swap out whatever you like (just be sure to save the template using the template options admin.

    Thread Starter j4ze

    (@j4ze)

    It cant be that difficult, can it?

    I’ve found the original link custom field to be in the import_post.php file. For some reason its within an if loop, so unfortunately i can’t just add another custom field.

    I’ve figured out that this must be the code i need to insert:

    add_post_meta($post_id, 'rssmi_author_link', $items['myauthor'], true);

    i just need help to figure out where to insert it, and im not sure that my value is correct ” $items[‘myauthor’] ”

    Plugin Author Allen

    (@amweiss98)

    your value is correct..you can try adding that inside the loop..it will add it to the database but I’m not sure what you want to do after that…

    Thread Starter j4ze

    (@j4ze)

    What i want is for the plugin to auto-generate a custom field – just like it does with the source-link now. I just want to add a field more, with the authors name as value.

    I will try to play around with it, but since I’m not an expert in php coding, i would appreciate any help you could give me.

    thank you

    Thread Starter j4ze

    (@j4ze)

    Now i got the plugin to add the custom field, but for some reason the value-field is empty ?? I’ve tried to use

    add_post_meta($post_id, 'rssmi_author_link', $items['myauthor'], true);

    and

    add_post_meta($post_id, 'rssmi_author_link', $feedAuthor, true);

    but none of them returns a value ??

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Create author custom field?’ is closed to new replies.