Here is the PHP that I have which i am trying to change:
global $current_user, $post, $product;
?>
<?php if ( $post->post_author == get_current_user_id() ) { ?>
<div class="wpproductedit">
<p class="wpproducteditbutton"><a href="http://blah.com/private/products">EDIT</a></p>
</div>
<?php } ?>
Here, the button only takes the user (author of the product) to product page which then they have to find the product they want to edit.
So any product edit page will have the following URL:
http://blah.com/shop/product-x/edit
http://blah.com/shop/product-y/edit
As you can see, only the product name changes.
In summary, I am trying to edit the "Edit" link so that it will be like the following and picks up the product name automatically.
http://blah.com/shop/"ANYPRODUCT"/edit