peranha
Members-
Posts
878 -
Joined
-
Last visited
Everything posted by peranha
-
yes it is because it is text, so it need the single quotes. hence what you have there.
-
yeah that looks correct, you can always back up your table as well.\ Make sure you have the quotes, and the ; in there as well.
-
That is called pagination. There is a tutorial on the main phpfreaks website that can help you, or just do a google search for pagination. http://www.phpfreaks.com/tutorial/basic-pagination
-
We need to see the code for this page SearchNotFinished.php on line 75
-
[SOLVED] Help With Complex Query (at least complex to me)
peranha replied to refiking's topic in PHP Coding Help
$ratring2 is that supposed to be $rastring2 -
Unable to modify posts with google chrome.
peranha replied to blueman378's topic in PHPFreaks.com Website Feedback
That is what i said is it wasnt the original, it was when you edit. -
buddy, settle down, like stated before, on the login page all you will do is header ("Location: page.php"); and on that page, select the data from the sql database, and display it. This is a true statement. if You dont know php, sql, I suggest you go the freelancing forum and see if anyone will write it for you.
-
You may need to post some code you currently have, almost everyone on here will not write things for you.
-
Unable to modify posts with google chrome.
peranha replied to blueman378's topic in PHPFreaks.com Website Feedback
it's not the original posting it is when you edit. -
is you "least fastest" machine only running at 10X instead of 100X? Full duplex? or half duplex?
-
I use it all the time, it will display all them, just have a scroll bar at the bottom.
-
Try this and see what you get. are the passwords encrypted? # Retrieve password from result, strip slashes $dbarray = mysql_fetch_array($result); $dbarray['password'] = stripslashes($dbarray['password']); $password = stripslashes($password); echo "password is" . $password . "<br />; echo "dbpassword is" . $dbarray['password']; # Validate that password is correct if ($password == $dbarray['password']) { return 0; // Sucess! usrname and pw confirmed } else { return 2; // Indicates password failure }
-
Ultra VNC, or any vnc software for that matter. It will have a scroll bar at the bottom of the screen if the remote computers resolution is larger than your local computer.
-
Just go with an IP camera, and not worry about software.
-
try setting a variable with the $_get value and see if that works. $rt = $_GET['rt']; then use $rt in the redirect. or try this header ("Location: showtop.php?t_id=$_POST[t_id]&rt=$_GET[rt]");
-
in the second code, why are you suppressing all errors with the @ symbol?
-
try this, you didnt close your else statement. <?php $ip = $_SERVER['REMOTE_ADDR']; $useripdata = "/ip/$ip.txt"; if (file_exists($useripdata)) { foreach (file($useripdata) as $line) { echo '$' . $line; } for ($i=0; $i < $numTimes; $i++) { echo '<object width="$setwidth" height="$setheight""><param name="movie" value="http://www.youtube.com/v/' . $shorturl . '&hl=en&fs=1"></param><param name="allowFullScreen" value="false"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/' . $shorturl . '&hl=en&fs=1$autoplay" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="false" width="$setwidth" height="$setheight"></embed></object>'; } echo "<meta http-equiv='refresh' content='$reloadtime'>"; } else { if (isset($_POST['action'])) { $numTimes = (isset($_POST['times']) && is_numeric($_POST['times']))?$_POST['times']:10; $shorturl = $_POST['url']; $autoplay = "&autoplay=1"; $reloadtime = $_POST['reloadtime']; $setwidth = $_POST['setwidth']; $setheight = $_POST['setheight']; $shorturl = $_POST['url']; $fullurl = "http://www.youtube.com/watch?v=$shorturl"; $myFile = "./ip/$ip.txt"; $fh = fopen($myFile, 'w'); $stringData = "numTimes = 10 \n"; fwrite($fh, $stringData); $stringData = "shorturl = $shorturl \n"; fwrite($fh, $stringData); $stringData = "autoplay = $autoplay \n"; fwrite($fh, $stringData); $stringData = "reloadtime = $reloadtime \n"; fwrite($fh, $stringData); $stringData = "setwidth = $setwidth \n"; fwrite($fh, $stringData); $stringData = "setheight = $setheight \n"; fwrite($fh, $stringData); $stringData = "fullurl = $fullurl \n"; fwrite($fh, $stringData); fclose($fh); function check_if_valid($fullurl) { $res = (($check = @fopen($fullurl, ‘r’)) === false) ? false : @fclose($check); return ($res == TRUE) ? VIDEO_IS_VALID:VIDEO_IS_INVALID ; } if ($HTTP_POST_VARS["submitted"] == "yes"){ echo "<meta http-equiv='refresh' content='$reloadtime'>"; } for ($i=0; $i < $numTimes; $i++) { echo '<object width="$setwidth" height="$setheight""><param name="movie" value="http://www.youtube.com/v/' . $shorturl . '&hl=en&fs=1"></param><param name="allowFullScreen" value="false"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/' . $shorturl . '&hl=en&fs=1$autoplay" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="false" width="$setwidth" height="$setheight"></embed></object>'; } $self = $_SERVER['PHP_SELF']; echo "<table border='1'>"; echo "<form action='$self' method='post'>"; echo "<tr>"; echo "<td>Video Url:<input type='text' readonly='1' value='http://www.youtube.com/watch?v=' size='30'><input type='Text' name='url'></td>"; echo "</tr>"; echo "<tr>"; echo "<td>(Number)<input type='text' name='times' value='10'> of Times to Display Video in <input type='text' name='reloadtime' value='5'>(Seconds)</td>"; echo "</tr>"; echo "<tr>"; echo "<td>Set Width <input type='text' name='setwidth' value='425'> Set Height <input type='text' name='setheight' value='344'>"; echo "</tr>"; echo "<tr>"; echo "<td align='center' valign='center'><input type='submit' name='action' value='Submit'>"; echo "<input type='hidden' name='submitted' value='yes'>"; echo "</td>"; echo "</tr>"; echo "</form>"; echo "</table>"; } } ?>
-
yeah, very well could be.
-
without seeing some code before line 52, including line 52, it is hard to say.
-
$sDELQUERY = "DELETE * FROM tblComment WHERE sCommentID='$DelID';"; should be $sDELQUERY = "DELETE FROM tblComment WHERE sCommentID='$DelID'"; You dont use * for delete statements, and also the ; was not needed.
-
Where are you actually running this query at? $query = "SELECT `a`.`post_id`, `a`.`author_id`, `a`.`author_name`, DATE_FORMAT(`a`.`date_posted`, '%W, %M %d %Y %l:%i %p'), `a`.`author_email`, `a`.`category_id`, `c`.`category_name`, `a`.`title`, `a`.`post_body` FROM `posts` `a` INNER JOIN `categories` `c` ON `a`.`category_id` = `c`.`category_id` ORDER BY `a`.`date_posted` DESC LIMIT 4"; something along the lines of mysql_query($query); also in your if statement in the first set of codes, I believe you want to check if it is not set with isset. With something along these lines. if (!isset($_GET['postID'])) { // CODE GOES HERE }
-
I have a delay, I wouldnt say that it is a long delay, but it is definitely noticeable. You're just going to have to put up with it. Obviously
-
I have a delay, I wouldnt say that it is a long delay, but it is definitely noticeable.
-
also on a side note, never use short php tags. <? always use the full <?php opening tag as short tags may not be supported on the server.
-
At the very top of the page put error_reporting(E_ALL); and after all the queries add mysql_error() I fixed the one query below for you. $vils="SELECT * from km_villages where user='$player'"; $vils2=mysql_query($vils) or die("Could not get user stats".mysql_error()); $vils3=mysql_fetch_array($vils2);