|
|
|
|
![]() ![]() |
Nov 9 2005, 09:29 PM
Post
#1
|
|
|
Super Member ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 407 Joined: 13-December 04 Member No.: 2,696 |
I want to be bale to poistion certin parts of my code in specfic places. I need to be able to disaply this quickly. As a temp measure I have started and stopped php tags. Now normally this will disaply a php block on my dreamweaver. However it is not. Is there a reason why??
My code is; PHP Code: CODE <?php $db = @mysql_connect ("localhost","root","andy"); print "Database Connection gained"; echo '<br>'; mysql_select_db("disertation",$db); $query = "SELECT questions.Question, questions.Option FROM questions"; $result = @mysql_query($query,$db); while($row = @mysql_fetch_assoc($result)) { ?> <?php echo $row['Question'] . '<br>'; ?> <?php switch($row['Option']) { case 'R': ?> <?php echo "<input name='" . $row['Question'] . "' type='radio' value='radiobutton'>"; echo '<br>'; ?> <?php break; case 'T': ?> <?php echo "<input type='text' name='" . $row['Question'] . "'>"; echo '<br>'; break; } } ?> Thanks,kvarnerexpress |
|
|
|
Nov 9 2005, 11:32 PM
Post
#2
|
|
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 1,161 Joined: 9-May 05 From: Brisbane, QLD Member No.: 6,818 |
I'm sorry, what's the actual question?
|
|
|
|
Nov 10 2005, 01:03 AM
Post
#3
|
|
|
Advanced Member ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 123 Joined: 5-September 05 Member No.: 11,522 |
From what I think you are trying to do, you need to have the code inside of the body tag. Then dreamweaver should display the blocks. But the other possibility is that you need to just put the code bits directly into the HTML using the "code" view in dreamweaver. I don't see why you can't do that in the first place...anyway, if you could elaborate on your question--as Tyssen suggested--that would be very helpful.
Good luck! |
|
|
|
Nov 10 2005, 07:02 AM
Post
#4
|
|
|
Premium Member ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Group: Members Posts: 165 Joined: 1-November 05 From: SATA II Member No.: 13,683 |
I'am not sure the question you are asked
- hope this help |
|
|
|
![]() ![]() |
Similar Topics
| Topics | Topics | |
|---|---|---|
|
|
|
|
Lo-Fi Version | Time is now: 13th October 2008 - 05:38 PM |