SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Evangelist
    Join Date
    Feb 2000
    Location
    England
    Posts
    568
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry for so many questions today.. but... well...

    i have $$something

    if i do

    echo $$something;

    i get what i want but if i di

    echo "blah blah $$something blah blah";

    i don't. I get $something displayed.. no use.

    Do i have to do

    echo "blah blah" . $$something . "blah blah"; or is there another way?

  2. #2
    SitePoint Wizard
    Join Date
    Mar 2001
    Posts
    3,537
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi,

    This will work:

    echo "blah blah {$$something} blah blah";

    but I think concatenating is clearer.

  3. #3
    SitePoint Evangelist
    Join Date
    Feb 2000
    Location
    England
    Posts
    568
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ar.. thank you for that. I agree it might be clearer in the case but i need to make SQL statements from the variable as well and { } will make that a lot easier.

    thanks


Bookmarks

Posting Permissions

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