Button to link to the same page on another omeka installation

Hello,
I have two omeka sites installed on two subdomains (with two different databases but the entries match) :
- subdomain1.domain.org
- subdomain2.domain.org

I would like to add a button on every item show page of my omeka installed on subdomain1, to link towards the same item on subdomain2.

For example, on the page subdomain1.domain.org/items/show/153, I would like to add a button that links to the page subdomain2.domain.org/items/show/153

I use the seasons theme, I guess I need to add something in the themes/seasons/items/show.php file, but I don't know how to do it.

Could anyone provide me guidance?

Thanks,
Fran├žois.

The basics might work something like getting the url for the current item, then replacing subdomain1 for subdomain2 with str_replace. This will get you the current url on an items/show page:

<?php
    $url = record_url($item, 'show', true);
?>

After that replacement, you can add the link wherever in the items/show.php file.

Thank you it worked!