This topic is locked

include an user defined php file

4/24/2008 4:26:42 AM
PHPRunner General questions
W
webdino author

how can I include an user defined file in all templates
I will put there some global functions
which template must I change when I use application wizard to generate my own application
thank you for help

W
webdino author 4/24/2008

I have solved this problem, I include this file in commonfunctions.
But where can I include a java script file? this must be in the header but I can´t find a header.php

J
Jane 4/24/2008

Hi,
you can create header.php file manually in the output/include directory and place your code in it.

W
webdino author 4/24/2008

thank you
but there is another question

I want to set an sql request before list page was listed.
I find the function
$strSQLExists = "select * from AnyTable where AnyColumn='AnyValue'";

$rsExists = db_query($strSQLExists,$conn);

$data=db_fetch_array($rsExists);
but it does not give me an array of results

I will ask for all results of my sql which function must I use?

J
Jane 4/24/2008

Please make sure you've replaced AnyTable and AbyColumn with your actual names.

Also you can print returned values for debugging purpose:

...

$data=db_fetch_array($rsExists);

print_r($data);