This topic is locked

Menu Page, inserting php

10/2/2007 9:29:15 AM
PHPRunner General questions
spettinato author

Hi all, is it possible to inserti in menu page or other pages some php code? For example, if i want to show the number of mailing list user in a field of a database, i have to query database and show results on a page. So, is it possible to write some php code inside phprunner editor for the page? Thanks.

A
alang 10/2/2007

Sure. On the visual editor page you can "Insert PHP code snippet". This creates an "event" which is called when the page displays and you can output results using echo statement. I have used this technique to add lines to the tables in View/Edit pages etc. Example:
[codebox]echo "<TR><TD class=shade>".$iref."</TD><TD>".$idat."</TD></TR>";[/codebox]