Tengo un formulario.
Lo pueden ver aqui http://autoresponder.hostei.com/contacto/index.php
EL problema que tengo es, donde colocar la evariable subcategoria, ya que al darle en vista previa no me aparece.. Reyenen el formulario pa que vean..
LEs dejo el codigo para ver quien me puede hechar la mano.
Estoy casi seguro que esta {select:subcategorias} va colocada en la parte que DONDE ESTA EL SCRIP,,, solo falta eso, colocarlo para poder envia el formulario,, solo que no se donde va exactamente,, todo lo demas esta perfecto.
Espero que me puedan ayudar
Código HTML:
<?xml version="1.0"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" dir="{txt_content_direction}"> <head> <title>{txt_script_name} {txt_script_version}</title> <meta http-equiv="Content-Type" content="text/html; charset={txt_charset}" /> </head> <style type="text/css"> <!-- body { font-family:Arial,Helvetica,Geneva,Sans-serif,sans-serif; } p, td, br, form, div, span, blockquote { font-family:Arial,Helvetica,Geneva,Sans-serif,sans-serif; font-size:9pt; } .index { font-weight:bold; } #poweredby { text-align:center; margin-top:30px; } --> AQUI EMPIEZA EL CODIGO JAVA SCRIP....SEGURO QUE AQUI VA.. BUENO CASI </style> <script type="text/javascript"> function populate(o) { d=document.getElementById('de'); if(!d){return;} var mitems=new Array(); mitems['United States']=['Burger Meals','Breakfast','Steaks','Fish Dishes','Vegetarian Dishes']; mitems['United Kingdom']=['Brownies','Cookies']; mitems['Germany']=['Shakes','Sodas','Cocktails','Juices']; mitems['France']=['Tuna Salad','Cesar Salad','Green Salad','Prawn Salad']; mitems['Spain']=['Pancakes','Waffles','Ice Cream','Fresh Fruit']; d.options.length=0; cur=mitems[o.options[o.selectedIndex].value]{select:subcategorias}; if(!cur){return;} d.options.length=cur.length; for(var i=0;i<cur.length;i++) { d.options[i].text=cur[i]; d.options[i].value=cur[i]; } } </script> AQUI TERMINA EL CODIGO JAVASCIP,, DE SEGURO QUE SI VA POR AQUI.. <body> <h4>{txt_script_name}</h4> <!-- Display error messages (required fields etc.) --> <LOOP NAME="message"> <blockquote style="color:#FF5F00;"> <p style="font-weight:bold;">{message}</p> <blockquote>{fields}</blockquote> </blockquote> </LOOP NAME="message"> <!-- Display posted information --> <LOOP NAME="display_data"> <table border="0" cellpadding="3" cellspacing="0"> <tr> <td class="index">{txt_firstname}</td> <td> </td> <td>{firstname}</td> </tr> <tr> <td class="index">{txt_lastname}</td> <td> </td> <td>{lastname}</td> </tr> <tr> <td class="index">{txt_email}</td> <td> </td> <td>{email}</td> </tr> <tr> <td class="index">Fruits</td> <td> </td> <td>{checkbox:fruits}</td> </tr> <tr> <td class="index">Categorias</td> <td> </td> <td>{select:categorias}</td> </tr> <tr> <td class="index">Subcategorias</td> <td> </td> <td>{select:subcategorias}</td> </tr> <tr> <td class="index">{txt_subject}</td> <td> </td> <td>{subject}</td> </tr> <tr valign="top"> <td class="index">{txt_comment}</td> <td> </td> <td>{comment}</td> </tr> <tr> <td> </td> <td> </td> <td> </td> </tr> </table> </LOOP NAME="display_data"> <!-- Display form --> <IF NAME="display_form"> <form action="{script_self}" method="post"> <input type="hidden" name="required_fields" value="lastname, email, subject" /> <input type="hidden" name="email_fields" value="email" /> <input type="hidden" name="html_template" value="form.tpl.html" /> <input type="hidden" name="mail_template" value="mail.tpl.txt" /> <!-- <input type="hidden" name="thanks" value="./docu/thanks.html" /> --> <table border="0" cellpadding="3" cellspacing="0"> <tr> <td>{txt_firstname}</td> <td> </td> <td><input type="Text" name="firstname" value="{firstname}" size="40" /></td> </tr> <tr valign="bottom"> <td>{txt_lastname} *</td> <td> </td> <td> <input type="Text" name="lastname" value="{lastname}" size="40" /> </td> </tr> <tr valign="bottom"> <td>{txt_email} *</td> <td> </td> <td> <input type="Text" name="email" value="{email}" size="40" /> </td> </tr> <tr> <td>Fruits</td> <td> </td> <td> Choose at least 1 Fruit<br /> <input name="fruits[]" type="checkbox" value="Apple" {checkbox:fruits=Apple} /> Apple <br /> <input name="fruits[]" type="checkbox" value="Pear" {checkbox:fruits=Pear} /> Pear <br /> <input name="fruits[]" type="checkbox" value="Orange" {checkbox:fruits=Orange} /> Orange <br /> <input name="fruits[]" type="checkbox" value="Cherry" {checkbox:fruits=Cherry} /> Cherry </td> </td> <tr> <label for="countriess">Categorias: </label> <select name="categorias" id="categorias" onchange="populate(this)"> <option value="United States" {select:categorias=United States}>United States</option> <option value="United Kingdom" {select:categorias=United Kingdom}>United Kingdom</option> <option value="Germany" {select:categorias=Germany}>Germany</option> <option value="France" {select:categorias=France}>France</option> <option value="Spain" {select:categorias=Spain}>Spain</option> </select> <label for="de">Subcategorias:</label> <select name="de" id="de"> </select> </td> </tr> <tr> <td valign="bottom">{txt_subject} *</td> <td> </td> <td> <input type="Text" name="subject" value="{subject}" size="40" /> </td> </tr> <tr valign="top"> <td>{txt_comment}</td> <td> </td> <td><textarea name="comment" cols="30" rows="10">{comment}</textarea></td> </tr> <tr valign="top"> <td> </td> <td> </td> <td> <input type="submit" name="mode_preview" value="{txt_preview}" /> <input type="submit" name="send" value="{txt_submit}" /> </td> </tr> </table> </form> <p>* = {txt_mandatory_fields}</p> </IF NAME="display_form"> </body> </html>