Site icon Hip-Hop Website Design and Development

How to save page URL as a favorite

I’m building a WordPress site with dynamic pages. I want to allow users to save each page like a favorite and then be able to view them and delete them.

Since my pages are custom pages that are dynamic they all have the same post ID but they do have unique URLs.

I know I can pull the full url with queries using this code:

<?php $current_url = home_url( add_query_arg( NULL, NULL ) ); ?>

Does anyone have any advice on how I can allow users to save a page based on this?

Thanks!