Find Jobs
Hire Freelancers

Convert 1 page from mySql to PDO

₹600-1500 INR

已关闭
已发布超过 7 年前

₹600-1500 INR

货到付款
This should be a quick fix for a good programmer. Please read instructions carefully. I have 1 website that is working now. It uses the following code in MySQL and it works perfectly. I also have a NEW website that uses PDO. I would like this code converted to PDO so that it does the same thing, just written in PDO. I am going to hire, pay, and leave 5 star positive feedback for the first programmer who can deliver working code in PDO format. I understand very little about programming and this is why I cannot do this myself. Contract price is $5.00 or less. If you bid less, I will test your code first. <form name='input' method='post' action=''> <input type='hidden' name='userID' /> <div align="center"><?=$error?></div> <table border=0 cellspacing=2 cellpadding="2" style='border:2px solid black;'> <tr style="font-weight:bold"> <td><center>Name</th> <th>Day</th> <th>Date</th> <th>Hrs. Worked</th> <th>Description of Work </th> <td>Submit</th> <td>Remaining</th> </tr> <?php if (isset($_POST['userID'])) { mysql_query(' insert into timesheet set userID = ' . $_POST['userID'] . ', day = "' . $_POST['day_' . $_POST['userID']] . '", date = "' . $_POST['date_' . $_POST['userID']] . '", hours = "' . $_POST['hours_' . $_POST['userID']] . '", description = "' . $_POST['description_' . $_POST['userID']] . '", status = 1, worksite = "' . $info['worksite'] . '" ') or print(mysql_error() . '<br /><br />'); } $userID = $info['ID']; $i=1; $query=mysql_query("SELECT firstname,lastname,hours,ID FROM `users` where type='volunteer' and worksite='".$info['worksite']."' ORDER BY 2,3 ASC"); while($row = mysql_fetch_assoc($query)) { $select_hrs = mysql_query("select sum(hours) as completed_hours from timesheet where worksite='".$info['worksite']."' and status=1 and userID='".$row['ID']."'") or die(mysql_error()); $hrs = mysql_fetch_assoc($select_hrs); $remaining_hours = $row['hours'] - $hrs['completed_hours']; $date_query = "select date from timesheet where ID = (select max(ID) from timesheet where worksite='".$info['worksite']."' and status=1 and userID='".$row['ID']."') "; //echo $date_query;die(); $select_date = mysql_query($date_query) or die("2".mysql_error()); $get_date = mysql_fetch_assoc($select_date); if($remaining_hours > 0) { ?> <tr bgcolor=<? $k = $i%2; if($k == 1) { $color= "#FFFFFF"; } else { $color = "#EBEDF3"; } echo $color?> > <td align='center'><?=$row['firstname']." ".$row['lastname']?></td> <td align='center'> <select name='day_<?php echo $row['ID'] ?>'> <option value="Monday" <? if(date('N') ==1){ echo "selected";}?>>Monday</option> <option value="Tuesday" <? if(date('N') ==2){ echo "selected";}?>>Tuesday</option> <option value="Wednesday" <? if(date('N') ==3){ echo "selected";}?>>Wednesday</option> <option value="Thursday" <? if(date('N') ==4){ echo "selected";}?>>Thursday</option> <option value="Friday" <? if(date('N') ==5){ echo "selected";}?>>Friday</option> <option value="Saturday" <? if(date('N') ==6){ echo "selected";}?>>Saturday</option> <option value="Sunday" <? if(date('N') ==7){ echo "selected";}?>>Sunday</option> </select> </td> <!-- <script>DateInput('date', true, 'DD-MON-YYYY')</script> --> <td><script>DateInput('date_<?php echo $row['ID'] ?>', true, 'MM/DD/YYYY')</script></td> <th bgcolor="green"><input name='hours_<?php echo $row['ID'] ?>' type="text" value="" size="6"</th> </th> <td><input name='description_<?php echo $row['ID'] ?>' type="text" value="" size="20"></td> <td bgcolor="green"><input type='button' value='Submit' onclick='[login to view URL] = "<?php echo $row['ID'] ?>"; [login to view URL]();'></td> <td align='center'><?=$remaining_hours?></td> <!-- <td bgcolor="yellow"><input type="button" value="Time" onClick="javascript:window.location.href='[login to view URL]<?=$row['ID']?>'"></td> </tr> --> <?php } $i++; } ?>
项目 ID: 12105324

关于此项目

5提案
远程项目
活跃7 年前

想赚点钱吗?

在Freelancer上竞价的好处

设定您的预算和时间范围
为您的工作获得报酬
简要概述您的提案
免费注册和竞标工作
5威客以平均价₹1,010 INR来参与此工作竞价
用户头像
I can have this done today. I have hundreds of hours of experience with PDO and understand how to implement it correctly.
₹600 INR 在1天之内
5.0 (2条评论)
3.4
3.4
用户头像
Hi. Understood what you want. I often use PDO (MySQL) in my projects. I can make for you in max 2 hours.
₹600 INR 在1天之内
0.0 (0条评论)
0.0
0.0
用户头像
I have 2 years of experience in PHP and database. Please give me an opportunity. I am new as freelancer so in my profile there is no project but I am doing job as software developer. I hope you will give me an opportunity Thank you
₹1,300 INR 在1天之内
0.0 (0条评论)
0.0
0.0

关于客户

INDIA的国旗
DINANAGAR, India
5.0
9
会员自5月 1, 2016起

客户认证

谢谢!我们已通过电子邮件向您发送了索取免费积分的链接。
发送电子邮件时出现问题。请再试一次。
已注册用户 发布工作总数
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
加载预览
授予地理位置权限。
您的登录会话已过期而且您已经登出,请再次登录。