php-windows Digest 26 Oct 2002 17:51:16 -0000 Issue 1408

Topics (messages 16566 through 16570):

<Script language=php???
        16566 by: Jason Porembski
        16567 by: Warren Vail
        16568 by: John Meyer
        16570 by: George William Smith

URL Validation
        16569 by: Jan S.

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message ---
Hey folks.  I am attempting to run PHP code with <script language="php"> and
it doesn't work.  Any ideas as to why and how I can fix that?  Also what is
the best way to run a snippet of PHP code in an ASP page?  Thanks in
advance.

Jason "Gluten Mifflin" Porembski
http://www.world-gaming.com


--- End Message ---
--- Begin Message ---
Don't know if this will help, but it looks to me that you are trying to
identify a browser based scripting language in html format;

<script language="php">

For that to work, Netscape and IE would need to be able to execute your
code, and as of my last check that wasn't even in the works.  PHP is
designed to run "server side", not "browser side".

To your second question; ASP is a server side language running under IIS,
and if installed properly PHP is also.  That does not mean that you can
switch to PHP coding in a ASP script, but there should be ways that they can
interface.  Haven't tried this but if you have a way in ASP to invoke
another URL (Include may not do the trick) something like PHP's

$fp = fopen("http://www.yourdomain.com/info/test.php?parm1=5&parm2=3","r";);
$info = fread($fp,2048);

Notice that you can pass parameters in the "get" format to the URL, and
$info contains the data generated by the PHP script (there should be some
equivalent technique in ASP).  This technique should work with relative
URL's as well.

there are probably other methods of doing the same thing as well, good luck.

Warren Vail
[EMAIL PROTECTED]


-----Original Message-----
From: Jason Porembski [mailto:jporembs@;optonline.net]
Sent: Friday, October 25, 2002 8:32 PM
To: [EMAIL PROTECTED]
Subject: [PHP-WIN] <Script language=php???


Hey folks.  I am attempting to run PHP code with <script language="php"> and
it doesn't work.  Any ideas as to why and how I can fix that?  Also what is
the best way to run a snippet of PHP code in an ASP page?  Thanks in
advance.

Jason "Gluten Mifflin" Porembski
http://www.world-gaming.com



--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



--- End Message ---
--- Begin Message ---
Technically speaking, that's not true.  ASP is a set of objects that can be
manipulated via  a server side scripting language.  VBScript is the most
famous, but you can also use JScript, Perl or even Python in an ASP page.

-----Original Message-----
From: Warren Vail [mailto:warren@;vailtech.net]
Sent: Saturday, October 26, 2002 10:13 AM
To: Jason Porembski; [EMAIL PROTECTED]
Subject: RE: [PHP-WIN] <Script language=php???


D

To your second question; ASP is a server side language running under IIS,
and if installed properly PHP is also.

--- End Message ---
--- Begin Message ---
No, see http://uk.php.net/manual/en/language.basic-syntax.php

I quote: "There are four sets of tags which can be used to denote blocks of
PHP code. Of these, only two (<?php. . .?> and <script language="php">. .
.</script>) are always available;"

<script language="php"> /* PHP CODE */ </script> is perfectly valid way of
escaping from HTML into PHP.

G

"Warren Vail" <[EMAIL PROTECTED]> wrote in message
news:006401c27d0a$9872cac0$9b897ed8@;WarrenVail...
> Don't know if this will help, but it looks to me that you are trying to
> identify a browser based scripting language in html format;
>
> <script language="php">
>
> For that to work, Netscape and IE would need to be able to execute your
> code, and as of my last check that wasn't even in the works.  PHP is
> designed to run "server side", not "browser side".
>
> To your second question; ASP is a server side language running under IIS,
> and if installed properly PHP is also.  That does not mean that you can
> switch to PHP coding in a ASP script, but there should be ways that they
can
> interface.  Haven't tried this but if you have a way in ASP to invoke
> another URL (Include may not do the trick) something like PHP's
>
> $fp =
fopen("http://www.yourdomain.com/info/test.php?parm1=5&parm2=3","r";);
> $info = fread($fp,2048);
>
> Notice that you can pass parameters in the "get" format to the URL, and
> $info contains the data generated by the PHP script (there should be some
> equivalent technique in ASP).  This technique should work with relative
> URL's as well.
>
> there are probably other methods of doing the same thing as well, good
luck.
>
> Warren Vail
> [EMAIL PROTECTED]
>
>
> -----Original Message-----
> From: Jason Porembski [mailto:jporembs@;optonline.net]
> Sent: Friday, October 25, 2002 8:32 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP-WIN] <Script language=php???
>
>
> Hey folks.  I am attempting to run PHP code with <script language="php">
and
> it doesn't work.  Any ideas as to why and how I can fix that?  Also what
is
> the best way to run a snippet of PHP code in an ASP page?  Thanks in
> advance.
>
> Jason "Gluten Mifflin" Porembski
> http://www.world-gaming.com
>
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>




--- End Message ---
--- Begin Message ---
hello, i have written a litle script how validate a url (ns) but it isn't perfect ... 
plz help me

if(preg_match("/^ns([1-9]*)\.([a-z0-9-]+)\.([a-z]{2,})\.$/",$url)) echo 'url ok';

// for bind (zones) @ linux 
example: $url='ns1.testing.com.'; // work fine
but $url='ns1.-testing.com.'; // is also working ... but it isn't a valid url ...

Jan S.
Germany
--- End Message ---

Reply via email to