Outputs templates after the content as needed.

@param string $content Post content

@uses  'the_content' filter

@return string Post content with the template appended if appropriate.

@since 2.4.5
182707
public function front( $content ) {

		// get the current post type
		$current_post_type = $this->current_post_type();

		// now use other methods in class to build array to search in/ use
		$possible_pods = $this->auto_pods();

		// check if $current_post_type is the key of the array of possible pods
		if ( isset( $possible_pods[ $current_post_type ] ) ) {
			// get array for the current post type
			$this_pod = $possible_pods[ $current_post_type ];

			$filter = $this->get_pod_filter( $current_post_type, $possible_pods );

			if ( current_filter() !== $filter ) {
				return $content;
			}

			if ( ! in_the_loop() && ! pods_v( 'run_outside_loop', $this_pod, false ) ) {
				// If outside of the loop, exit quickly
				return $content;
			}

			// build Pods object for current item
			global $post;
			$pods = pods( $current_post_type, $post->ID );

			if ( $this_pod['single'] && is_singular( $current_post_type ) ) {
				// load the template
				$content = $this->load_template( $this_pod['single'], $content, $pods, $this_pod['single_append'] );
			} //end if
			// check if we are on an archive of the post type
			elseif ( $this_pod['archive'] && is_post_type_archive( $current_post_type ) ) {
				// load the template
				$content = $this->load_template( $this_pod['archive'], $content, $pods, $this_pod['archive_append'] );

			} elseif ( is_home() && $this_pod['archive'] && $current_post_type === 'post' ) {
				// if pfat_archive was set and we're in the blog index, try to append template
				// append the template
				$content = $this->load_template( $this_pod['archive'], $content, $pods, $this_pod['archive_append'] );

			} elseif ( is_tax( $current_post_type ) ) {
				// if is taxonomy archive of the selected taxonomy
				// if pfat_single was set try to use that template
				if ( $this_pod['archive'] ) {
					// append the template
					$content = $this->load_template( $this_pod['archive'], $content, $pods, $this_pod['archive_append'] );
				}
			}
		}//end if

		return $content;

	}
275539
public static function getHtmlAttributes($content)
    {
        $content = self::getHtmlTags($content, false);

        if (!is_array($content) || empty($content)) {
            return;
        }

        $content = implode($content);

        $re = '@(\s+)(\S+)=["\']?((?:.(?!["\']?\s+(?:\S+)=|[>]))+.)["\']?@';

        preg_match_all($re, $content, $matches, PREG_SET_ORDER, 0);

        $atts = array();
        if ($matches) {
            foreach ($matches as $match) {
                $atts[$match[2]] = $match[0];
            }

            return $atts;
        }

        return;
    }
1360382
protected function applySiteSpecificFilters($content)
    {
        $filters = $this->getSiteSpecificFilters();

        $from = array_keys($filters);
        $to = array_values($filters);

        return str_replace($from, $to, $content);
    }
493396
public function prepareContent($content)
    {
        $cto = $this->getContentTypeObject();
        if (!empty($cto)) {
            return $cto->prepareContent($content);
        } else {
            return (string) $content;
        }
    }
551431
public function parseContent($content)
    {
        $cto = $this->getContentTypeObject();
        if (!empty($cto)) {
            return $cto->parseContent($content);
        } else {
            return $content;
        }
    }
1249396
protected function formatContent($content)
    {
        if ($this->request->method == 'HEAD') {
            return (object) $this->headers;
        }

        if ($this->isXml()) {
            return json_decode($this->parseXml($content));
        }

        if ($this->isJson()) {
            return json_decode($content);
        }
    }
1072903
public static function buildAndGetPage(string $content) :string {
		// initial content
		$page = '<!doctype html><html lang="'.\Polyfony\Locales::getLanguage().'"><head><title>'.(isset(self::$_metas['title']) ? self::$_metas['title'] : '').'</title><meta http-equiv="content-type" content="text/html; charset=' . \Polyfony\Response::getCharset() . '" />';
		// add the meta tags and the links
		$page .= self::buildMetasTags() . self::buildLinksTags();
		// close the head, add the body, and add the scripts
		$page .= '</head><body>' . $content . self::buildScriptsTags();
		// add the profiler (if enabled)
		$page .= \Polyfony\Config::get('profiler', 'enable') ? new \Polyfony\Profiler\HTML : '';
		// close the document and return the assembled html page
		return $page . '</body></html>';

	}
1234063
public function renderContainer($content = null)
    {
        if ($this->UseContainer) {
            
            return sprintf(
                "<div class=\"%s\">\n<div class=\"%s\">\n%s</div>\n</div>\n",
                $this->getContainerClass(),
                $this->getHTMLClass(),
                $content
            );
            
        }
        
        return $content;
    }
1070833
protected function _getContent($content)
    {
        if(!isset($content))
            return;

        if(is_array($content))
            return array_map(
                function ($value) {
                    return $this->_getContent($value);
                }, $content
            );

        switch(gettype($content)) {
            case 'string': case 'integer': case 'double': case 'float':
                return $content;
            break;
            case 'object':
                if('Closure' == get_class($content)) {
                    ob_start();
                    ob_clean();
                    $returned = $content($this->data);
                    $output = ob_get_clean();
                    if(isset($returned))
                        return $returned;
                    else
                        return $output;
                } elseif(isset($content->content))
                    return $content->content;
            break;
            default:
                throw new \InvalidArgumentException('wrong view content type : '.gettype($content));
        }
    }
259456
protected function renderLayout(string $content): string
    {
        $content = str_replace('<!-- extends "' . $this->layout . '" -->', '', $content);
        $content = trim($content);
        $this->assign(['content' => $content]);
        $layoutFile = $this->pathLayouts . '/' . $this->layout . '.phtml';
        return $this->renderFile($layoutFile);
    }
1156807
public function parseLang($content) {
        $this->_content = $content;
        $this->_parseDebugStart();
        $this->_parsePath();
        $this->_parseGravatar();
        $this->_parseUrl();
        $this->_parsePhp();
        $this->_parseLang();
        $this->_parseForeach();
        $this->_parseFor();
        $this->_parseVar();
        $this->_parseVarFunc();
        $this->_parseCondition();
        $this->_parseFunction();
        $this->_parseException();
        $this->_parseDebugEnd();

        return $this->_content;
    }
1066021
protected function processVars(string &$content): void
    {
        $pattern = $this->getTagPattern('(\$.+?)');
        $content = preg_replace_callback($pattern, function ($match) {
            return '<?php echo ' . $match[1] . '; ?>';
        }, $content);
    }
244087
public function __output($content){
	
		if(method_exists($this,'_beforeView')){
			$this->_beforeView();
		}
		
		Loader::getClass('Sky.core.Output')->append($content)->render();
		
		if(method_exists($this,'_afterView')){
			$this->_afterView();
		}
	}
1051268
protected function parseContent($content)
    {
        $content = preg_replace_callback($this->shortcodeRegex(), [$this, 'doShortcodeTag'], $content);
        if (!$this->isFinishedParse()) {
            $content = $this->parseContent($content);
        }
        return $content;
    }
931948
public function contentParser($content)
    {
        return str_replace(['{{dataApiUrl}}', '{{title}}', '{{template}}'], [$this->getDataApiUrl(), $this->getTitle(), $this->_template], $content);
    }
467959
public function render($content) {
        $form = $this->getElement();
        if (!$form instanceof \Zend_Form) {
            return $content;
        }

        $this->_recurseForm($form);

        return $content;
    }
898625
public function json($content)
    {
        if (is_array($content)) {
            $content = json_encode($content);
        }

        $this->content = $content;

        return $this->header('Content-Type', 'application/json');
    }