Hey guys,
I’ve been trying to find a solution for this for about a week, hoping for some help.
I’m building a website using Elementor, JetEngine & JetFormBuilder (using this because I needed the user login action addon). The idea of the website is to have a frontend dashboard where a registered user (subscriber) can post a job, and that job needs to show it was created by the subscriber who posted it.
For some reason, when the post is created by the subscriber and goes to pending review, once the site admin posts the … post, the user changes to the site admin, and it also comes out of the listing grid in the subscriber’s account. I’m not sure what I’m doing wrong. Hoping to get some help.
Thanks in advance!
Here are some screenshots to help with the explanation:
[1-Post created by subscriber.](https://preview.redd.it/wrxfg5s5izkc1.png?width=1283&format=png&auto=webp&s=d86e7f6477186311acde65b01a4fe35e72fc7abb)​
[2-Post pending review in the list.](https://preview.redd.it/21xsxp3eizkc1.png?width=1733&format=png&auto=webp&s=f3f2221a3836640eaed09fe9a5fdb2821a92ceac)​
[3-Post pending review inside the post.](https://preview.redd.it/dh6fu611jzkc1.png?width=335&format=png&auto=webp&s=35eb33c424788057303ed054344f38f69522a7ce)​
[4-Info after posting](https://preview.redd.it/qjib05b4jzkc1.png?width=290&format=png&auto=webp&s=de3e8e7579c18c636891eb04d86bcd016efba098)​
[5-User changed after posting-Frontend public view](https://preview.redd.it/w5uipzkmjzkc1.png?width=1211&format=png&auto=webp&s=10ed5f2edff2b5f0f28a43722ea8fef201fdeeaf)​
[6-Listing for user is empty in the frontend account](https://preview.redd.it/zje57zwpjzkc1.png?width=1290&format=png&auto=webp&s=7b671b1517ced2b6601156c2f6a048cf4103b7da)​
[7-Setting for the listing grid](https://preview.redd.it/n2uvfzasjzkc1.png?width=286&format=png&auto=webp&s=9e38d45815906fff6b1690fc702d99a17a4cf2d4)​
​
​
[ad_2]
When you publish the post, who does it say the author is in the WordPress dashboard? If it’s you (admin), can you change it to the desired user?
If it’s already published as the desired user (I.e. the person who submitted it) then I think the issue is your query inside your loop (#7 in your images). ‘Current User’ is a native WordPress query which would under normal circumstances return the username of the person who is logged in and looking at the page (I.e. you). Try logging in as a third user and looking at the loop to confirm this.
So basically I think there are only 2 scenarios:
1. When you publish the post the author changes to yourself (admin)
2. Your query settings are wrong, or are running in the wrong context
If #1 you could either manually update the user each time, orrr… (I would have to think about this)
If #2 you need to play around with the loop’s query settings. I find in cases like these it’s often best to query posts by user ID, or perhaps user slug (you may be able to pin it to the URL if the page is something like `yoursite.com/jobs/the-username`
Are the users who submit the gigs registered in the WP database?
The field you’re referring to is called the ‘author’ field.
Firstly, I’d double check that when the posts are submitted, they are using the correct author. Secondly, when the post is loaded by the admin, check that the Author field is showing the correct user.