Announcement

Collapse
No announcement yet.

Can PHP be used within a template?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Can PHP be used within a template?

    I basically have some templates that I'm editing that were taken from a hardcoded page that had some simple PHP calls like 'include' and 'require'.

    Is there a way to call out PHP thru the style manager?

  • #2
    99% of the templates? No.

    In phpinclude_start yes

    Comment


    • #3
      Hi there

      In the phpinclude_start/end templates you can put your php code.
      If you want to show a result in a template, put it in a variable:

      // this is for the phpinclude_start
      $blah = "Blah blah";

      // example for forumhome
      // in forumhome, above the guest welcome message, add
      <div>$blah</div>


      You can do this with your php functions now.

      Comment


      • #4
        Whats the difference between phpinclude_start and phpinclude_end ?

        Comment


        • #5
          Originally posted by b00tsauce
          Whats the difference between phpinclude_start and phpinclude_end ?
          I believe that phpincude_start is ran before the page contents is displayed and executed, whereas phpinclude_end would be after the page has been executed.
          Bugdar: PHP bug tracking software that is beautiful, fast, and robust.

          Comment

          Loading...
          Working...
          X