Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Primary category not reflected in URL on Ajax function call #11717

Closed
6 of 9 tasks
burhandodhy opened this issue Nov 30, 2018 · 3 comments
Closed
6 of 9 tasks

Primary category not reflected in URL on Ajax function call #11717

burhandodhy opened this issue Nov 30, 2018 · 3 comments

Comments

@burhandodhy
Copy link

  • I've read and understood the contribution guidelines.
  • I've searched for any related issues and avoided creating a duplicate issue.

Please give us a description of what happened.

WordPress inserts the link using the secondary category instead of the primary category permalink in Ajax function call.

Please describe what you expected to happen and why.

Add the primary category slug in permalink.

How can we reproduce this behavior?

  1. Send the post ID in Ajax call.
  2. Call get_permalink( $post_id ) function.

Technical info

  • If relevant, which editor is affected (or editors):
  • Classic Editor
  • Gutenberg
  • Classic Editor plugin
  • Which browser is affected (or browsers):
  • Chrome
  • Firefox
  • Safari
  • Other

Used versions

  • WordPress version: 4.9.8
  • Yoast SEO version: 9.2.1
  • Gutenberg plugin version:
  • Classic Editor plugin version:
  • Relevant plugins in case of a bug:
  • Tested with theme: Twenty Seventeen
@andizer
Copy link
Contributor

andizer commented Dec 5, 2018

Thanks for reporting this issue.
Unfortunately, we do not have enough information to reproduce this problem. Please follow these guidelines to improve your bug report.

Also, it may help us a lot if you can provide a backtrace of the error encountered. This gist will explain how to enable the backtrace in your website: https://gist.github.com/jrfnl/5925642

Thank you.

@andizer
Copy link
Contributor

andizer commented Dec 13, 2018

Closing due to inactivity. If this issue is still relevant, please open a new issue with the requested information. Thanks for your understanding.

@andizer andizer closed this as completed Dec 13, 2018
@semmais
Copy link

semmais commented Oct 22, 2020

Same here.
pratical example:
The modal acf-link call admin-ajax and the results links do not reflect the "primary category"
( wp_link_query links are not with primary category )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants