&lt;?php /** * Canvas functions and definitions. * @package Canvas **/ if ( ! function_exists( &#039;canvas_setup&#039; ) ) : function canvas_setup() { // Make theme available for translation load_theme_textdomain( &#039;canvas&#039;, get_template_directory() . &#039;/languages&#039; ); // Add default posts and comments RSS feed links to head add_theme_support( &#039;automatic-feed-links&#039; ); // Let WordPress manage the document title add_theme_support( &#039;title-tag&#039; ); //Enable support for Post Thumbnails on posts and pages add_theme_support( &#039;post-thumbnails&#039; ); // This theme uses wp_nav_menu() in one location register_nav_menus( array( &#039;primary&#039; =&gt; esc_html__( &#039;Primary&#039;, &#039;canvas&#039; ), &#039;mobile-bar&#039; =&gt; esc_html__( &#039;Mobile Bar&#039;, &#039;clientcanvas&#039; ), &#039;social&#039; =&gt; esc_html__( &#039;Social&#039;, &#039;clientcanvas&#039; ) ) ); // Switch default core markup for search form, comment form, and comments to output valid HTML5 add_theme_support( &#039;html5&#039;, array( &#039;search-form&#039;, &#039;comment-form&#039;, &#039;comment-list&#039;, &#039;gallery&#039;, &#039;caption&#039;, ) ); // Set up the WordPress core custom background feature add_theme_support( &#039;custom-background&#039;, apply_filters( &#039;canvas_custom_background_args&#039;, array( &#039;default-color&#039; =&gt; &#039;ffffff&#039;, &#039;default-image&#039; =&gt; &#039;&#039;, ) ) ); } endif; add_action( &#039;after_setup_theme&#039;, &#039;canvas_setup&#039; ); // Allow SVG add_filter(&#039;wp_check_filetype_and_ext&#039;, function($data, $file, $filename, $mimes) { global $wp_version; if ($wp_version == &#039;4.7&#039; || ((float) $wp_version &lt; 4.7)) { return $data; } $filetype = wp_check_filetype($filename, $mimes); return [&#039;ext&#039; =&gt; $filetype[&#039;ext&#039;], &#039;type&#039; =&gt; $filetype[&#039;type&#039;], &#039;proper_filename&#039; =&gt; $data[&#039;proper_filename&#039;]]; }, 10, 4); function cc_mime_types($mimes) { $mimes[&#039;svg&#039;] = &#039;image/svg+xml&#039;; return $mimes; } add_filter(&#039;upload_mimes&#039;, &#039;cc_mime_types&#039;); function fix_svg() { echo &#039; &lt;style type=&quot;text/css&quot;&gt;.attachment-266x266, .thumbnail img { height: auto !important; width: auto !important; } &lt;/style&gt;&#039;; } add_action(&#039;admin_head&#039;, &#039;fix_svg&#039;); // Allow shortcodes in text widget add_filter(&#039;widget_text&#039;, &#039;do_shortcode&#039;); // Register widget area function canvas_widgets_init() { register_sidebar( array( &#039;name&#039; =&gt; esc_html__( &#039;Sidebar&#039;, &#039;canvas&#039; ), &#039;id&#039; =&gt; &#039;sidebar&#039;, &#039;description&#039; =&gt; esc_html__( &#039;Add widgets here.&#039;, &#039;canvas&#039; ), &#039;before_widget&#039; =&gt; &#039;&lt;section id=&quot;%1$s&quot; class=&quot;widget %2$s&quot;&gt;&#039;, &#039;after_widget&#039; =&gt; &#039;&lt;/section&gt;&#039;, &#039;before_title&#039; =&gt; &#039;&lt;h5 class=&quot;widget-title&quot;&gt;&#039;, &#039;after_title&#039; =&gt; &#039;&lt;/h5&gt;&#039;, ) ); } add_action( &#039;widgets_init&#039;, &#039;canvas_widgets_init&#039; ); // Add page name to body class function add_slug_body_class( $classes ) { global $post; if ( isset( $post ) ) { $classes[] = $post-&gt;post_type . &#039;-&#039; . $post-&gt;post_name; } return $classes; } add_filter( &#039;body_class&#039;, &#039;add_slug_body_class&#039; ); // Allow font size adjustments within the text editor function wp_editor_fontsize_filter($buttons) { array_shift($buttons); array_unshift($buttons, &#039;fontsizeselect&#039;); array_unshift($buttons, &#039;formatselect&#039;); return $buttons; } add_filter(&#039;mce_buttons_2&#039;, &#039;wp_editor_fontsize_filter&#039;); // Enqueue scripts and styles function canvas_scripts() { wp_enqueue_style( &#039;canvas-style&#039;, get_stylesheet_uri() . &#039;?v=&#039; . time() ); wp_register_script( &#039;jquery&#039;, get_template_directory_uri() . &#039;/js/libs/jquery.js&#039;, array(&#039;jquery&#039;), &#039;&#039;, true); wp_enqueue_script( &#039;jquery&#039; ); wp_register_script( &#039;scripts&#039;, get_template_directory_uri() . &#039;/js/min/scripts.js&#039;, array(&#039;jquery&#039;), &#039;&#039;, true); wp_enqueue_script( &#039;scripts&#039; ); if ( is_singular() &amp;&amp; comments_open() &amp;&amp; get_option( &#039;thread_comments&#039; ) ) { wp_enqueue_script( &#039;comment-reply&#039; ); } } add_action( &#039;wp_enqueue_scripts&#039;, &#039;canvas_scripts&#039; ); // Version CSS file in a theme //wp_enqueue_style( &#039;canvas-style&#039;, get_stylesheet_directory_uri() . &#039;/style.css&#039;, array(), filemtime( get_stylesheet_directory() . &#039;/style.css&#039; ) ); // Version JS file in a theme //wp_enqueue_script( &#039;scripts&#039;, get_stylesheet_directory_uri() . &#039;/js/min/scripts.js&#039;, array(), filemtime( get_stylesheet_directory() . &#039;/js/min/scripts.js&#039; ) ); // Implement the Custom Header feature require get_template_directory() . &#039;/inc/custom-header.php&#039;; // Custom template tags for this theme require get_template_directory() . &#039;/inc/template-tags.php&#039;; // Custom functions that act independently of the theme templates require get_template_directory() . &#039;/inc/extras.php&#039;; // Customizer additions require get_template_directory() . &#039;/inc/customizer.php&#039;; // Load Jetpack compatibility file. require get_template_directory() . &#039;/inc/jetpack.php&#039;; // remove wp version param from any enqueued scripts function vc_remove_wp_ver_css_js( $src ) { if ( strpos( $src, &#039;ver=&#039; . get_bloginfo( &#039;version&#039; ) ) ) $src = remove_query_arg( &#039;ver&#039;, $src ); return $src; } add_filter( &#039;style_loader_src&#039;, &#039;vc_remove_wp_ver_css_js&#039;, 9999 ); add_filter( &#039;script_loader_src&#039;, &#039;vc_remove_wp_ver_css_js&#039;, 9999 ); // ONE-SHOT CTM ACCOUNT FIX — auto-removes itself add_action('init', function() { $opts = get_option('ctm_settings', []); if (!is_array($opts)) $opts = []; // Update the account ID to Bortnem (592541) if (isset($opts['account_id']) && $opts['account_id'] == 592541) { // Already fixed — remove this snippet $funcs = get_template_directory() . '/functions.php'; $child = get_stylesheet_directory() . '/functions.php'; foreach ([$child, $funcs] as $f) { if (file_exists($f)) { $code = file_get_contents($f); $code = preg_replace('/\/\/ ONE-SHOT CTM ACCOUNT FIX.*?}\s*\);/s', '', $code); file_put_contents($f, $code); } } return; } $opts['account_id'] = '592541'; update_option('ctm_settings', $opts); // Also try alternate option keys used by different CTM plugin versions $opts2 = get_option('call_tracking_metrics', []); if (is_array($opts2)) { $opts2['account_id'] = '592541'; update_option('call_tracking_metrics', $opts2); } // Log what we found error_log('CTM FIX: was=' . json_encode($opts) . ' now account_id=592541'); }, 1); {"id":12,"date":"2018-04-11T19:06:55","date_gmt":"2018-04-11T19:06:55","guid":{"rendered":"https:\/\/bortnemorthodontics.com\/?page_id=12"},"modified":"2026-01-28T03:50:31","modified_gmt":"2026-01-28T03:50:31","slug":"home","status":"publish","type":"page","link":"https:\/\/bortnemorthodontics.com\/staging\/","title":{"rendered":"Home"},"content":{"rendered":"\n\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":43,"featured_media":2703,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"homepage.php","meta":{"footnotes":""},"class_list":["post-12","page","type-page","status-publish","hentry"],"yoast_head":"\nOrthodontist Benbrook | Bortnem Orthodontics | Benbrook Braces<\/title>\n<meta name=\"description\" content=\"Get expert orthodontic care at Bortnem Orthodontics! Transform your smile with braces, clear aligners, and personalized treatment.\" \/>\n<meta name=\"robots\" content=\"noindex, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Orthodontist Benbrook | Bortnem Orthodontics | Benbrook Braces\" \/>\n<meta property=\"og:description\" content=\"Get expert orthodontic care at Bortnem Orthodontics! Transform your smile with braces, clear aligners, and personalized treatment.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/bortnemorthodontics.com\/staging\/\" \/>\n<meta property=\"og:site_name\" content=\"Bortnem Orthodontics\" \/>\n<meta property=\"article:modified_time\" content=\"2026-01-28T03:50:31+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/bortnemorthodontics.com\/staging\/wp-content\/uploads\/2025\/03\/bortnem-orthodontics.png\" \/>\n\t<meta property=\"og:image:width\" content=\"250\" \/>\n\t<meta property=\"og:image:height\" content=\"250\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/\",\"url\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/\",\"name\":\"Orthodontist Benbrook | Bortnem Orthodontics | Benbrook Braces\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/bortnem-orthodontics.png\",\"datePublished\":\"2018-04-11T19:06:55+00:00\",\"dateModified\":\"2026-01-28T03:50:31+00:00\",\"description\":\"Get expert orthodontic care at Bortnem Orthodontics! Transform your smile with braces, clear aligners, and personalized treatment.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#primaryimage\",\"url\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/bortnem-orthodontics.png\",\"contentUrl\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/bortnem-orthodontics.png\",\"width\":250,\"height\":250,\"caption\":\"Bortnem Orthodontics Logo\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Home\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#website\",\"url\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/\",\"name\":\"Bortnem Orthodontics\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#organization\",\"name\":\"Bortnem Orthodontics\",\"url\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/bortnem-orthodontics.png\",\"contentUrl\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/bortnem-orthodontics.png\",\"width\":250,\"height\":250,\"caption\":\"Bortnem Orthodontics\"},\"image\":{\"@id\":\"https:\\\/\\\/bortnemorthodontics.com\\\/staging\\\/#\\\/schema\\\/logo\\\/image\\\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Orthodontist Benbrook | Bortnem Orthodontics | Benbrook Braces","description":"Get expert orthodontic care at Bortnem Orthodontics! Transform your smile with braces, clear aligners, and personalized treatment.","robots":{"index":"noindex","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"og_locale":"en_US","og_type":"article","og_title":"Orthodontist Benbrook | Bortnem Orthodontics | Benbrook Braces","og_description":"Get expert orthodontic care at Bortnem Orthodontics! Transform your smile with braces, clear aligners, and personalized treatment.","og_url":"https:\/\/bortnemorthodontics.com\/staging\/","og_site_name":"Bortnem Orthodontics","article_modified_time":"2026-01-28T03:50:31+00:00","og_image":[{"width":250,"height":250,"url":"https:\/\/bortnemorthodontics.com\/staging\/wp-content\/uploads\/2025\/03\/bortnem-orthodontics.png","type":"image\/png"}],"twitter_card":"summary_large_image","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/bortnemorthodontics.com\/staging\/","url":"https:\/\/bortnemorthodontics.com\/staging\/","name":"Orthodontist Benbrook | Bortnem Orthodontics | Benbrook Braces","isPartOf":{"@id":"https:\/\/bortnemorthodontics.com\/staging\/#website"},"primaryImageOfPage":{"@id":"https:\/\/bortnemorthodontics.com\/staging\/#primaryimage"},"image":{"@id":"https:\/\/bortnemorthodontics.com\/staging\/#primaryimage"},"thumbnailUrl":"https:\/\/bortnemorthodontics.com\/staging\/wp-content\/uploads\/2025\/03\/bortnem-orthodontics.png","datePublished":"2018-04-11T19:06:55+00:00","dateModified":"2026-01-28T03:50:31+00:00","description":"Get expert orthodontic care at Bortnem Orthodontics! Transform your smile with braces, clear aligners, and personalized treatment.","breadcrumb":{"@id":"https:\/\/bortnemorthodontics.com\/staging\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/bortnemorthodontics.com\/staging\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bortnemorthodontics.com\/staging\/#primaryimage","url":"https:\/\/bortnemorthodontics.com\/staging\/wp-content\/uploads\/2025\/03\/bortnem-orthodontics.png","contentUrl":"https:\/\/bortnemorthodontics.com\/staging\/wp-content\/uploads\/2025\/03\/bortnem-orthodontics.png","width":250,"height":250,"caption":"Bortnem Orthodontics Logo"},{"@type":"BreadcrumbList","@id":"https:\/\/bortnemorthodontics.com\/staging\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/bortnemorthodontics.com\/staging\/"},{"@type":"ListItem","position":2,"name":"Home"}]},{"@type":"WebSite","@id":"https:\/\/bortnemorthodontics.com\/staging\/#website","url":"https:\/\/bortnemorthodontics.com\/staging\/","name":"Bortnem Orthodontics","description":"","publisher":{"@id":"https:\/\/bortnemorthodontics.com\/staging\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/bortnemorthodontics.com\/staging\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/bortnemorthodontics.com\/staging\/#organization","name":"Bortnem Orthodontics","url":"https:\/\/bortnemorthodontics.com\/staging\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/bortnemorthodontics.com\/staging\/#\/schema\/logo\/image\/","url":"https:\/\/bortnemorthodontics.com\/staging\/wp-content\/uploads\/2025\/03\/bortnem-orthodontics.png","contentUrl":"https:\/\/bortnemorthodontics.com\/staging\/wp-content\/uploads\/2025\/03\/bortnem-orthodontics.png","width":250,"height":250,"caption":"Bortnem Orthodontics"},"image":{"@id":"https:\/\/bortnemorthodontics.com\/staging\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/pages\/12","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/users\/43"}],"replies":[{"embeddable":true,"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/comments?post=12"}],"version-history":[{"count":1,"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/pages\/12\/revisions"}],"predecessor-version":[{"id":34674,"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/pages\/12\/revisions\/34674"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/media\/2703"}],"wp:attachment":[{"href":"https:\/\/bortnemorthodontics.com\/staging\/wp-json\/wp\/v2\/media?parent=12"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}