Hello everyone. I am trying to modify a script I have been working with but have no true knowledge of PHP. Currently the script creates an http post and upon successful sending it opens a new web page and posts a message that reads "Sending results: OK". I would like to have this message show up in a form field in the original page as opposed to opening a new page. Can someone please help me to do this? I would be very appreciative of any assistance I can get. A working version of this can be tried at http://www.coffeebuzz.net/sms/gm/

Attachments

change $_post to $_request ....

$results = $mysms->send($_POST,$_POST,$message);

and add if ... else

if true ( header('location send.php?Action=OK');

<?php

if ( $_request == 'OK' )
{
print "msg sent";
}
else
{
print "bla bla";
}

change $_post to $_request ....

$results = $mysms->send($_POST,$_POST,$message);

and add if ... else

if true ( header('location send.php?Action=OK');

<?php

if ( $_request == 'OK' )
{
print "msg sent";
}
else
{
print "bla bla";
}

How do I specify the form field to print the results to?
BTW, fantastic signature in your post.

u ve form field as "Customer's Mobile Number" named as "to"
when you post this to send.php
add there
$_request instead post as you did in ur example.

if you give more details i can help u better.

PS: thanks for that. I love my signature :)

I know this makes sense to you but I am quickly lost in the PHP world. If you could edit the code to return the results to a new field in the HTML or back to the existing "to" field I would happily donate to your favorite charity. Even if that charity is you.

This article has been dead for over six months. Start a new discussion instead.