Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19
apache server side includes
Results 1 to 4 of 4

Thread: apache server side includes

  1. #1
    Junior Member
    Join Date
    Dec 2001
    Posts
    65

    apache server side includes

    hi all

    i'm trying to configure my apache box - rh7.1, 2.4.2-2, apache 1.3.22 - for server side includes. i've went through the tutorial on ssi, but i have a few questions.

    -i'd like to use ssi's to generate a small footer at the bottom of most webpages being served up, this would be like

    'date last modified' &/or a copyright notice. do most folks use apache ssi's to generate these? or do they use cgi's and such?

    -webmin says that mod_include is enabled, however the line Option +Includes isn't in my httpd.conf, i'm confused where to put it in httpd.conf and a line similar to 'AddType text/html .shtml AddHandler server-parsed .shtml' needs to go in httpd.conf in order to get ssi's to work. hopefully, i'm going about this the right way...

    as of now, when i try to put an ssi tag in one of my pages like

    <!--#echo var="DATE_LOCAL" -->

    it doesn't seem to work. am i going about this the right way? please let me know, also please let me know if there's a better way to get ssi's going...

    thanks again
    p.



  2. #2
    Moderator
    Good Guru
    Compunuts's Avatar
    Join Date
    May 2001
    Location
    California
    Posts
    3,935

    Re: apache server side includes

    do most folks use apache ssi's to generate these? or do they use cgi's and such?
    It all depends on how you want to do it. In CGI, the script do it for you but in SSI, you will have to define your own directives if no such directives are available in default.

    -webmin says that mod_include is enabled, however the line Option +Includes isn't in my httpd.conf, i'm confused where to put it in httpd.conf and a line similar to *'AddType text/html .shtml AddHandler server-parsed .shtml' needs to go in httpd.conf in order to get ssi's to work. *hopefully, i'm going about this the right way...
    Yes, you are. To get SSI to parse documents for you, you need the above four enabled. I've never used Webmin for it so I do not know how but if you are willing to edit httpd.conf, add them to your httpd.conf file. There you will see the commented sections so it's easy to find. If not, they are usually lay out after <Directory> directives.

    when i try to put an ssi tag in one of my pages like

    <!--#echo var="DATE_LOCAL" -->

    it doesn't seem to work. *am i going about this the right way?
    Is your document name ( web page ) is shtml??
    Is there a space between ! and - ??

    please let me know if there's a better way to get ssi's going...
    Yes, there is. You can set the XBi tHack bit to either on or Full. But it still required you to enable mod_ssi and AddType stuff. And also, you must set all the documents that you want to parse to excute bit with chmod. But as far as my experience is concerned, XBi tHack runs faster in bigger sites with more dynamic contents since it do not have to check and parse all requested files but only the documents that X bit is set.

    HTH ....

  3. #3
    Mentor coltrane's Avatar
    Join Date
    May 2001
    Location
    North Carolina
    Posts
    1,390

    Re: apache server side includes

    Personally, Ive just created php documents full of classes in a hidden includes folder . I then reference that file and class at the foot of every php document thats viewed by the public.

    IE
    The following appears at the bottom of all my pages
    Code:
    // finally print the footer
    if (PHP_group == 1) {
      $phpgw->common->phpgw_footer();
    } else {
      require('./includes/system_footer.php');
    }
    
    ?>

    Just another option

  4. #4
    Moderator
    Good Guru
    Compunuts's Avatar
    Join Date
    May 2001
    Location
    California
    Posts
    3,935

    Re: apache server side includes

    PHP is nice for highly dynamic contents but SSI is useful for maintaining the uniform looks of the site with majorly static information.

Similar Threads

  1. apache server problem
    By pankajkarde in forum Redhat / Fedora
    Replies: 2
    Last Post: 01-17-2007, 10:16 AM
  2. PHP + Apache web server
    By honey bee in forum Linux - Hardware, Networking & Security
    Replies: 8
    Last Post: 05-18-2006, 10:05 AM
  3. Apache Web Server Troubles
    By [a2]ACE in forum Linux - Software, Applications & Programming
    Replies: 2
    Last Post: 02-04-2006, 08:37 AM
  4. apache server with SSL connection
    By erictcy in forum Linux - General Topics
    Replies: 0
    Last Post: 10-21-2004, 02:15 AM
  5. apache server
    By M_A_G_I_C in forum Linux - Software, Applications & Programming
    Replies: 2
    Last Post: 12-05-2002, 12:38 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •