WatsonN Posted October 17, 2010 Share Posted October 17, 2010 I have a piece of code: Print "<li><a href=\"biz?UID=".$info['ID'].'">'.$info['BSN']. "</a></li>"; What I want it to do is use POST instead of get but i'm mot sure how to achieve this. Is this even possible? This page: <?php $data = mysql_query("SELECT * FROM YBK_Ads WHERE `delete` = '0' ORDER BY CNL") or die(mysql_error()); while($info = mysql_fetch_array( $data )) { Print "<li><a href=\"biz?UID=".$info['ID'].'">'.$info['BSN']. "</a></li>"; Print '<li>'." -".$info['CNL'] . ", <em> " . $info['CNF'] . "</em></li>"; } ?> Page sent to: <div id="biz"> <div class="toolbar"> <h1>Contact Information</h1> <a href="#" class="back">Back</a> </div> <ul class="edgetoedge"> <?php $data = mysql_query("SELECT * FROM `YBK_Ads` WHERE `UID` = '{$_GET['UID']}' and `delete` = '0'") or die(mysql_error()); while($info = mysql_fetch_array( $data )) { Print $info['BSN']; Print "Payment Status: <b>".$info['payment'] . "</b>"; ?> <p><li> -Contact Name: <?php Print "<b>" . $info['CNF'] ." " . $info['CNL'] . "</b></a></li>";?> <?php Print "<li> -Address: <b>".$info['ADD'] . "</b></a></li>"; Print "<li> -City: <b>".$info['CITY'] . "</b></a></li>"; Print "<li> -State:<b> ".$info['STATE'] . "</b></a></li>"; Print "<li> -Zip:<b> ".$info['ZIP'] . "<br></b>"; Print "<li> -Declined Ad:<b> ".$info['DCL'] . "<br></b>"; Print "<li> -Call Back Next Year:<b> ".$info['CB'] . "<br></b>"; Print "<li> -Type of Ad:<b> ".$info['ToA'] . "</b></a></li>"; Print "<li> -Ad Size:<b> ".$info['AS'] . "<br></b>"; Print "<li> -Payment Type:<b> ".$info['PT'] . "</b></a></li>"; Print "<li> -Check Number:<b> ".$info['CN'] . "</b></a></li>"; Print "<li> -Buying a yearbook:<b> ".$info['BY'] . "</b></a></li>"; Print "<li> -Ad Copy • Artwork/Photo Instructions:<b> ".stripslashes($info['ACI']) . "</b></a></li>"; Print "<li> -Talked to Ad Manager:<b> ".$info['TAM'] . "</b></a></li>"; Print "<li> -Left A Voicemail: <b>".$info['VM'] . "</b></a></li>"; } ?> </ul> </div> Quote Link to comment https://forums.phpfreaks.com/topic/216051-getpost/ Share on other sites More sharing options...
trq Posted October 17, 2010 Share Posted October 17, 2010 To use the post method you would nee to use a form instead of a link. Quote Link to comment https://forums.phpfreaks.com/topic/216051-getpost/#findComment-1122901 Share on other sites More sharing options...
WatsonN Posted October 17, 2010 Author Share Posted October 17, 2010 Well yeah, but is there a way you can make a form look like a link? Quote Link to comment https://forums.phpfreaks.com/topic/216051-getpost/#findComment-1122934 Share on other sites More sharing options...
kenrbnsn Posted October 17, 2010 Share Posted October 17, 2010 The only way you can make a link use POST is to use AJAX techniques. Ken Quote Link to comment https://forums.phpfreaks.com/topic/216051-getpost/#findComment-1122936 Share on other sites More sharing options...
WatsonN Posted October 17, 2010 Author Share Posted October 17, 2010 Thank yall much, figured it out. . . So far Quote Link to comment https://forums.phpfreaks.com/topic/216051-getpost/#findComment-1123086 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.