Re: custom forms - data collection
In reviewing the code, the problem of the HTML emails not being delivered properly ... is because the code was written for an older version of Zen Cart, which didn't support HTML emails at the time.
The HTML portion of the emails needs to be added to the module.
1 Attachment(s)
Re: custom forms - data collection
Here's a packaged version of the module, designed for v1.3.7 ... tested on v1.3.7.
Please consider a donation to the Zen Cart team if you find it useful, as there are numerous hours invested in upgrading and writing and testing this form.
Re: custom forms - data collection
There's an error in the packaged module, in the file "tpl_band_signup_default.php".
The first "<div" tag doesn't appear to be closed.
<div class="centerColumn" id="bandSignupDefault">
<h1 id="bandSignupDefaultHeading"><?php echo HEADING_TITLE; ?></h1>
<?php if ($messageStack->size('band_signup') > 0) echo $messageStack->output('band_signup'); ?>
Re: custom forms - data collection
Right -- the initial div is closed at the end of the file after everything else in it is displayed.
Re: custom forms - data collection
Quote:
Originally Posted by
DrByte
Right -- the initial div is closed at the end of the file after everything else in it is displayed.
Could be. I picked up a little HTML over 10 years ago, and that's about it. I don't even know what a div tag is! :blink:
But I had problems getting it to work, so I downloaded some PHP editors, and both reported an unclosed div tag. So I closed it and now it works.
Re: custom forms - data collection
You were right.
I finally went through my template file line by line, fixed a bunch of errors, and now have it working without adding the extra "</div>" tag.
The PHP editor I have still reports an unclosed div, but it works anyway.
And I even fixed some display problems in firefox. :smile:
Re: custom forms - data collection
I have modified the form for my customers to make a request for special orders and have run into a snag.
Upon trying to add more fields the page will not display correctly.
Like so.... http://www.freshabundance.com/index....pecial%20order
When I remove the additional fields it returns to the correct display.
Here is the code, what am I missing?
Code:
<div id="specialorderContent" class="content">
<fieldset id="specialorder-Info">
<legend>Special Order Information</legend>
<div class="alert forward"><?php echo FORM_REQUIRED_INFORMATION; ?></div>
<br class="clearBoth" />
<label class="inputLabel" for="band_name">Name of the Item:</label>
<?php echo zen_draw_input_field('band_name', zen_output_string_protected($band_name), ' size="30" id="band_name"') . '<span class="alert">' . ENTRY_REQUIRED_SYMBOL . '</span>'; ?>
<label class="inputLabel" for="band_genre">Who makes it?:</label>
<?php echo zen_draw_input_field('band_genre', zen_output_string_protected($band_genre), ' size="30" id="band_genre"') . '<span class="alert">' . ENTRY_REQUIRED_SYMBOL . '</span>'; ?>
<label class="inputLabel" for="band_country">12 Digit UPC Code:</label>
<?php echo zen_draw_input_field('band_country', zen_output_string_protected($band_country), ' size="30" id="band_country"') ; ?> What is a <a href="<?php echo zen_href_link(FILENAME_PAGE_4); ?>" target="_blank">UPC Code?</a>
<label class="inputLabel" for="band_city">Description:</label>
<?php echo zen_draw_textarea_field('band_city',30, 4, zen_output_string_protected($band_city), 'id="band_city"') ; ?>
<!--additional items -->
<label class="inputLabel" for="item2_name">Name of the Item:</label>
<?php echo zen_draw_input_field('item2_name', zen_output_string_protected($item2_name), ' size="30" id="item2_name"') ; ?>
<label class="inputLabel" for="item2_manufacturer">Who makes it?:</label>
<?php echo zen_draw_input_field('item2_manufacturer', zen_output_string_protected($item2_manufacturer), ' size="30" id="item2_manufacturer"') ; ?>
<label class="inputLabel" for="item2_upc">12 Digit UPC Code:</label>
<?php echo zen_draw_input_field('item2_upc', zen_output_string_protected($item2_upc), ' size="30" id="item2_upc"') ; ?> What is a <a href="<?php echo zen_href_link(FILENAME_PAGE_4); ?>" target="_blank">UPC Code?</a>
<label class="inputLabel" for="item2_description">Description:</label>
<?php echo zen_draw_textarea_field('item2_description',30, 4, zen_output_string_protected($item2_description), 'id="item2_description"') ; ?>
</fieldset>
When I get it all done and working, I'll repost it as a zipped file in case anyone wants to clean it up for and use it for their special orders.
Jacque
Re: custom forms - data collection
I've made some changes and put the 2nd item in it's own fieldset, it makes it cleaner, though the formating still eludes me...
http://www.freshabundance.com/index....pecial%20order
Re: custom forms - data collection
I've figured out the cause, it appears to be related to
Code:
'<span class="alert">' . ENTRY_REQUIRED_SYMBOL . '</span>'
Which puts that little red "required information" star there.
So, how do I remove or hide that little star where it is not needed?
Re: custom forms - data collection