Jump to content
luckian121

echo php

Recommended Posts

Posted (edited)

Salut am si eu o mica problema orice am incercat numi iese in loc sami iasa Dempsey de ex imi da $nn11 aveti vreo idee de ce?

<?php

$nn11 = "Dempsey";
$nn12 = "Vargas";
$nn13 = "Kelley";
$nn14 = "Stroming";
$nn15 = "Johnson";
$nn16 = "Connell";
$nn17 = "Newlander";
//am mai taiat din cod
$nn146 = "Walter";

$xx = rand(110, 146);
$xxx = rand(10, 46);
$n4 = '$nn'.$xx;
$n3 = '$nn'.$xxx;
echo $n3;
?>

Sper ca am postat unde trebui..

Edited by luckian121
Posted

Scz am rezolvat

<?php

$input = array("Neo", "Morpheus", "Trinity", "Cypher", "Tank");

$rand_keys = array_rand($input, 2);

echo $input[$rand_keys[0]] . "\n";

echo $input[$rand_keys[1]] . "\n";

?>

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...