-
Posts
252 -
Joined
-
Last visited
Posts posted by ryanfilard
-
-
Try This:
$f_q = mysql_query("SELECT * DISTINCT thread FROM jos_kunena_messages ORDER BY id DESC");
-
-
My email is [email protected] what is really bad please email me
-
It is great! I did not see any problems with your website.
-
Try this:
body { text-align: center; }
-
Try NeoLoad It worked for me.
-
It is because the div is automatically readjusting itself.
-
I use this:
<?php $link = mysql_connect("localhost", "myuser", "mypass"); mysql_select_db("login_system", $link); $result = mysql_query("SELECT * FROM users", $link); $num_rows = mysql_num_rows($result); $totalone = $num_rows ; echo "$totalone"; ?>
-
How would I become a global moderator for the forum?
-
header("location:yourpage.php");
it should redirect you.
Here is the redirect code in html
<meta HTTP-EQUIV="REFRESH" content="0; url=http://www.yourweb.com/index.html">
-
Linux
-
I am running my own sever with cpanel
-
Is there a way when a user signs up it can make a subdomain
-
You need to have a site and testing server to add a database.
-
How do I make a light div shadow?
-
Folks,
I have an Image URL, i want to show this image on my site but i want to resize the image on the fly.
Image:
http://ecx.images-amazon.com/images/I/41daynaberL._SL75_.jpg
What i am doing is:
<img height="100" width="80" src="http://ecx.images-amazon.com/images/I/41daynaberL._SL75_.jpg" />
But its not resizing the Image...
Any solutions?
Cheers
N
Have img height="100" width="80" after the img src <src="http://ecx.images-amazon.com/images/I/41daynaberL._SL75_.jpg" img height="100" width="80" />
-
Is there a way I can use google adsense in simple machines forum? (And also add more links in the link bar)
-
Is there a way I can do this?
-
use the order by clause. I don't know what column you want to sort by descending but that page should give you enough information to get started
All of them
-
How can I make this so it makes my table descending.
http://www.ryanweekly.com/user/index.php?p=ryanweekly
<?PHP $maxRows_posting = 6; $pageNum_posting = 0; if (isset($_GET['pageNum_posting'])) { $pageNum_posting = $_GET['pageNum_posting']; } $startRow_posting = $pageNum_posting * $maxRows_posting; mysql_select_db($database_posting, $posting); $query_posting = "SELECT post, fromwho FROM post WHERE username = '$uasilly'"; $query_limit_posting = sprintf("%s LIMIT %d, %d", $query_posting, $startRow_posting, $maxRows_posting); $posting = mysql_query($query_limit_posting, $posting) or die(mysql_error()); $row_posting = mysql_fetch_assoc($posting); if (isset($_GET['totalRows_posting'])) { $totalRows_posting = $_GET['totalRows_posting']; } else { $all_posting = mysql_query($query_posting); $totalRows_posting = mysql_num_rows($all_posting); } $totalPages_posting = ceil($totalRows_posting/$maxRows_posting)-1; $queryString_posting = ""; if (!empty($_SERVER['QUERY_STRING'])) { $params = explode("&", $_SERVER['QUERY_STRING']); $newParams = array(); foreach ($params as $param) { if (stristr($param, "pageNum_posting") == false && stristr($param, "totalRows_posting") == false) { array_push($newParams, $param); } } if (count($newParams) != 0) { $queryString_posting = "&" . htmlentities(implode("&", $newParams)); } } $queryString_posting = sprintf("&totalRows_posting=%d%s", $totalRows_posting, $queryString_posting); $queryString_recordset2 = ""; if (!empty($_SERVER['QUERY_STRING'])) { $params = explode("&", $_SERVER['QUERY_STRING']); $newParams = array(); foreach ($params as $param) { if (stristr($param, "pageNum_recordset2") == false && stristr($param, "totalRows_recordset2") == false) { array_push($newParams, $param); } } if (count($newParams) != 0) { $queryString_recordset2 = "&" . htmlentities(implode("&", $newParams)); } } $queryString_recordset2 = sprintf("&totalRows_recordset2=%d%s", $totalRows_recordset2, $queryString_recordset2); $userida = $_REQUEST['p']; require_once('../Connections/loginsys.php'); ?>
-
-
-
I found out how to do it!
you just put
$insert_go_to "index.php?p=$userid";
-
$insertGoTo = "<a href=\"index.php?id=$sbnineseven\">Link</a>
It didn't work here is more of my script
<?php if (!function_exists("GetSQLValueString")) { function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") { if (PHP_VERSION < 6) { $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue; } $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue); switch ($theType) { case "text": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "long": case "int": $theValue = ($theValue != "") ? intval($theValue) : "NULL"; break; case "double": $theValue = ($theValue != "") ? doubleval($theValue) : "NULL"; break; case "date": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "defined": $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue; break; } return $theValue; } } if (!function_exists("GetSQLValueString")) { function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") { if (PHP_VERSION < 6) { $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue; } $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue); switch ($theType) { case "text": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "long": case "int": $theValue = ($theValue != "") ? intval($theValue) : "NULL"; break; case "double": $theValue = ($theValue != "") ? doubleval($theValue) : "NULL"; break; case "date": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "defined": $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue; break; } return $theValue; } } $currentPage = $_SERVER["PHP_SELF"]; $editFormAction = $_SERVER['PHP_SELF']; if (isset($_SERVER['QUERY_STRING'])) { $editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']); } if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) { $insertSQL = sprintf("INSERT INTO post (username, post, fromwho) VALUES (%s, %s, %s)", GetSQLValueString($_POST['usernme'], "text"), GetSQLValueString($_POST['share4'], "text"), GetSQLValueString($_POST['fromwho'], "text")); mysql_select_db($database_posting, $posting); $Result1 = mysql_query($insertSQL, $posting) or die(mysql_error()); $insertGoTo = "index.php?p=$i"; if (isset($_SERVER['QUERY_STRING'])) { $insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?"; $insertGoTo .= $_SERVER['QUERY_STRING']; } header(sprintf("Location: %s", $insertGoTo)); } $maxRows_posting = 6; $pageNum_posting = 0; if (isset($_GET['pageNum_posting'])) { $pageNum_posting = $_GET['pageNum_posting']; } $startRow_posting = $pageNum_posting * $maxRows_posting; mysql_select_db($database_posting, $posting); $query_posting = "SELECT post, fromwho FROM post WHERE username = '$uasilly'"; $query_limit_posting = sprintf("%s LIMIT %d, %d", $query_posting, $startRow_posting, $maxRows_posting); $posting = mysql_query($query_limit_posting, $posting) or die(mysql_error()); $row_posting = mysql_fetch_assoc($posting); if (isset($_GET['totalRows_posting'])) { $totalRows_posting = $_GET['totalRows_posting']; } else { $all_posting = mysql_query($query_posting); $totalRows_posting = mysql_num_rows($all_posting); } $totalPages_posting = ceil($totalRows_posting/$maxRows_posting)-1; $queryString_posting = ""; if (!empty($_SERVER['QUERY_STRING'])) { $params = explode("&", $_SERVER['QUERY_STRING']); $newParams = array(); foreach ($params as $param) { if (stristr($param, "pageNum_posting") == false && stristr($param, "totalRows_posting") == false) { array_push($newParams, $param); } } if (count($newParams) != 0) { $queryString_posting = "&" . htmlentities(implode("&", $newParams)); } } $queryString_posting = sprintf("&totalRows_posting=%d%s", $totalRows_posting, $queryString_posting); $queryString_recordset2 = ""; if (!empty($_SERVER['QUERY_STRING'])) { $params = explode("&", $_SERVER['QUERY_STRING']); $newParams = array(); foreach ($params as $param) { if (stristr($param, "pageNum_recordset2") == false && stristr($param, "totalRows_recordset2") == false) { array_push($newParams, $param); } } if (count($newParams) != 0) { $queryString_recordset2 = "&" . htmlentities(implode("&", $newParams)); } } $queryString_recordset2 = sprintf("&totalRows_recordset2=%d%s", $totalRows_recordset2, $queryString_recordset2); $userida = $_REQUEST['p']; require_once('../Connections/loginsys.php'); ?>
Trying to display unique rows?
in MySQL Help
Posted
Did you try the "ORDER BY id DESC"
It works here:
http://ryanweekly.com/user/index.php?p=ryanweekly