Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2007
    Location
    London
    Posts
    1,577
    Tokens
    36

    Latest Awards:

    Default PHP BASICS HELP +REP

    Hello,

    I'm sure there is a really easy answer to this. How do I put a variable in a variable? I think it involves a '.' or two.

    For example I want to do something like this:

    Code:
    $variable1 = 'blahblah$variable2blabla';
    But I want $variable2 to be showing as what it is in that place.

    Thanks to any help in advance. Will +rep.
    Kind Regards,

    Guy
    __________________

    Since 2007. Unbelievable Uptime. Web hosting, resellers, master resellers, linux VPS, windows VPS, shoutcasts, at the lowest prices on the net.
    Tech-Hosts.co.uk.


  2. #2
    Join Date
    Dec 2006
    Location
    Swindon
    Posts
    3,299
    Tokens
    215
    Habbo
    dunko

    Latest Awards:

    Default

    Code:
    $variable1 = 'blahblah' . $variable2 . 'blabla';

  3. #3
    Join Date
    Nov 2007
    Location
    London
    Posts
    1,577
    Tokens
    36

    Latest Awards:

    Default

    Quote Originally Posted by Blob View Post
    Code:
    $variable1 = 'blahblah' . $variable2 . 'blabla';
    Thank you very much. Sorted now, thread closed.
    Kind Regards,

    Guy
    __________________

    Since 2007. Unbelievable Uptime. Web hosting, resellers, master resellers, linux VPS, windows VPS, shoutcasts, at the lowest prices on the net.
    Tech-Hosts.co.uk.


Posting Permissions

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