Looks like the add_rewrite_rule('^somepage/([^/]*)/([^/]*)/([^/]*)/?','index.php?pagename=somepage&target=$matches[1]&arrival=$matches[2]&departure=$matches[3]','top');
code was the way to go. Although I still couldn’t retrieve the GET part. So what I did was:
1.) In the functions.php I’ve added a new rewrite rule as an init action:
add_rewrite_rule(‘^hotels/([^/]*)/([^/]*)/([^/]*)-([0-9]*)/?’,’index.php?pagename=hotels’,’top’);
2.) Since I couldn’t get the other GET parameters to work, I’ve just read the $_SERVER[‘REQUEST_URI’] from the plugin part and made appropriate checks of the ID from the URI.
It does create quite a bunch of potential alternative links that would create issues with SEO. So, I’ll need to ensure that any alternating links that have same ID would be redirected to the original page.