Jump to content

Monshery

Members
  • Posts

    44
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Monshery's Achievements

Member

Member (2/5)

0

Reputation

  1. i did looked but matey .. id didnt worked iether way . i tryed it again now that i am a bit more awake and still nothing
  2. Well basicaly i am trying to make a Admin side of my data base show thats means that php basicaly will print all the lines 1 by 1 in dec order and show them what i am trying to do and cant figure out whats not working is .. i added a check box in every fatch array .... and i am trying to make an array with this check box so i could delete several massages at once if i want here here is the exact code : [code]   <?php // well basicaly if i make this to work i will know how to delete enough that i will know that i can send me //the array but somewhy it wont send me.   foreach ($_POST["checkbox"] as $key=>$val)     echo "key:$key value:$val<BR>\n"; ?>   <table width="444" border="0">   <tr>     <td height="23"><div align="left"><span class="style3">my admin</span></div><div align="right"><span class="style5">הודעות מעודכנות להיום</span></div></td>   </tr>   <tr>     <td width="438" height="33" bgcolor="#006699">    <form action="Admin.php" method="POST">         <table width="437" border="0" style="border-width: 0px">         <tr>           <td bgcolor="#FFFFFF" class="style1" style="border-style: none; border-width: medium"> <!-- php database --> <?php $post_LINK=mysql_connect('xxxxxxxxx','xxxxxxxx','xxxxxxx') or die("Connection fail"); mysql_select_db('xxxxxxxxx',$post_LINK); $MASSAGES_links = mysql_query("SELECT * FROM xxxxxxx ORDER BY id DESC",$post_LINK); while($MASSEGES=mysql_fetch_array($MASSAGES_links)) { ?>             <div align="right"></div>             <div align="right">               <table width="432" height="77" border="0" bgcolor="#FFFFFF">                   <tr>                     <td width="167" height="23">                       <div align="left"> <input type="checkbox" name="checked[<?php print $MASSEGES['id']; ?>]" value="<?php print $MASSEGES['id'];?>">                        למחיקת הודעה סמן </div></td>                     <td width="167"><div align="right"><?php echo $MASSEGES['name'];?></div></td>                     <td width="30"><div align="right">:שם                      </div></td>                     <td width="52"><div align="right"><?php echo $MASSEGES['id'];?>                     </span></div></td>                   </tr>                   <tr>                     <td height="23" colspan="3"><div align="right"><?php echo $MASSEGES['email'];?></div>                       <div align="right"></div></td>                     <td height="23"><div align="right">: נושא</div></td>                   </tr>                   <tr>                     <td height="23" colspan="4"><p align="right">:הודעה</p>                     <p align="right"><?php echo $MASSEGES['massage'];?></p>                       <p align="right">----------------------------------------------------------------------------------- </p></td>                   </tr>               </table>               <?php } ?>             </div></td>         </tr>       </table> <input name="deletem" type="submit" id="deletem" value="מחק את ההודעות">   </form>       </td>   </tr> </table> [/code] Thanks in advance sorry for so long code didnt know how to sammorzing it .
  3. [quote author=kamasheto link=topic=112280.msg455610#msg455610 date=1161466694] just add DESC id at the end of your SQL query, should fix that for you [/quote] What mean DESC ID ?
  4. some kinda of post replay form . it has a continuance in my page :-) [code]         $INSERTD = mysql_query("INSERT INTO xxxxxx (id, name, email, massage, show_mail) VALUES                ('$f','$_POST[name]', '$_POST[email]', '$_POST[massage]', '$_POST[show_email]')",$post_LINK); $post_LINK=mysql_connect('xxxxx','xxxxxx','xxxxxx') or die("Connection fail"); mysql_select_db('xxxxxx',$post_LINK); $MASSAGES_links = mysql_query("SELECT * FROM xxxxxx",$post_LINK); /* basicaly here i start showing the table */ while($MASSEGES=mysql_fetch_array($MASSAGES_links)) { ?>             <table width="427" height="54" border="0">               <tr>                 <td width="26" height="23"><?php echo $MASSEGES['id'];?></td>                 <td width="117"><span class="style2"><strong>Name:</strong> <?php echo $MASSEGES['name'];?></span></td>                 <td width="250"><span class="style2">                   <?php if ($MASSEGES['show_mail'] == "show_email") { echo "<strong>Email: </strong> ". $MASSEGES['email']; }?>                 </span></td>               </tr>               <tr>                 <td height="23" colspan="3"><p><span class="style2"><strong>Massage: </strong><?php echo $MASSEGES['massage'];?></span> </p>                     <p>-----------------------------------------------------------------</p></td>               </tr>             </table>           <?php } ?> [/code] what i am trying to do and dont know how it i want it to show the resualt in backward order instead it will show newest raw as last i want it to show the newest as first in page and go on down the table to the oldes This suppost to be some kinda of post replay form . you have a window to post a replay after you do its just add it to database and then show it in table with fatch array. but its showing me the oldest replay as first in page instead of doing it like a forum which the first replay show's first in the page .. if anyone will help i will realy much appricate it thanks in advanced.
  5. well i am trying to make a deleteing form - for mails - i have a mail sending form and i am trying to add a delete form - but i have problem with my query  here is code : This code comes first [code]             <?php if($_POST['Deletemail'] != null) { $to_delete_this_message = $_POST['Deletemail']; $DELETEING = mysql_query("DELETE FROM userinboxmail WHERE MNUMBER = '$to_delete_this_message'",$MMO_LINK); } ?> [/code] This is the form its self : [code] <FORM action="WOW-MAILIN.PHP" method="POST">                   <input name="Deletemail" type="checkbox" id="Deletemail" value="<? echo $MMO_FE_GET_USERMAIL['MNUMBER'] ?>">                 <input name="DELETE" type="submit" id="DELETE" value="Delete"> </FORM> [/code] i am getting this error all time [quote] Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in C:\wamp\www\Yanivs\MMO-Date\WOW-MAILIN.PHP on line 578 [/quote] Any help would be great thnx
  6. thanks very much i will try to understand how to do it . its not simple though
  7. but what is my smtp server lol ? i only instaled Wamp server have no idea about smtp mate at least for now. thnx for help though
  8. well i have this code for sending the mail : [code]   $to = $_POST['REMAIL'];   $subject = "Activation details - MMODATE -";   $message = "Congratulation \r".$_POST['RUSERNAME']." \r for signing up with MMODATE your one step from beeing an active memeber of MMODATE<BR><BR>". 'Please click on this link to activate your account <BR> <a href= "http://localhost/Yanivs/MMO-Date/Activation.PHP?USDC='.$checkbig .'&USDP='.$_POST['RPASSWORD'] .'">http://localhost/Yanivs/MMO-Date/Activation.PHP?<a>';   $message = wordwrap($message, 70);   $headers  = 'MIME-Version: 1.0' . "\r\n";   $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";   $headers .= 'From: MMODATE <Monshery@localhost>' . "\r\n"; /* i am not sure what i am suppost to put in this */   mail($to, $subject, $message, $headers); [/code] well i am getting this error: [quote] Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 20, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\Yanivs\MMO-Date\Register.PHP on line 451 [/quote] Any help on how to configer my INI's would me amazing i am useing wamp server pack . thanks in advanced
  9. for eg: [code] blabla = "1"; blabla1 = "1"; if((isset(blabla)) or (isset(blabla1))) echo "working"; [/code] well realy stupid question but its the source for my big problem :"-)
  10. once more thinks [code] if(isset($_GET['action'])) $action=$_GET['action']; if(isset($_POST['action'])) $action=$_POST['action']; [/code] use $_GET/$_POST - in lower case since you use it as small case on your form like this $_get/$_post . or go to your form begining and in method  change it to method="POST" not method="post"
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.