Results 1 to 2 of 2

Thread: Adding "" around variable

  1. #1

    Thread Starter
    PowerPoster lintz's Avatar
    Join Date
    Mar 2003
    Location
    The 19th Hole
    Posts
    2,697

    Resolved Adding "" around variable

    There is most likely a simple solution but how do I add " " around a variable?

    This is code i'm using but I get an unexpected T_VARIABLE error.

    Thanks.

    PHP Code:
    function  registrations() { 
    include(
    "db_connect.php"); 

    $query mysql_query("SELECT * FROM mytable"); 
    $results mysql_fetch_row($query); 

    while(
    $Details mysql_fetch_row($results)) { 

    echo 
    " "$Details[0]" <br>"




    Last edited by lintz; Oct 18th, 2004 at 09:34 PM.

  2. #2
    Stuck in the 80s The Hobo's Avatar
    Join Date
    Jul 2001
    Location
    Michigan
    Posts
    7,256
    Code:
    echo " \"$Details[0]\" <br>";
    My evil laugh has a squeak in it.

    kristopherwilson.com

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