• Resolved raphaelle_s

    (@raphaelle_s)


    Hi everyone,

    I’m trying to add a page(with php inside) to my theme with a plugin, with: add_pages_page, or add_options_page but I get a page in the admin part of my site, and I want to add one in my theme: does anyone know wich function I can use?

    In advance thanks

    Best regards

    Raphaelle

Viewing 1 replies (of 1 total)
  • Thread Starter raphaelle_s

    (@raphaelle_s)

    I found the solution: here si the code:

    add_shortcode('page_listauthors', array(&$this, 'listauthors_page_shortcode'));
    
    ### Function: Short Code For Inserting list authors Into Page
    
    		function listauthors_page_shortcode($atts) {
    			return $this->listauthors_page();
    		}
    ### Function: List authors Page
    		function listauthors_page() {	echo" voici ma page";}

    After that, must create a page in administration settings, which url will be “https://youblog_domain/listauthors”
    and in page text write:[page_listauthors]

Viewing 1 replies (of 1 total)
  • The topic ‘Add a page to my theme with a plugin’ is closed to new replies.