- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 4
- Posts with Upvotes
- 2
- Upvoting Members
- 4
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
SRM
- Interests
- Golf, Fishing, Soccer, AFL and PHP
28 Posted Topics
Re: Hi, This is a great post. I wanted to ask you a few questions about the security. I use a very similiar login method on one of my websites and i have read alot about this topic and many other tutorials suggest using sessions with hash, salt, session id, ip, … ![]() | |
Re: mine use to do that all the time and i would just reset the ports and everything would be fine again. in mamp its just preferences>ports should be similiar to wamp | |
Hi, I need to exclude any rows where the ASX_Prices.Date is a weekend. The date format is yyyy/mm/dd 2013/03/17. Ideally I would like to add another WHERE clause. WHERE ASX_Prices.Date !=weekend date????? $sql="SELECT Distinct ASX_Prices.ASX_Code, ASX_Prices.ASX_Price, ASX_Prices.Date, Company_Information.Company_Name FROM ASX_Prices, Company_Information WHERE ASX_Prices.ASX_Code = Company_Information.ASX_Code AND DateDiff(now(), ASX_Prices.Date)<=7 ORDER BY … | |
Hi All, This has become a very tedious process and I am hoping someone can help me simplify things. I run the below php command to retreive all the stock prices and then it prints it to the screen like this: stockcode price AAA $1 BBB $2 CCC $3 It … | |
Hi, This has been troubling me for the last hour and I cant think of a way around it. My SQL table looks like this: **Name, Cost** Matt, $5.00 Carl, $4.50 Tom, $6.00 Tom, $7.50 I need to make a query so that it puts anything with the same **Name** … | |
Re: Can you give more details? Are all the pages going to be the same design and layout? If so, then it would be easiest to use a php template that gets all the data from a database. When the user submits the data below it be stored in the database … | |
Re: The example you have given is a fairly simple form that probably uses AJAX for predictive text. Have a look at this video and it will go through the basics of creating a form - http://www.youtube.com/watch?v=vBxcPOxRgeE . | |
Re: for a start change [CODE]$sql="insert into vote(name)values('$name')";[/CODE] to this [CODE]$sql="insert into vote(name)values('$username')";[/CODE] | |
Hey Guys, I have an issue with my checkbox and the values that are posted to the next page. The issue is that each time the checkbox is clicked it just adds another value. example - if i check it and uncheck it and check it again i will get … | |
Re: Hi, you may need to have line 38 (in the revised code) like this [CODE]header("Location: '".$url.'"");[/CODE] | |
Re: I used this link a while back. [URL="http://www.codeproject.com/Tips/72592/IIS-7-needs-extra-configuration-to-allow-large-fil"]http://www.codeproject.com/Tips/72592/IIS-7-needs-extra-configuration-to-allow-large-fil[/URL] | |
Re: all the best. let us know how it goes and post some code along the way if you get stuck:) | |
Re: hi jelly, check out google api's. I've been told there fairly easy to integrate with any website. [URL="http://code.google.com/apis/maps/index.html"]http://code.google.com/apis/maps/index.html[/URL] | |
Re: Hi, You dont seem to have a variable $row which is what you have used as the values in your textboxes. [CODE]<input name="Staff_name" type="text" id="Staff_name" value="<?php echo $row['Staff_name'];?>" size="40">[/CODE] Replace this code [CODE]<?php$con = mysql_connect("localhost","root","root");if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("pqs", $con);$ref1 = $_REQUEST['ref1']; $result = … | |
Re: You should post the code that you currently have. [CODE] <?php //db connection //sql query $sql="SELECT NAME,SCORE FROM TABLE"; $result = mysql_query($sql); while($data=mysql_fetch_assoc($result)) { echo "<tr><td>Name:'".$data['name']."'</td>"; echo "<td>score:'".$data['score']."'</td></tr>"; } [/CODE] | |
Re: Hi, Have you tried putting an if statement at the start to only allow images? Like this... [CODE]if ($HTTP_POST_FILES['type']=="jpg"){ all your code} else { echo "only jpg allow";}[/CODE] or it might be better to do it this way [CODE]if ($HTTP_POST_FILES['type']!="jpg"){ echo "jpg only allowed";} else { all you code} [/CODE] | |
Re: I have no idea what your trying to say. could you please explain the last part a little better. (The problem is every time i select an option from a row, the -Select Order Status- will apear in the Order Status of the next row, but the last row function … | |
Re: Hi, Can you post the code that you currently have? ![]() | |
Re: You could have something like this for your page to get the details. [CODE] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Get Details</title> </head> <body> <form action="<?php echo $_SERVER['PHP_SELF'];?>" method="post" name="get_memb_gui"> <label>Member_Guid: </label> <input type="text" name="memguid" /> <input type="submit" value="Get Memb_guid" … | |
Re: Well the below code is very simple and works ok. You may want to consider if it secure enough for your needs. For instance make the password MD5 ect Login Script could be similiar to this [CODE]<?php session_start(); include('db_config.php'); $errmsg_arr = array(); $errflag = false; include ("database.php"); function clean($str) { … | |
Re: Try this instead... [CODE]$myquery="SELECT pro_brand FROM product_information ORDER BY pro_id DESC"; if ($result=mysql_query($myquery)) { while ($row=mysql_fetch_assoc($result)) { echo $row['pro_brand']; }} [/CODE] That works for me. i think the $myquery = mysql_query("select... may have caused issues for you. | |
Re: The $_GET is used to get variables from the URL. eg URL: example.php?id=123 GET: $id=$_GET['id']; The $_POST is used to get variables from a form on the previous page eg $id=$_POST[id']; i have never used the $_request before becuase you can do pretty much do everything with the post and … | |
Re: At the moment you have a few things wrong. The form action should be SaveEvent.php . Im not sure what the hiddenframe is but get rid of it. You also don't need to have an onsubmit function because you already have the action in the form. [CODE]<form name="event" action="SaveEvent.php" method="POST"> … | |
Re: On line 36 you appear to have $id2 outside the braces of the first query so i dont think it would have a value. Try moving $id2 to line 32 and make sure all other variables are with the while loop of the query. one thing you could try is … | |
Re: thats a very confusing post. however, something in the select name doesnt look right. [CODE]<select name='cb_permissions['".$row['emp_number']."'>[/CODE] Possibly an extra bracket at the start ...ions['".$row... maybe try this [CODE]<select name='cb_permissions'".$row['emp_number']."'>[/CODE] ref:line71 | |
Re: [CODE]<?php $name=$_GET['name']; $target = "../upload/$name"; $myFile = $target; unlink($myFile);[/CODE] This is a piece of code that i have used once before. In this case i have got the file name after it was posted to the url. The unlink part is the bit where it deletes the file. Make sure … |
The End.