Re: [PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Chris Shiflett

Georgie,

Then what you're doing should work perfectly fine. Can you give more 
details about the error received?

The reason I ask is because a Web browser will submit the exact same 
request for that URL that you do when you type it in yourself. Thus, if 
you don't see any PHP code, neither should the browser when it tries to 
execute that as javascript.

Chris

Georgie Casey wrote:

>The Javascript has to be called from other servers, some who might not even
>support PHP. And yeah, when you actually visit the URL, it displays perfect
>JavaScript
>


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




Re: [PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Georgie Casey

The Javascript has to be called from other servers, some who might not even
support PHP. And yeah, when you actually visit the URL, it displays perfect
JavaScript

Thanks anyway
"Chris Shiflett" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Georgie,
>
> I'm not sure what you're wanting to do here, but it looks like you just
> want to use PHP to write some javascript. There's no need to make the
> browser request an additional page for this. Just do something like this
> in your PHP script:
>
> 
>  PHP stuff here - output is valid javascript
> ?>
> 
>
> or even:
>
> 
>  include("/home/georgie/top_stuff.php");
> ?>
> 
>
> However, speaking directly to your problem, see what you see when you
> access that URL (http://localhost/top_stuff.php?affiliate=1) yourself.
> If your PHP scripts are not being processed and instead are just
> displayed in the browser, then your Web server is not configured to
> process PHP.
>
> Happy hacking.
>
> Chris
>
> Georgie Casey wrote:
>
> >In HTML, you can do this:
> > >src="http://localhost/top_stuff.php?affiliate=1";>
> >
> >But the script isn't executed before being used by the browser, it's
> >returned with PHP tags and all, which obviously gives JS errors. Is there
> >any setting you can change in Apache that let's you do this.
> >
>



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




Re: [PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Chris Shiflett

Georgie,

I'm not sure what you're wanting to do here, but it looks like you just 
want to use PHP to write some javascript. There's no need to make the 
browser request an additional page for this. Just do something like this 
in your PHP script:





or even:





However, speaking directly to your problem, see what you see when you 
access that URL (http://localhost/top_stuff.php?affiliate=1) yourself. 
If your PHP scripts are not being processed and instead are just 
displayed in the browser, then your Web server is not configured to 
process PHP.

Happy hacking.

Chris

Georgie Casey wrote:

>In HTML, you can do this:
>src="http://localhost/top_stuff.php?affiliate=1";>
>
>But the script isn't executed before being used by the browser, it's
>returned with PHP tags and all, which obviously gives JS errors. Is there
>any setting you can change in Apache that let's you do this.
>


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




[PHP] JAVASCRIPT INCLUDES

2002-09-22 Thread Georgie Casey

In HTML, you can do this:
http://localhost/top_stuff.php?affiliate=1";>

But the script isn't executed before being used by the browser, it's
returned with PHP tags and all, which obviously gives JS errors. Is there
any setting you can change in Apache that let's you do this.



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