Jump to content

[SOLVED] return a value


corillo181

Recommended Posts

i got a functions and it echos out a result, the problme is if i make the functions into a string it still echos out the result at the spot where the string is at..

 

illustration

<?php

function name(){
echo 'jay';
}

?>

 

now my problem is when i try to use it.

 

<?php
$names=name();

echo $names;

?>

 

the result will be

 

jay

 

jay

Link to comment
https://forums.phpfreaks.com/topic/56935-solved-return-a-value/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.