Zen Cart Logo
Forums / General Questions / PHP inside EZpages

PHP inside EZpages

Locked

Views: 1,454

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
15 Nov 2008, 7:00 AM
#1
hookah avatar

hookah

New Zenner

Join Date:
Oct 2008
Location:
Oregon
Posts:
57
Plugin Contributions:
0

PHP inside EZpages

Is there a way I can have a php page in EZpages and have it wrapped by zencart? I have tried using both internal and external pages and in both cases, it opens the php application without wrapping it with the typical zencart wrapping.

The text editor doesn't allow for pasting the PHP code.

I am using 1.3.8

15 Nov 2008, 7:28 AM
#3
hookah avatar

hookah

New Zenner

Join Date:
Oct 2008
Location:
Oregon
Posts:
57
Plugin Contributions:
0

Re: PHP inside EZpages

That is for version 1.3.0 and I have 1.3.8. and never worked for me. I did find a way to put in an IF in the code saying if the page_id == {my page id} then include my php else do what was already there and it works but.... The page footer is missing. Everything below my include is missing.

My ezpage ID is 9, so in my copy of tpl_page_default.php on about line 57 I did this...

     
    <div>
    <?php
      if( $var_pageDetails->fields['pages_id'] == 9 ){
        include('lounge_directory.php');    
      } else {
        echo $var_pageDetails->fields['pages_html_text'];
      }
    ?> 
    </div>

The page can be found at
www.thehookahstore.com/index.php?main_page=page&id=9

misty:

Previous thread at
http://www.zen-cart.com/forum/showthread.php?t=37252&highlight=pages+include+php

15 Nov 2008, 7:40 AM
#4
misty avatar

misty

Inactive

Join Date:
Apr 2004
Location:
UK
Posts:
5,752
Plugin Contributions:
1

Re: PHP inside EZpages

That is for version 1.3.0 and I have 1.3.8.
Did you read WHOLE thread...