CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums
Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2005

    Problem with embedding JS code in PHP

    Hi all,

    I have the following string as part of my PHP code (before you ask, it HAS to be in PHP, can't write PHP and HTML separately):

         $submission_form ="
            <p style=\"font-size:20px; padding: 15px;\">
                <u>Please select the type of analysis you wish to perform</u>
            <form name=\"analysis_form\" method=\"post\">  
                <a id=\"myHeader1-2\" href=\"javascript:showonlyonev2(\"newboxes1-2\");\" >
                    <input type=radio name=\"criterion\" value=\"single_genotype\">
                    Single-study analysis using genotypes
    Everything works fine, except the JS part...Because it should have single quotes, but this I can't do it inside the PHP string...
    Any ideas?

  2. #2
    PeejAvery's Avatar
    PeejAvery is offline Super Moderator Power Poster
    Join Date
    May 2002

    Re: Problem with embedding JS code in PHP

    Why do you say you can't do single quotes inside a PHP string?
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Click Here to Expand Forum to Full Width