Jump to content

Archived

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

tego10122

php html code echo erorr

Recommended Posts

Hello ,

I have a image upload site www.vobgaming.com if you go there and upload a file it will give you a myspace code it comes out like so. <a href='http://littlepic.zapto.org'><img src='http://vobgaming.com/images_dir/picname.jpg'></a> what i need to do is have the php echo ' as ". The code is below.


<tr><td><b><img src="images_0/1794icon_friends.gif">&nbsp;MySpace Code:</b><td><input type="text" name="thetext" size="70" value = "<a href='<? echo $hosturl; ?>'><img src='<?echo $urlf; ?>'></a>"</td></tr>

that echos <a href='http://littlepic.zapto.org'><img src='http://vobgaming.com/images_dir/picname.jpg'></a>

I need to replace ' with " with out getting an erorr.

Thanks in advanced!

Share this post


Link to post
Share on other sites
This is what I have for the exact same application.
you want to use  HTML chars, like 
&gt; = > 
&quot; =  "

[code]     <table border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td>HTML Code: </td>
        <td><input name="textfield" type="text" size="30" value="&lt;img src=&quot;http://www.mysite.com/photos/<? echo $row['imageLocation'] ?>&quot;&gt;" onClick="this.focus(); this.select()" title="display image on sites like myspace or ebay"></td>
          </tr>
      <tr>
        <td>Forum Code: </td>
        <td><input name="textfield2" type="text" size="30" value="[IMG]http://www.mysite.com/photos/<? echo $row['imageLocation'] ?>[/IMG]" onClick="this.focus(); this.select()" title="display image in a forum using BBcode"></td>
            </tr>
      <tr>
        <td>HTML Link: </td>
        <td><input name="textfield3" type="text" size="30" value="&lt;a href=&quot;http://www.mysite.com/photos/<? echo $row['imageLocation'] ?>&quot;&gt;Click Here To View Image&lt;/a&gt;" onClick="this.focus(); this.select()" title="create an HTML hyperlink to the image for sites like myspace or ebay"></td>
            </tr>
          </table>[/code]

this lets you click on the text field to auto highlight the code snippet too. kind of like photobucket

Share this post


Link to post
Share on other sites

×

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.