CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> Archive -> CodeCharge.Discussion

 including extern javascripts in php4-templates

Print topic Send  topic

Author Message
jan
Posted: 07/09/2001, 5:42 AM

Hi!

I have the following problem:
I want to include extern javascripts in the templates, which are parsed by
php4, but the .js files seem not to be included.
I testet the .js file with a normal html-file and also wrote the js-code
directly into the template, both worked fine, therefore the javascript can
not the be the problem. The path is set also correct ( I am including css
files from the same directory and it works fine).

Up to now I only found a workaround by parsing the javascript into the
template, which is not the way I want to do it.

Thanks,
jan

For those who are interested in the workaround:
$str = <<<EOD
var win=null;
function NewWindow(mypage,myname,w,h,scroll,pos){

if(pos=="random"){LeftPosition=(screen.width)?Math.floor(Math.random()*(scre
en.width-w)):100;TopPosition=(screen.height)?Math.floor(Math.random()*((scre
en.height-h)-75)):100;}
if(pos=="center"){LeftPosition=(screen.width)?(screen.width-w)/2:100;TopPosi
tion=(screen.height)?(screen.height-h)/2:100;}
else if((pos!="center" && pos!="random") ||
pos==null){LeftPosition=0;TopPosition=20}
settings='width='+w+',height='+h+',top='+TopPosition+',left='+LeftPosition+'
,scrollbars='+scroll+',location=no,directories=no,status=no,menubar=no,toolb
ar=no,resizable=no';
win=window.open(mypage,myname,settings);}
EOD;
$tpl->set_var("skripts", $str);



   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.