WebmasterSite.net: PHP scripts to enable your creativity
WSN Links PHP Directory Software
PHP Scripts Webmaster Links Support Forums

Register | Forgot Password

Javascript Export
How to use Static Javascript Files

Version: 2.12
printPrint


Javascript Export
Vix
Member

Usergroup: Customer
Joined: Dec 26, 2003
Total Topics: 5
Total Posts: 12
Posted 11/19/04 - 02:34 AM:
quote post
#1
I'm having a problem generating different .js file using the Javascript Export option. It's either that or a problem with the template I'm using.

Here's the template I'm using:




links,id,100,ascending,catid='11',4,0,0,0,0







This works fine if I just generate 1 .js file, as it has the same config. But adding a second config line inside Javascript Export doesn't work because .js file #2 has the same content as .js file #1.

Any thoughts on what I'm doing wrong.


Paul
Administrator
Avatar

Usergroup: Administrator
Joined: Dec 21, 2001
Location: Northern California
Total Topics: 57
Total Posts: 6189
Posted 11/22/04 - 02:30 AM:
quote post
#2
Config lines should be specified on the JS export page, not the template.

"Do things you love doing, because then it ain't work. Don't do something you don't really enjoy, because you're never going to work hard enough at it." - Bob Young, founder of Red Hat
Vix
Member

Usergroup: Customer
Joined: Dec 26, 2003
Total Topics: 5
Total Posts: 12
Posted 12/03/04 - 07:40 PM:
quote post
#3
This is how my template looks like:











And here's what I placed in the Javascript Export page:


Config:
links,id,100,ascending,catid='11',4,0,0,0,0
links,id,100,ascending,catid='75',4,0,0,0,0

Filename:
gall_survivingchristmas.js
gall_manabouttown.js


I get these errors:


Warning: fopen(../javascript/): failed to open stream: Is a directory in path/to/filefunctions.php on line 148

Warning: fwrite(): supplied argument is not a valid stream resource in path/to/filefunctions.php on line 149

Warning: fwrite(): supplied argument is not a valid stream resource in path/to/filefunctions.php on line 150

Warning: fclose(): supplied argument is not a valid stream resource in path/to/filefunctions.php on line 151

* This error message repeats an additional 3 times

and the javscript files contain this:


document.write('Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /path/to/classes/database.php on line 72
');



Paul
Administrator
Avatar

Usergroup: Administrator
Joined: Dec 21, 2001
Location: Northern California
Total Topics: 57
Total Posts: 6189
0 of 1 people found this post helpful
Posted 12/04/04 - 10:00 AM:

quote post
#4
The errors state that you have file permissions problems preventing it from being allowed to write.

I can generate your two toplists with no problem.

"Do things you love doing, because then it ain't work. Don't do something you don't really enjoy, because you're never going to work hard enough at it." - Bob Young, founder of Red Hat
Search thread for
Download thread as


You don't have permission to post.

Please login or register.

   
 
© 2008 Paul Knierim. All rights reserved.