Web Images Videos Maps News Shopping Gmail more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Sintassi codice JS in codice PHP
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  5 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
mbyte  
View profile   Translate to Translated (View Original)
 More options Jul 15 2008, 5:23 am
Newsgroups: it.comp.lang.javascript
From: mbyte <michela.police...@gmail.com>
Date: Tue, 15 Jul 2008 02:23:12 -0700 (PDT)
Local: Tues, Jul 15 2008 5:23 am
Subject: Sintassi codice JS in codice PHP
Ciao!
Vorrei sapere qual'è la sintassi corretta da utilizzare per inserire
codice Javascript in un sorgente PHP.
Grazie

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Alessandro Pellizzari  
View profile   Translate to Translated (View Original)
 More options Jul 15 2008, 5:34 am
Newsgroups: it.comp.lang.javascript
From: Alessandro Pellizzari <shuri...@amiran.it>
Date: 15 Jul 2008 09:34:04 GMT
Local: Tues, Jul 15 2008 5:34 am
Subject: Re: Sintassi codice JS in codice PHP
Il Tue, 15 Jul 2008 02:23:12 -0700, mbyte ha scritto:

> Vorrei sapere qual'è la sintassi corretta da utilizzare per inserire
> codice Javascript in un sorgente PHP. Grazie

La stessa che per inserirlo in HTML, visto che non dovresti mai mischiare
PHP e HTML se non in minima parte.

Se devi inserire parametri o codice condizionale:

<?php if ($insertjs): ?>
 <script type="text/javascript">
  alert("<?php echo "Pippo!"; ?>");
 </script>
<?php endif; ?>

Bye.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
mbyte  
View profile   Translate to Translated (View Original)
 More options Jul 15 2008, 5:44 am
Newsgroups: it.comp.lang.javascript
From: mbyte <michela.police...@gmail.com>
Date: Tue, 15 Jul 2008 02:44:08 -0700 (PDT)
Local: Tues, Jul 15 2008 5:44 am
Subject: Re: Sintassi codice JS in codice PHP
On 15 Lug, 11:34, Alessandro Pellizzari <shuri...@amiran.it> wrote:

Sono ignorante doc in materia... Ho copiato il codice che mi hai
indicato e l'ho inserito in un index.php. Quando accedo alla pagina
non succede nulla...
Non dovrei vedere la scritta "Pippo!" da qualche parte ?

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Darkbyte [Google]  
View profile   Translate to Translated (View Original)
 More options Jul 15 2008, 7:10 am
Newsgroups: it.comp.lang.javascript
From: "Darkbyte [Google]" <seprano.anto...@gmail.com>
Date: Tue, 15 Jul 2008 04:10:41 -0700 (PDT)
Local: Tues, Jul 15 2008 7:10 am
Subject: Re: Sintassi codice JS in codice PHP

> Sono ignorante doc in materia... Ho copiato il codice che mi hai
> indicato e l'ho inserito in un index.php. Quando accedo alla pagina
> non succede nulla...
> Non dovrei vedere la scritta "Pippo!" da qualche parte ?

<?php
  if (true)
  {
?>
<script type="text/javascript">
  alert("Hello world!!!");
</script>
<?php
  }
?>

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
mbyte  
View profile   Translate to Translated (View Original)
 More options Jul 15 2008, 7:31 am
Newsgroups: it.comp.lang.javascript
From: mbyte <michela.police...@gmail.com>
Date: Tue, 15 Jul 2008 04:31:52 -0700 (PDT)
Local: Tues, Jul 15 2008 7:31 am
Subject: Re: Sintassi codice JS in codice PHP
On 15 Lug, 13:10, "Darkbyte [Google]" <seprano.anto...@gmail.com>
wrote:

> > Sono ignorante doc in materia... Ho copiato il codice che mi hai
> > indicato e l'ho inserito in un index.php. Quando accedo alla pagina
> > non succede nulla...
> > Non dovrei vedere la scritta "Pippo!" da qualche parte ?

> <?php
>   if (true)
>   {
> ?>
> <script type="text/javascript">
>   alert("Hello world!!!");
> </script>
> <?php
>   }
> ?>

Così va, grazie

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google