Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
138 changes: 69 additions & 69 deletions about.php
Original file line number Diff line number Diff line change
@@ -1,69 +1,69 @@
<?php include "core.php";?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<!--about us page-->
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>About Us</title>
<meta name="keywords" content="PDFs Books" />
<meta name="description" content="Free Pdfs to download" />
<link href="http://fonts.googleapis.com/css?family=Varela" rel="stylesheet" />
<link href="default.css" rel="stylesheet" type="text/css" media="all" />
<link href="fonts.css" rel="stylesheet" type="text/css" media="all" />

</head>
<body>
<div id="wrapper">
<div id="header-wrapper">
<?php include "header.php";?>
</div>
<div id="banner">
<div class="container">
<div class="title">
<h2>About Us</h2>
<span class="byline">We are the group of students.
</br>Our objective is to share the resources with everyone.</br>
Across the globe.</br>Without any restrictions.</span>
</div>
<p>Note:We won't Host any content on this site.
We just list the PDF's available across the internet and free to download.</p>
</div>
</div>

<div id="featured">
<div class="container">
<div class="title">
<h2></h2>
<span class="byline"> Have some PDFs book to share with others.</br> Come join us.
</br>We are pleased to have u with us
</span> </div>
<p></p>
</div>
<ul class="actions">
<li><a href="join" class="button">Join us</a></li>
</ul>
</div>
<div id="page" class="container">
<div class="title">
<h2></h2>
<span class="byline">Want to suggest something</span> </div>
<p> We would like to hear from You. </p>
<ul class="actions">
<li><a href="suggest" class="button">Suggest</a></li>
</ul>
</div>
<div id="featured">
<div class="container">
<div class="title">
<h2></h2>
<span class="byline">We would like Thanks the Developers </br>
Who Helped and Helping in Development and Running of this Site.
</span> </div>
</div>
</div>
</div>
<div id="copyright" class="container">
<?php include "footer.php";?>
</div>
</body>
</html>
<?php include "core.php";?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<!--about us page-->
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>About Us</title>
<meta name="keywords" content="PDFs Books" />
<meta name="description" content="Free Pdfs to download" />
<link href="http://fonts.googleapis.com/css?family=Varela" rel="stylesheet" />
<link href="default.css" rel="stylesheet" type="text/css" media="all" />
<link href="fonts.css" rel="stylesheet" type="text/css" media="all" />
</head>
<body>
<div id="wrapper">
<div id="header-wrapper">
<?php include "header.php";?>
</div>
<div id="banner">
<div class="container">
<div class="title">
<h2>About Us</h2>
<span class="byline">We are the group of students.
</br>Our objective is to share the resources with everyone.</br>
Across the globe.</br>Without any restrictions.</span>
</div>
<p>Note:We won't Host any content on this site.
We just list the PDF's available across the internet and free to download.</p>
</div>
</div>
<div id="featured">
<div class="container">
<div class="title">
<h2></h2>
<span class="byline"> Have some PDFs book to share with others.</br> Come join us.
</br>We are pleased to have u with us
</span> </div>
<p></p>
</div>
<ul class="actions">
<li><a href="join" class="button">Join us</a></li>
</ul>
</div>
<div id="page" class="container">
<div class="title">
<h2></h2>
<span class="byline">Want to suggest something</span> </div>
<p> We would like to hear from You. </p>
<ul class="actions">
<li><a href="suggest" class="button">Suggest</a></li>
</ul>
</div>
<div id="featured">
<div class="container">
<div class="title">
<h2></h2>
<span class="byline">We would like Thanks the Developers </br>
Who Helped and Helping in Development and Running of this Site.
</span> </div>
</div>
</div>
</div>
<div id="copyright" class="container">
<?php include "footer.php";?>
</div>
</body>
</html>
78 changes: 39 additions & 39 deletions add_comment.php
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
<?php
include_once 'core.php';
include_once 'user/core.inc.php';
if (loggedin()==1)
{ $head=$_POST['head'];
$comment=$_POST['comment'];
$acess=1;
if (isset($head) && isset($comment) )
{
if (!empty($head) && !empty($comment) )
{
include 'add_comment_script.php';
//die(); //to kill rest of page
//echo "some problem occurs<br/>";
}
else
{
echo "<br/>Some error has occur.<br> Please check the values. Might be some field left out. ";
include 'add_comment_form.php';
}


}
else
{
include 'add_comment_form.php';
}


}
else
{
if ($countc==0)
{
echo "<p>Be the first one to comment </p>";
}
echo "<hr></hr><br/>Please <a href=\"login.php\">login</a> to post comments";
}

<?php
include_once 'core.php';
include_once 'user/core.inc.php';
if (loggedin()==1)
{ $head=$_POST['head'];
$comment=$_POST['comment'];
$acess=1;
if (isset($head) && isset($comment) )
{
if (!empty($head) && !empty($comment) )
{
include 'add_comment_script.php';
//die(); //to kill rest of page
//echo "some problem occurs<br/>";
}
else
{
echo "<br/>Some error has occur.<br> Please check the values. Might be some field left out. ";
include 'add_comment_form.php';
}
}
else
{
include 'add_comment_form.php';
}
}
else
{
if ($countc==0)
{
echo "<p>Be the first one to comment </p>";
}
echo "<hr></hr><br/>Please <a href=\"login.php\">login</a> to post comments";
}
?>
54 changes: 27 additions & 27 deletions add_comment_form.php
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
<?php
include_once "user/core.inc.php";
include_once 'core.php';
if ($countc==0)
{
echo "<p>Be the first one to comment </p>";
}
?>
<br/>
<form action="<?php echo "$current_file?ref=$bid";?>" method="post" >
<fieldset>
<input type="hidden" value="<?php echo "$uid" ?>" name="uid" size="3" maxlength="20">
<input type="hidden" value="<?php echo "$bid" ?>" name="bid" size="3" maxlength="20">
<fieldset>
<legend>Heading:</legend>
<input type="text" value="<?php echo "$head" ?>" name="head" size="70" maxlength="100">
</fieldset>
<fieldset>
<legend>Comment:</legend>
<textarea value="<?php echo "$comment" ?>" name="comment" cols="50" rows="10"><?php echo "$comment" ?></textarea>
</fieldset>
<br/>
<input type="submit" name="Post" value="Post" size="7">
</fieldset>
</form>
<?php

<?php
include_once "user/core.inc.php";
include_once 'core.php';
if ($countc==0)
{
echo "<p>Be the first one to comment </p>";
}
?>
<br/>
<form action="<?php echo "$current_file?ref=$bid";?>" method="post" >
<fieldset>
<input type="hidden" value="<?php echo "$uid" ?>" name="uid" size="3" maxlength="20">
<input type="hidden" value="<?php echo "$bid" ?>" name="bid" size="3" maxlength="20">
<fieldset>
<legend>Heading:</legend>
<input type="text" value="<?php echo "$head" ?>" name="head" size="70" maxlength="100">
</fieldset>
<fieldset>
<legend>Comment:</legend>
<textarea value="<?php echo "$comment" ?>" name="comment" cols="50" rows="10"><?php echo "$comment" ?></textarea>
</fieldset>
<br/>
<input type="submit" name="Post" value="Post" size="7">
</fieldset>
</form>
<?php
?>
100 changes: 50 additions & 50 deletions add_comment_script.php
Original file line number Diff line number Diff line change
@@ -1,51 +1,51 @@
<?php
//checking the data entered for invalid data
$acess=0;
if (isset($head) && !empty($head))
{
$acess=1;
}
if (isset($comment) && !empty($comment))
{
$acess=1;
}
//echo "$head & <br/>$comment"; //for testing only
$mysql_query_run=$connection->query("SELECT DISTINCT `comment` FROM `comments` WHERE `bookid`='$bid'");
while ($rows=$mysql_query_run->fetch_array())
{
$com=$rows[0];
if($com==$comment)
{
$acess=0;
echo "Please Don't copy someones comment<br/>";
}
}
//neutralizing the data
if ($acess==1)
{
$head=htmlentities($head);
$comment=htmlentities($comment);
$date=date('Y-m-d H:i:s'); //to get the current system date time.
// php insertion code
$sql = "INSERT INTO `comments` (`cid`, `userid`, `bookid`, `cheadding`, `comment`, `date`) VALUES (NULL, '$uid', '$bid', '$head', '$comment', '$date');";

include_once "user/core.inc.php"; //to get database acess

$mysql_query_run=$connection->query($sql); //data adding query
if(!$mysql_query_run)
{
// error occurs
echo "<br>Error writing data".@mysqli_error($connection);
}
else
{ //sucess in adding the data.
echo "Thank you for your comment";
//header('location: $current_file'); //to refresh current page.
}
}
else
{
echo "<br/>Some error has occur.<br> Please check the values. Might be some field left out.";
include 'add_comment_form.php';
}
<?php
//checking the data entered for invalid data
$acess=0;
if (isset($head) && !empty($head))
{
$acess=1;
}
if (isset($comment) && !empty($comment))
{
$acess=1;
}
//echo "$head & <br/>$comment"; //for testing only
$mysql_query_run=$connection->query("SELECT DISTINCT `comment` FROM `comments` WHERE `bookid`='$bid'");
while ($rows=$mysql_query_run->fetch_array())
{
$com=$rows[0];
if($com==$comment)
{
$acess=0;
echo "Please Don't copy someones comment<br/>";
}
}
//neutralizing the data
if ($acess==1)
{
$head=htmlentities($head);
$comment=htmlentities($comment);
$date=date('Y-m-d H:i:s'); //to get the current system date time.
// php insertion code
$sql = "INSERT INTO `comments` (`cid`, `userid`, `bookid`, `cheadding`, `comment`, `date`) VALUES (NULL, '$uid', '$bid', '$head', '$comment', '$date');";
include_once "user/core.inc.php"; //to get database acess
$mysql_query_run=$connection->query($sql); //data adding query
if(!$mysql_query_run)
{
// error occurs
echo "<br>Error writing data".@mysqli_error($connection);
}
else
{ //sucess in adding the data.
echo "Thank you for your comment";
//header('location: $current_file'); //to refresh current page.
}
}
else
{
echo "<br/>Some error has occur.<br> Please check the values. Might be some field left out.";
include 'add_comment_form.php';
}
?>
Loading