You could use switch_theme function.
Accepts one argument: $stylesheet of the theme. ($stylesheet is the name of your folder slug. It’s the same value that you’d use for a child theme, something like “twentythirteen”.)
Documentation: switch_theme
Related Posts:
- How to add CSS class to custom logo?
- theme path in javascript file
- The proper way to include/require PHP files in WordPress
- How to insert a logo in the header?
- Add a dropdown to theme customizer
- Why doesn’t default WordPress page view use force_balance_tags?
- Theme Customizer : how to create multiple-level panel
- What is the problem if I use CDN in my WordPress parent theme(built using bootstrap)?
- Automatic Updates For Private And Commercial Themes?
- What can I hook into after_setup_theme?
- add_image_size is scaling, even though crop is set to true
- How to check if post has any tag?
- Which is the simplest theme for WordPress to use it as your base?
- A theme that follows all the best practices to learn from?
- get_post() function returns post even if it is trashed
- How to highlight the current page in the nav menu?
- How to use bloginfo( ‘template_directory’ ) in array
- Should I update my _s theme?
- Setting a Default ‘Theme Location’ When Creating a Menu
- How to set page template on front using starter content?
- Different Admin Theme – Based on Role?
- Finding Page Template and Displaying Content
- Override Constants in Child theme
- How to correctly add JQuery in a WP theme?
- Custom theme not visible in Appearance
- how to change a theme slug
- Same theme name issue with wordpress repository theme
- Removing feeds from header using a function?
- I want to get the home root path
- How to add code in the content area in a WordPress theme?
- How to add a second stylesheet to the editor
- Developing WordPress Theme using CSS framework like Bootstrap
- WP_Customize_Color_Control omitting # symbol
- Single Page theme [closed]
- Theme translation not applying
- How to add filter the post thumbnail before save in database?
- Can I have two different theme for two different language?
- Storefront child theme not applying parent theme [closed]
- How to add Space between sidebar and footer widget in WordPress theme [closed]
- Theme Inspector “X-Ray”
- Acivate all themes multisite wide automatically
- Customize how a WordPress theme looks like in the Theme Selector
- How to set a page as homepage in stead of the newspages?
- Admin: sub menu doesnt display under apperance when activate my themes
- Widget Option is Missing
- WordPress Theme Validator?
- If you were to start using a WordPress framework today, which one would you use? [closed]
- Template for landing pages
- Is it possible to have a theme that uses only one single page?
- underscores use of the article element on the page template
- Plugin does not work in custom theme
- html5-reset theme does not show the image [closed]
- Adding a gallery to my first theme
- Are seven additional image sizes are too many?
- What exactly is “wordpress theming”? [closed]
- registering a global template wordpress 6.0
- Copying the theme style files and images to duplicate the website but with a difference
- How to set Post meta-box defaults based on the choices made by user in Customizer?
- Theme Action to hook for one time only function [duplicate]
- Valid SQL query not returning results
- Change Image Sizes for Mobile Theme
- Recommended sidebar / content widths
- Converting a theme to a child theme in a network
- HTTP Error when uploading images over specific dimensions
- What is the difference between Twenty eleven & roots framework?
- iPad WordPress theme?
- custom Background not showing after upgrade?
- Rolling your own WordPress Themes
- Is there a list of default generated Gutenberg block CSS? Unable to align video blocks
- PHP Parse error: syntax error, unexpected ‘endwhile’ (T_ENDWHILE), expecting elseif (T_ELSEIF) or else (T_ELSE) or endif (T_ENDIF) on line 124
- How to change listing type permlink?
- Adding popup support to the theme
- Calling a WP Plugin Function’s Variable in Theme Template [duplicate]
- How to make updatable custom WordPress theme?
- How can I access variables from theme in child theme? [closed]
- Local variable name in setup_postdata()
- Creating a Single Page Theme correctly
- Is it possible to echo a woocommerce prouct attribute discription?
- Child theme menu not appearing in Twenty Seventeen
- How do I remove header/page-title image in farvis theme? [closed]
- Is a multipurpose theme an alternative to modifying or creating a theme from scratch?
- How to link post image to post link?
- WordPress Twenty-Fourteen: How to Remove Home Page Header Image from Other Pages
- On wordpress, how do i require specific dimensions from user uploads only
- WordPress Theme Developments – Start from another theme
- Slider should be display in home template [closed]
- Modify comments_popup_link output
- Can you create a custom page with content in the center already defined?
- How to migrate the menu from the site on my own theme in WordPress?
- Trouble creating custom sanitization function when uploading video files
- What’s the policy for building a theme that doesn’t support widgets/menus?
- RSS feed url showing page not found. How to solve it?
- How to convert that page to a wordpress template? [closed]
- Toolbox theme using printif statement – help needed understanding code block
- php file child theme directory not overriding parent theme php file [duplicate]
- How to Create a Multi Purpose Theme?
- Custom Single Page Portfolio Theme [closed]
- getting id of page
- What is the point of using the front-page.php template? [closed]
- Is child-theme required when modyfing “Appearence > Editor”?