What we would like to change to is:
When admin create a new product in MarketPress, the URL of the new product will have the blog ID and product ID at the end of the URL, such as:
The first number is blogID 6, and the second number is productID 32.
Both numbers are all known at the time when “publish” button is pressed. I assume we just read it out somewhere and then change the URL accordingly. Am I right?
1. How to get the blog ID and proudct ID automatically when creating a new product in marketpress?
2. How to change the new product URL to add blog ID and product ID at the end automatically?
Can this be done easily? Where do we start?
Thank you for reading my question :slight_smile:
Note: if you are really curious why we need that, here is the short story:slight_smile:
We will display some of the facts of this product on the front end, such as total number of sales to-date. In order for us to read out this piece of information from the store database, we need to know the blog ID and product ID. We could find out both IDs manually for each product, but it would be time consuming if we have to do that all the time for all the products. So, an automation would be nice. Would you think :slight_smile: