|
In my php file called "account.php" I have
<html>
<body>
<link rel="icon" type="image/gif" href="favicon.gif" />
<div id="main-box">
<ul>
<li class="buttons">
="button"="account"="Get Your Account"="#"
</li>
</ul>
</div>
</body>
</html>
I want it so when the user clicks the button, a text box appears and displays ONE line from the text file and when they view it, it deletes it from the text file.
text.txt
Eddie
Apples
Hello
People
So after the user clicks the button it displays "Eddie" line to them and then deletes it after the user sees it so that the next line "Apples" would then become the first line.
If you don't understand my question then please let me know and I will try to explain further. Thank you.
|
|
|
|
|
|
Hi,
I have a table fetched using ajax, according to the choice made from my dropdown menu. In the table I have some input fields. I need to save my inputs in the table while submitting it.
If I check the source code of the page I cannot find the table fields to post using $_post since ajax is used. I am really new to ajax. Can anybody please tell me how I can submit these table input values in PHP?
Thanks in advance
|
|
|
|
|
I want to make a messageboard with php.
but I cant't insert data to database.
I dont know what's wrong in my code???
Can someone help me please?
<!DOCTYPE HTML>
<html>
<head>
<title> 留言板 </title>
</head>
<body>
<form action="insert.php" method="get">
請輸入名稱: <input type="text" name="name" />
請輸入標題: <input type="text" name="title" />
請輸入留言: <input type="text" name="message" />
請輸入電子郵件: <input type="text" name="email" />
<input type="submit" value="送出留言" name="post" />
</form>
</body>
</html>
<?php
require_once("connectdb.php");
if(isset($_GET["name"])!=""){
$query_insert = "INSERT INTO '1100108128'.'MB'
('USER','TITLE','MESSAGE','TIME','EMAIL')
VALUES (";$query_insert .= "'".$_GET["name"]."',";
$query_insert .= "'".$_GET["title"]."',";
$query_insert .= "'".$_GET["message"]."',";
$query_insert .= "NOW(),";
$query_insert .= "'".$_GET["email"]."')";
mysql_query($query_insert);
header("Location:Messageboard.php");
}
?>
|
|
|
|
|
replace
mysql_query($query_insert);
with
mysql_query($query_insert) or die('Error occured: ' . mysql_error());
Than reply with the output.
|
|
|
|
|
navigate data from database in webpage without page refresh
|
|
|
|
|
I make a little login example...
In the index.php :
<html>
<head>
<!--
</head>
<body>
Username:<input id="input-username" type="text" maxlength="100" />
Password:<input id="input-password" type="password" maxlength="16" />
<input id="btn-ok" type="button" value="OK" />
</body>
<script type="text/javascript">
$('#btn-ok').click(function() {
var DataToSend = new Object();
DataToSend.username = $('#input-username').val();
DataToSend.password = $('#input-password').val();
$.post('validate.php',DataToSend,function(data) {
if(data == 'ok')
alert('Login OK!');
else
alert('Login ERROR!');
});
});
</script>
</html>
You just make a post to a php file "validate.php" and there you validate the login, and make querys to the DataBase and return a value, and you are doing that all without refresh the page!
Any question, add me on gtalk: miguel.poegel@pears.fr
Regards,
KZ
|
|
|
|
|
ques 1: Php how can Multiple selected List box items move from one list box to another list box?
ques 2:Instead of Submit button how can i use Button or Any thing which do process like insert / update / delete /select without refresh the page?
navigate the data without page refresh how can i achieve in easy way?
|
|
|
|
|
You can use javascript... without refresh the page...
|
|
|
|
|
hi all.
I want get data form url when use header('location:'.$url) then it rederect to another url.
how to get data when using header('location:'.$url) ???
thanks
nothing
|
|
|
|
|
In one page you use:
header('Location: ' . $url);
Suppose $url = 'www.example.com/abcd.php?action=register';
And in the "abcd.php" page just do a $_GET['action'] to get the action!
And then you do something, in this case you show a div to register!
Hope I can help,
KZ
|
|
|
|
|
what about using :
$content = include '${url}';header("location:antoher url");
|
|
|
|
|
From where to start programming on Open Source?
|
|
|
|
|
From your posting in a thread below, you are at the beginner level in the learning phase. It will take you quite a while before you become competent. I would suggest you grab hold of this book and work through it doing some of the exercises.
Beginning PHP and MySQL: From Novice to Professional by W. Jason Gilmore
You could also visit the nettuts website, search for beginning php, and view their video tutorials.
When you feel you have reached some maturity in this PHP/MySQL subject, go look at, for example, SourceForge[^] who have a number of Open Source projects under some level of development.
modified 1-Aug-19 21:02pm.
|
|
|
|
|
|
|
How to Install PHP
, MySQL and Apache on my Machine?
|
|
|
|
|
You can get PHP from http://www.php.net/[^]. No doubt you can find the other two for yourself.
One of these days I'm going to think of a really clever signature.
|
|
|
|
|
|
WAMP is enough for the whole development envirnment?
I am on the beginning level, so want to know more about it.
|
|
|
|
|
Yes! WAMP is enough, I'm not familiar with WAMP, becouse I'm using XAMPP, and IIS with installed PHP.
|
|
|
|
|
Yes, WAMP is good for local Server. But we shall also need the server-side Application language[PHP] with the Database for storing captured Information.
|
|
|
|
|
Go to this page here and it gives a full rundown of how-to for differing applications. XAMPP or WAMP products are very good. I have tried XAMPP and it installs very easily and sets up very well. Easy to use and learn. It installs mysql, php, apache etc for you all at once as I assume WAMP does also. To answer one of your posts, either product provides a whole package for you to begin.
vbmike
|
|
|
|
|
Well if you are using Windows then you can install wamp or Xampp.
C#, VB.NET,ASP.NET DEVELOPER
|
|
|
|
|
What's more convenient you think - WAMP or XAMPP?
|
|
|
|