Rommeo Posted August 1, 2008 Share Posted August 1, 2008 hi After uploading the picture, for to use it in any page i wanna print the codes. But curious how can i print the codes.I m sure its very easy but I have never done that before. When i try to print it , i see with at the source code can not copy from html page lets say the code i wanna use is <img src="$name.jpg" align="left"> i wanna see it like <img src="pic.jpg" align="left"> Then i wanna copy that from the html.file and use it by echo or print function if it's possible ? Thanks in Advance. Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/ Share on other sites More sharing options...
DeanWhitehouse Posted August 1, 2008 Share Posted August 1, 2008 <img src="<?php echo $name;?>.jpg" align="left"> Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/#findComment-605719 Share on other sites More sharing options...
Rommeo Posted August 1, 2008 Author Share Posted August 1, 2008 Oh yeap. i was trying to use by echo, cause I ll add more variables like size etc. Is possible with that ? with escape chars lets say ? Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/#findComment-605722 Share on other sites More sharing options...
DeanWhitehouse Posted August 1, 2008 Share Posted August 1, 2008 should all you do is . for width <img src="" width="<?php echo $width; ?>"> Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/#findComment-605723 Share on other sites More sharing options...
Rommeo Posted August 1, 2008 Author Share Posted August 1, 2008 should all you do is . for width <img src="" width="<?php echo $width; ?>"> Blade thank you so much and i got you. But my question is ; is it possible with echo ? i also heard that 's possible with print function. Cause I ll print more codes. So I wanna learn how people are doing it. Again thanks for your replies.I ll be glad if you can tell me by using echo or print function. Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/#findComment-605729 Share on other sites More sharing options...
DeanWhitehouse Posted August 1, 2008 Share Posted August 1, 2008 is it possible with echo ? i also heard that 's possible with print function Is what ? Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/#findComment-605732 Share on other sites More sharing options...
Rommeo Posted August 1, 2008 Author Share Posted August 1, 2008 ok .. lets say my code is = <img src="$name.jpg" align="left"> so is this possible $code = "<img src=\"$name.jpg\" align=\"left\">"; edit($code); echo $code; can i see the code after this ? Actually the code here will be longer. Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/#findComment-605736 Share on other sites More sharing options...
DeanWhitehouse Posted August 1, 2008 Share Posted August 1, 2008 yes it should , but without seing the function i can't be sure Quote Link to comment https://forums.phpfreaks.com/topic/117770-how-to-print-the-html-code/#findComment-605752 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.