Jump to content

how do ia insert the </br> tag on PHP?

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
2 replies to this topic

#1
lil-fino

lil-fino

    Newbie

  • Members
  • PipPip
  • 15 posts
sorry for my stupid question but i am really new at this.

I have this php script and i want to use the </br> tag so its not a single line when showing the XML text.
Where do i put it?

<?php


$file = "pet.xml";

$xml = simplexml_load_file($file) or die ("Unable to load XML file!");


echo "Name: " . $xml->name . "\n";

echo "Age: " . $xml->age . "\n";

echo "Species: " . $xml->species . "\n";

echo "Parents: " . $xml->parents->mother . " and " .  $xml->parents->father . "\n";


?> 


#2
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
\n should be replaced with <br /> in each case.
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

#3
lil-fino

lil-fino

    Newbie

  • Members
  • PipPip
  • 15 posts
thanks man!
it works perfect :D