Forums

This topic is locked

textarea problem

Posted 04 Dec 2007 09:30:36
1
has voted
04 Dec 2007 09:30:36 Mieke Janssens posted:
When I add (PHP- or javascript)code to a textarea in 'code view', and I switch back to 'design view', I can't see my original layout anymore.

I've made a screenshot to show what I mean:
www.theonlinesellinggame.com/dreamweaver2.jpg

When I upload the page, everything looks fine.

Can somebody tell me what's causing this?

Greetz!
Mieke

Replies

Replied 06 Dec 2007 11:34:43
06 Dec 2007 11:34:43 Alan C replied:
I think it depends on how you put the php in - what I found was that it was best to have very short parts of php, for example when there is a conditional part, do not enclose the whole of the html between the if and end of if statement. If you do then dw will not show all the html.

I think that may be what is happening

an example might be

<pre id=code><font face=courier size=2 id=code> &lt;?php if ($a&gt;3) { ?&gt;

now all the html for whatever you want here

&lt;?php }?&gt;</font id=code></pre id=code>

Reply to this topic