Issue between gibber and form
opened this issue · comments
Hi! No matter if I use or not the gibber library, as soon as I load it: (and nothing else, no command, nothing at all)
script type="text/javascript" src="js/p5.gibber.min.js"></script>
My form stops working properly: (mails don't get out and the error/success message dont' appear)
div id="error">
form class="estilo">
p>
p>Error! Trate refrescando la pagina y submitiendo nuevamente.
/form>
/div>
div id="success">
form class="estilo">
p>
p>El mensaje se envio exitosamente! Te respondere pronto.
/form>
/div>
form id="contact" class="estilo" name="contact" method="post" novalidate="novalidate">
fieldset>
label for="name" id="name"> *
/label>
input type="text" name="name" id="name" size="30" value="" placeholder="Nombre" required="">
label for="email" id="email"> */span>
/label>
input type="text" name="email" id="email" size="30" value="" placeholder="Email" required="">
label for="Message" id="message"> */span>
/label>
textarea name="message" id="message" placeholder="Mensaje" required=""></textarea>
input id="submit" type="submit" name="submit" value="">
/fieldset>
/form>
?php
$to = "info@christianlech.com.ar";
$from = $_REQUEST['email'];
$name = $_REQUEST['name'];
$headers = "From: $from";
$subject = "CONSULTA!!!";
$fields = array();
$fields{"name"} = "Nombre";
$fields{"email"} = "Mail";
$fields{"message"} = "Mensaje";
$body = "Here is what was sent:\n\n"; foreach($fields as $a => $b){ $body .= sprintf("%20s: %s\n",$b,$_REQUEST[$a]); }
$send = mail($to, $subject, $body, $headers);
I'm using gibber to sonorize my web and works fine (4 lines of code), but i would like to have both the gibber and the contact form working properly.
Couldn't trace where the issue is.
Any help would be awesome.
Thanks!
I'm not sure I can help with this... it's been quite some time since I've used PHP in any significant way. I guess my first question would be: does the post request reach the server?
Yes, it does. Web, form, php is up and running, no issues at all. I need form to be working since it is a point of contact with people.
Then as i've commented if I just load the gibber, mails don't quit at all. I had to choose for the form instead the sound. :(
This is what i do and works fine (is commented right now)
in setup
fm = FM({ maxVoices:16, attack:ms(1) })
fm.fx.add( Reverb() )
fm.fx.add( Delay() )
in draw
fm.note( i*j )
2-3 months since i realized this and tried to trace the issue while polishing my web, didn't want to bother you but it seems to me some kind of crazy bug. I can have the sound or the form but not both of them. Thanks,