wordpress permalink settings code example
Example 1: wordpress get_permalink
// Get post permalink (you can use it inside a wp_query loop)
<?php the_permalink(); ?>
// or
<?php $link = get_the_permalink(); ?>
Example 2: wordpress permalink inside database
In the wp_options table there is a record where
option_name = "permalink_structure".