I was looking for a method to dynamically change the page template loaded by Wordpress based on a url query parameter…. The idea was to use <If> statement to get value of query string then use <Load child_theme file=“template2.php” />
<Note>
//CHECKS QUERY STRING FOR THE PRESENCE OF URL QUERY EMBED
//IF EMBEDX = YES SETS PAGE TEMPLATE TO NOHEADERNOFOOTER.
</Note>
<Let name=embed><Url query=embedx></Url></Let>
<If variable=embed not_exists>
<Exit />
<Else>
<Load file="https://lotnova.com/public/wp-content/themes/g5-beyot-child/template_without_header_footer_sidebar.php" />
</Else>
</If>
But nothing happens… What am I missing?