Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> General/Other Stuff
Author Message
m-weisel2
Regular
Regular



Joined: May 22, 2005
Posts: 78

PostPosted: Mon Jun 20, 2005 1:52 am Reply with quote

I am working on a file that uses echo to show a variable then text right after it how do I do this

Code:
<?php

$variable1 = "1";
echo "$variable1 2";
?>


this shows "1 2" on a page

Code:
<?php

$variable1 = "1";
echo "$variable12";
?>


this shows nothing because php sees it as one variable how do I get it to end up being "12" insteasd of "1 2" or an error of the variable not existing.


Max
 
View user's profile Send private message
Holbrookau
Hangin' Around



Joined: Jun 25, 2004
Posts: 32

PostPosted: Mon Jun 20, 2005 3:46 am Reply with quote

Code:
echo $variable1."2";

or
Code:
echo "".$variable1."2";
 
View user's profile Send private message
m-weisel2







PostPosted: Mon Jun 20, 2005 3:52 am Reply with quote

thank you very much
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> General/Other Stuff

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©