SSI_Parser(3pm)
β¨ NAME β¨
Okay bestie, welcome to a User Contributed Perl Documentation page π β this one's called SSI_Parser, and it's all about CGI::SSI_Parser, which implements SSI for Perl CGI. That's the whole vibe. No cap.
π¦ SYNOPSIS π¦
Here's the whole thing at a glance, copy-paste ready, exactly as written:
use CGI::SSI_Parser;
$CGI::SSI_Parser::recursive = 1;
fssi($filename);
sssi($string);
π DESCRIPTION π
So CGI::SSI_Parser is the module you reach for inside CGI scripts when you wanna parse SSI directives β whether they're chillin' in files or just vibing inside string variables. And it fully implements the functionality of apache's mod_include module. Like, full send. π
It's an alternative to the famous Apache::SSI modules, except β plot twist β it doesn't require mod_perl. That's the glow-up for anyone stuck on public hosting services. π
But bestie, we gotta talk about the downside π β this module consumes much memory, and the author straight up says he doesn't recommend using it on heavy-loaded sites. Currently it's being used on a site with 10000 hits, and he considers that the limit. He hopes to get rid of this disadvantage by the time the release comes out (right now it's beta, so, y'know).
πΈ SSI Directives πΈ
This module supports the same directives as mod_include. For methods listed below but not documented, please see mod_include's online documentation at http://httpd.apache.org/docs/mod/mod_include.html β go read it, iykyk.
configβ supported, go off β¨echoβ this directive is not fully supported in current version πexecβ supportedfsizeβ supportedflastmodβ supportedincludeβ supportedprintenvβ supportedsetβ this directive is not supported in current version πperlβ this directive is not supported in current version πifβ see the note below πelifβ see the note below πelseβ see the note below πendifβ see the note below π
These four directives βif,elif,else,endifβ are not supported in current version. Don't come for me, that's just what the page says π«Ά
π Outline Usage π
Step one, babe β load the CGI::SSI_Parser module:
use CGI::SSI_Parser;
Step two: if you need processing of all nested directives, you gotta specify this (and the default value is 0, so it's off unless you say otherwise):
$CGI::SSI_Parser::recursive = 1;
Step three: to parse a file or a string, you use:
fssi($filename);
sssi($string);
And the result? It gets printed to STDOUT. That's it, that's the whole ritual. π
π₯ TO DO π₯
The author's manifesting list, fr fr:
- Full implementation of all SSI directives.
- Optimize memory consumption.
π AUTHOR π
Vadim Y. Ponomarenko, vp@istc.kiev.ua β give him his flowers π
π SEE ALSO π
mod_includeperl(1)
And that's a wrap, bestie π This page came to you courtesy of perl v5.32.1, dated 2022-01-08, from the User Contributed Perl Documentation collection. Stan a well-documented module. Periodt. πβ¨π¦
π¦ where this page comes from
- debian bookworm: libcgi-ssi-parser-perl 0.01-2 Β· not-copyrighted
- debian trixie: libcgi-ssi-parser-perl 0.01-2 Β· not-copyrighted
- ubuntu jammy: libcgi-ssi-parser-perl 0.01-2 Β· not-copyrighted
- ubuntu noble: libcgi-ssi-parser-perl 0.01-2 Β· not-copyrighted
- ubuntu resolute: libcgi-ssi-parser-perl 0.01-2 Β· not-copyrighted
- ubuntu stonking: libcgi-ssi-parser-perl 0.01-2 Β· not-copyrighted
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms