get_page_excerpt() not working - Printable Version +- GetSimple Support Forum (http://get-simple.info/forums) +-- Forum: GetSimple (http://get-simple.info/forums/forumdisplay.php?fid=3) +--- Forum: General Questions and Problems (http://get-simple.info/forums/forumdisplay.php?fid=16) +--- Thread: get_page_excerpt() not working (/showthread.php?tid=10480) |
get_page_excerpt() not working - bluzer - 2018-05-20 I am building a test site and am having trouble getting get_page_excerpt(250, $file) to work. there are no errors in development tools, debug, errorlog, or on screen. <section> <a href="<?php echo $file; ?>" <- this works <h2><?php echo $page; ?></h2> <-this works </a><?php get_page_excerpt(250,$file);<- this doesn't work //getPageContent($file); ?> <- this works <p><a href="<?php echo $file; ?>">Read More...</a><- this works </p> </section> Any suggestions? RE: get_page_excerpt() not working - Bigin - 2018-05-20 What is $file? RE: get_page_excerpt() not working - Bigin - 2018-05-20 This function does not expect $file RE: get_page_excerpt() not working - Carlos - 2018-05-20 get_page_excerpt() displays an excerpt of the current page. It doesn't work for other pages, since there's no parameter to specify another page slug. This may work for page with slug $slug : Code: <?php echo getExcerpt(returnPageContent($slug), 250); ?> RE: get_page_excerpt() not working - bluzer - 2018-05-21 (2018-05-20, 16:33:23)Carlos Wrote: get_page_excerpt() displays an excerpt of the current page. It doesn't work for other pages, since there's no parameter to specify another page slug. Thanks I will try this! |