Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > PHP How-To
|
PHP How-To Post your "How do I do this with PHP?" questions here.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the PHP How-To section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 20th, 2006, 12:37 AM
Friend of Wrox
 
Join Date: Oct 2003
Posts: 479
Thanks: 0
Thanked 3 Times in 3 Posts
Send a message via MSN to surendran Send a message via Yahoo to surendran
Default Try this, answer me

Hi friends,
i have a string with following format
<?php
$x='<table>
<tr>
<td>
Hello
</td>
</tr>
</table>'
?>

but i need the out put as follows, please help me...
<?php
$x='<table><tr><td>Hello</td></tr></table>'
?>

don't say trim function, i try all, please try and post

surendran
(Anything is Possible)
http://ssuren.spaces.msn.com
__________________
surendran
(Anything is Possible)
http://www.suren.info
http://ssuren.spaces.msn.com
 
Old November 14th, 2006, 07:09 AM
Authorized User
 
Join Date: Sep 2006
Posts: 53
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to aneesh_sunu@yahoo.co.in Send a message via Yahoo to aneesh_sunu@yahoo.co.in
Default

Hai
Try this code
<?php
$x='<table border=1><tr><td>Hello</td></tr></table>';
print $x;

$x1='<table border=1>'.'<tr>'.'<td>'.'Hello'.'</td>'.'</tr>'.'</table>';
print $x1;

$x2="&lt;"."table border=1". "&gt;" ."&lt;".tr."&gt;" ."&lt;".td."&gt;" .Hello ."&lt;" ."&frasl;".td."&gt;"."&lt;" ."&frasl;".tr."&gt;"."&lt;" ."&frasl;".table."&gt;";
print $x2;
?>





Similar Threads
Thread Thread Starter Forum Replies Last Post
Please answer canasdaq XML 3 April 19th, 2006 09:04 AM
i want answer titto_oo7 C# 7 February 9th, 2006 03:59 PM
answer IvAnR C++ Programming 1 July 22nd, 2005 08:01 AM
About the answer!!! soso ASP.NET 1.0 and 1.1 Basics 0 July 9th, 2003 11:05 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.