in reply to Problem to includ a perl file
Hay varios razones porque su ejemplo no funciona. Primera es que seria una violacion de seguridad si el webserver no prohibe cualquiera pagina de html ejecutar una script en cualquier directorio--alguien se puede escribir una script y ejecutarlo sin tener los permisos.
Segundo es que el html tag <script> necesita el atributo "type", y los valores permitidos no incluyen perl. Aqui esta detalles, pero en breve--<script> es solo para ordenar el cliente (typicamente un web browser) a ejecutar una script.
Perdoname mi castellano--hace muchas meses que escribia en la idioma, y nunca de sujectos tecnicos (que Ud. ya sospecha, pienso!).
Boy is my face red: I thought I saw Spanish in the OP and decided to try to show off. Teach me to write anything before coffee.
There are several reasons why your example doesn't work. First is that it would be poor security if the webserver allowed any old html page to exectute any old script in any directory--anyone could write a script and execute it without having the permissions to do so.
Second is that the html tag <script> requires the attribute "type" and the allowed values don't include perl. Here are the details, but in short--<script> is only for telling the client (typically a web browser) to execute code.
My apologies for my Spanish--it's been months since I've written in that language, and never on technical matters (as you probably suspect!).
Further attempt to atone for the above goof:
The tag you're probably looking for is:
<!--#exec cmd="command [arguments...]"-->
Note that your server has to be configured to allow this sort of thing.
Sweet jebus, I didn't notice he wants a JS solution. That's it, I'm going to go drink several cups of coffee and start over with PM today. Do me a favor and ignore this w/u.
AH
Using perl 5.6.1 unless otherwise noted. Apache 1.3.27 unless otherwise noted. Redhat 7.1 unless otherwise noted.
|
|---|