Code: <?php
session_start();
include("connect.php");
error_reporting(E_ALL);
ini_set('display_errors', '1');
$username = "Master";
$password = "pword";
$host = "localhost";
$database = "Ustack";
// Make the connect to MySQL or die
// and display an error.
$link = mysql_connect($host, $username, $password);
if (!$link) {
die('Could not connect: ' . mysql_error());
}
// Select your database
mysql_select_db ($database);
$url = mysql_real_escape_string($_POST['url']);
$tags = get_meta_tags($url);
$username1 = $_SESSION['username'];
$url = mysql_real_escape_string($_POST['url']);
$name = mysql_real_escape_string($_POST['title']);
$description = $tags['description'];
$keywords = $tags['keywords'];
$ip = $_SERVER['REMOTE_ADDR'];
$query = "INSERT INTO Stacks";
$query .= "(`username`,`hyperlink`,`name`,`summary`,`info`,`keywords`,`ip`,`posted`) VALUES ('$username1','$url','$name','$description','$description','$keywords','$ip',NOW())";
$results = mysql_query($query, $link);
if($query){
print "
<font color=white>Your webpage has been stacked. <a href='menu.php'>Return to Stacker</a></font>"; }
else {
print "No url selected/uploaded";
}
// Close our MySQL Link
mysql_close($link);
?>
its not inserting into mysql, i get no errors... whats the problem?
What are the two different files you download to update kernel?
What are the two different files you download to update kernel?
Update Database
Hi All,I have a problem with this:Code: [Select]<?phpsession_start();include('../common/dbconnect.php');$stock_id = $_GET['stock_id'];$query='SELECT * FROM users_stocks WHERE user_id ="' .
How to show a complete textarea ??
I enter Client Case Notes notes in a textarea field on a PHP form. The field is 5 rows deep and 70 chars wide , using the scroll bar to see beyond 5 lines.After entering notes, I want to echo or print
Supress some serveroutput but not all
Hi,
insert mysql embeded videos as blobs?
Using TinyMCE my client will be able to embed images and flash videos into large columns of text which will obviously be printed out client side at a later date. What my question is that is it
Page not Loading After Test
Hey AllIt seemed that an inlcude statement wasn't working for some reason, so I tried a more absolute file path:include("home/username/public_html/coding/scripts/carspecs.php")However this
puting for loop in 1 value
hi ,how do i put this code in 1 value:Code: <?phpfor ($i=1; $i<=5; $i++) { echo $i ; }?>the output will be: 12345how do i put the result in one value ,some thing like :if the
Parse Error
Hi Guys,I have a function in my class which returns a string link variable. The problem is it keeps giving me a parse error. See code below followed by error message:Code: function
CURL XML Request [From C to PHP]
Hi, I need some help converting this into something that will work with PHP.Code:
Sharing PHP Sessions Across Domains
I am in the process of writing a script to share a php session across various domains I have.The problem I have, is getting php to access the php session. It gives me a persmission error. It seems the