Jump to content

PHP AND html in variable


drophit

Recommended Posts

I am trying to setup a variable and store some code to display but am haveing some probs see code below

<CODE>
$insert_results = ('<form action="CDDuplicationStepFive.php" method="post" name="form1">
<p class="MainContentBlue">We offer multiple Insert Printing options </p>
<p class="MainContent">
<select name="printing" class="MainContentSmallBolder" id="printing">
'
do {
'
<option value="<?php echo $row_all_cds[\'print_id\']?>">' echo $row_all_cds['print_name']' - add ' echo $row_all_cds['print_retail']'</option>
'
} while ($row_all_cds = mysql_fetch_assoc($all_cds));
$rows = mysql_num_rows($all_cds);
if($rows > 0) {
mysql_data_seek($all_cds, 0);
$row_all_cds = mysql_fetch_assoc($all_cds);
}
'
</select>
<a href="#" class="MainContentVerySmall" onClick="MM_openBrWindow(\'../AutoHelp.php?sub=InsertPrinting\',\'HELP\',\'scrollbars=yes,width=375,height=400\')">HELP!</a></p>
<p>
<input name="Submit" type="submit" class="MainContentVerySmall" value="CONTINUE">
</p>
</form> ');

}
else
{

$quote['printing_name'] = "None";
$quote['printing_retail'] = ".00";
header("Location: CDDuplicationStepFive.php");

}
</CODE>

Getting:

Parse error: parse error, unexpected T_DO in /wizard/CDDuplicationStepFourA.php on line 36

PLEASE help me!!
Link to comment
Share on other sites

You're not terminating your statements with a semi-colon. I see lone single quotes in your code. You're attempting to store something in a variable and never using it anywhere. How are you expecting to show what you stored? You don't need parenthesis around strings.

Ken
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

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.