WordPress Tags Not Being Assigned to Post

  1. I created WordPress tags with Make and then used the module “Search Tags” to fetch their ID.

  2. An “Array Aggregator” was used to aggregate all tag IDs into a single bundle.

  3. Using {{get(map(124.array; “id”); 1)}} for all ten tags, the “Set Multiple Variables” gave me different variables for each tag.

The result:

  1. In the “Create a Post” module, I put those ten variables in the Tag field.

  2. The blog post and the tags are created successfully, but the tags are not assigned to the blog post. It appears empty without showing any error.

I also tried using the method found in the following link to update the blog post using the “Make an API Call” module, but with no success: Updating or posting a Wordpress post with multiple tags created with an Iterator module - #4 by Abhishek

I’m sure missing something here. Any help would be appreciated!

Delete module 123, and just paste this in the tags field:

{{ map(124.array; "id") }}

Hope this helps! Let me know if there are any further questions or issues.

@samliew

P.S.: Investing some effort into the Make Academy will save you lots of time and frustration using Make.

2 Likes

@samliew thanks a lot! That worked, but to be sure other people use the function correctly, it’s better to remove the speech marks around “id”, otherwise, there’s an error. Here’s the corrected function:

map(123.array;id)

Hello @Vasco
When I try to copy both of the versions into the Set Multiple Variable module See the results.

The version given by @samliew is more appropriate to use instead of given by @Vasco.
Just use copy-paste from Make and Always use code block for the formula.
How to use code blocks
```
{Formula}
```

A more convenient way is to directly copy-paste the syntax from the scenario.

Hi @dilipborad
Sorry, my mistake. I put the wrong number; it should be 124:
{{ map(124.array; “id”) }}

Also, I didn’t know that putting map(124.array[];id) into code in this forum would transform it to map(123.array;id), removing the square brackets.

Hello @Vasco,
As a formatting, this is still not as accurate as @samliew did.
You can copy and paste this first
{{ map(124.array; “id”) }}

and then try this

{{ map(124.array; "id") }}

See the difference in quotes(")


That’s why I always strongly recommend people take this course first.

Also, see this topic about how formatting works in the Make community.

@dilipborad , thanks for the heads up about the quotes!