Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    how to have 2 two tep_draw_form around the same code

    I searched the archives for this

    http://www.google.com/search?q=site%...ont=php+2+form

    but unfortunately, none of those is helping accomplish what I am trying to or I am not understanding which is a definite possibility.

    I am trying to find a way to work 2 <?php echo tep_draw_form(...); ?> around the same bit of code... on my php order page...

    is there anyway that this can work?
    Last edited by mariemeh; 03-15-2007 at 03:26 AM.

  • #2
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    I read your question 4 times and still don't know what you are talking about.

    Try asking your question again and pretend like we don't know anything about what you are trying to do.

  • #3
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    sorry I will try to do better...


    I own a website that uses a OSC shopping cart. I've been working on it to make it more efficient. So far so good... even with my verrrrrrry limited knowledge, I've been able to build something I can actually work with... only a week and a half ago I hit a snag... I have two options that need to work around the same code... here is the part of the code that is my concern on my order.php page


    <tr>
    <td><table border="0" width="100%" cellspacing="0" cellpadding="0">
    <tr>
    <td valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="2">
    <?php echo tep_draw_form('batch_orders', 'print_batch_process.php', '', 'post', 'target="_blank"'). "\n"; ?> <tr class="dataTableHeadingRow">
    <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_PRINT; ?><input name="allbox" type="checkbox" value="Check All" onclick="CheckAll(document.batch_orders);" /></td>
    <td class="dataTableHeadingContent" align="center"><?php echo TABLE_HEADING_CUSTOMERS; ?></td>
    <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_ORDER_TOTAL; ?></td>
    <td class="dataTableHeadingContent" align="center"><?php echo TABLE_HEADING_DATE_PURCHASED; ?></td>
    <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_STATUS; ?></td>
    <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_UPDATE; ?></td>
    <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_ACTION; ?>&nbsp;</td>
    </tr>

    ( I am cutting out part of the code to make this brief cause )

    <tr>
    <td colspan="7"><table border="0" width="100%" cellspacing="0" cellpadding="2">
    <?php echo '<tr><td colspan="7">' . tep_black_line() . '</td></tr>';?>

    <tr>
    <td class="smallText">Batch Print - Invoice:<?php echo tep_draw_radio_field('target_file', FILENAME_ORDERS_INVOICE, true); ?> Packing Slip:<?php echo tep_draw_radio_field('target_file', FILENAME_ORDERS_PACKINGSLIP, false); ?> Invoice &amp; Packing Slip:<?php echo tep_draw_radio_field('target_file', 'both', false); ?> Labels:<?php echo tep_draw_radio_field('target_file', 'labels'); ?></td>
    </tr>
    <tr>
    <td class="smallText" align="right">
    <?php echo tep_image_submit('button_confirm.gif', IMAGE_CONFIRM, 'align="absmiddle"'). "\n"; ?> </td>
    </tr>
    </table></td>
    </tr>
    <?php echo '</form>'. "\n"; ?>

    Note the 2 lines that are in blue... this is my first tep_draw_form.... the second one would normally go exactly in the same spot... for the second option to work...
    <?php echo tep_draw_form('UpdateStatus', FILENAME_ORDERS,tep_get_all_get_params()); ?>
    and of course it's closing code would be at about the same spot as the other one...

    As soon as i try to put both form in the same spot... there is a conflict and one works and the other doesn't. Like I said my knowledge in this is limited but I really really do need for this to work so I am trying to find out if it's at all possible to have another <?php echo tep_draw_form...?> showing in the code before the closing the for the first one shows...

    I don't knwo if I could illustrate it better like this... I know what I am going to write isn't related at all to this but I thought maybe it would give an image

    in HTML... you can't insert a <table> tag inside another <table> tag... but if I do this

    <table>
    <tr>
    <td><table></table></td>
    </tr>
    </table>

    then I can have a table inside another...

    I am trying to figure out if I can have one form code work inside another form code??

    am I making any more sense?? sorry for being so illetarate at this.

  • #4
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    I understand much better. The function tep_draw_form() is not a PHP function, but a user-defined function within you code, so that's why I didn't know what you were talking about. And no I can't help you specifically with that function since I don't have any idea what it is or what it does.

    Your desire to do <form name="form1"><form name="form2"></form></form> is not valid HTML markup and most every browser will be confused by it (and it won't do what you want it to).

    There is always another way to do things though...

  • #5
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    thanks for your reply, I appreciate it


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •