• NudeCelebForum has been moved from the vBulletin to the XenForo platform.
    For additional information, see: NCF Moved To XenForo
  • New threads will not be visible until approved by a moderator.

  • Welcome to the forum!
    You must activate your account in order to post and view all forum content
    Please check your email inbox & spam folders for our activation email, then follow the link to validate your email address.
    Contact Us if you are having difficulty posting or viewing forum content.
  • You are viewing our forum as a guest, with limited access.
    By joining you will gain full access to thousands of Videos, Pictures & Much More.
    Membership is absolutely FREE! Registration is FAST & SIMPLE.
    Register Today to join the first, most comprehensive and friendliest communities of nude celebrity fans on the net!

OK Bright minds here, I need your help.

-KA-

Staff Alumn
Joined
Sep 15, 2006
Messages
12,379
Reaction score
40,213
Here I go. The thing I need is a register/signature giving type of HTML page. I try to explain...

I need a HTML page which has 4 slots (fields) where I can insert text in (first name, last name, age, town) and a Submit button.
And now the hard part for me... When I click the button it should save the information typed in above and display them below in a table.

To make it easier, here's an example: http://www.karlova.ee/park/?action=allkirjasta

or

http://karistamatusevastu.rahvuslikliikumine.ee/

or (this is in english)

http://www.petitiononline.com/ringo098/petition-sign.html


If someone could post the code or download link for something like that would be great.

I'd really apprechiate your help.

I'll add rep (over 600 points).
 

Sahataba

"V" Is for Vagina
Staff Alumn
Joined
Sep 8, 2008
Messages
785
Reaction score
3,739
ctrl + u in forefox, and you'll see page code, and there should be solution. i guess.
 

numbersix

Staff Alumn
Staff Alumn
Joined
Oct 16, 2005
Messages
1,144
Reaction score
2,897
Do you want this data saved to a MySQL database so that it is "useable"? Or just to a table (ie: html) for visual purposes?
 

-KA-

Staff Alumn
Joined
Sep 15, 2006
Messages
12,379
Reaction score
40,213
Do you want this data saved to a MySQL database so that it is "useable"? Or just to a table (ie: html) for visual purposes?

Let me quess, if it's saved just to a table then the "saved" information will be lost after I refresh?

I want it to be usable (actually just printable), so MySQL version is needed. But if it's possible to save it just to a table and the saved information remains in it then that would be even better.
 

numbersix

Staff Alumn
Staff Alumn
Joined
Oct 16, 2005
Messages
1,144
Reaction score
2,897
'k, I'll play around with it for you.

Here's what I've got so far:
Code:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
	<title>Form Test</title>
</head>

<body>

<div>
<form method="post" name="petition" action="[COLOR="Red"]http://www.nudecelebforum.com/[/COLOR]">
<table>
<tr>
	<td align="right">First Name: </td>
	<td><input type="text" size="40" name="firstname"></td>
</tr>
<tr>
	<td align="right">Last Name: </td>
	<td><input type="text" size="40" name="lastname"></td>
</tr>
<tr>
	<td align="right">Age: </td>
	<td><input type="text" size="40" name="age"></td>
</tr>
<tr>
	<td align="right">Town: </td>
	<td><input type="text" size="40" name="town"></td>
</tr>
</table>
	<input type="button" value=" Submit " name="send" ONCLICK="javascript:validateForm()">
	<input type="reset" value=" Reset Form " name="reset">
</form>
<script language="JavaScript">
	function validateForm() 
	{
		var okSoFar=true
		with (document.petition)
		{
	if (firstname.value=="" && okSoFar)
		{
		okSoFar=false
		alert("Please enter your first name.")
		firstname.focus()
		}
	if (lastname.value=="" && okSoFar)
		{
		okSoFar=false
		alert("Please enter your last name.")
		lastname.focus()
		}
	if (age.value=="" && okSoFar)
		{
		okSoFar=false
		alert("Please enter your age.")
		age.focus()
		}
	if (town.value=="" && okSoFar)
		{
		okSoFar=false
		alert("Please enter your town.")
		town.focus()
		}
	if (okSoFar==true)  submit();
		}
	}
</script>

</div>

</body>
</html>

I'll try to get the actual action part together later, right now I'm off for the day.
Is that kinda what you had in mind?
 

-KA-

Staff Alumn
Joined
Sep 15, 2006
Messages
12,379
Reaction score
40,213
Yes, that's what I meant, thanks for helping me out :)
 

GrapJ

Balki Bartokamus
Joined
Sep 12, 2006
Messages
1,338
Reaction score
2,540
Looks nice but there is a small error

action="http://www.nudecelebforum.com/"> should read : action="http://www.nudecelebforum.com/some.php">

It is nice to show the html part but the interaction with the database should come from a php (or cgi or whatever) file on the server.
I have those files but it is a lot of work to make it work.
first question : do you have a database and can i get a username and password?
 

numbersix

Staff Alumn
Staff Alumn
Joined
Oct 16, 2005
Messages
1,144
Reaction score
2,897
Oh, I know, it will have to be php (or cgi), but I just threw that together knowing full well it wouldn't do anything.
The "action" part is the tricky part. I've got a php file that I'm trying to rework that does not need a database, instead, it just saves the entries to a text file which is located on the server and reads them from there.
 

numbersix

Staff Alumn
Staff Alumn
Joined
Oct 16, 2005
Messages
1,144
Reaction score
2,897
This may take a while read...

Double posting be damned, this is important :mallet:

Give this a shot:
:arrow: http://www.mediafire.com/?sharekey=fd3a4999704ff36ab94117dade8fc295e04e75f6e8ebb871

It is all PHP and MyMSLQ based so you'll need access to that for it to work.
The files included in the .zip are as follows:
  1. mysql.php - creates a table called "petition" within your MySQL DB with the values: First Name, Last Name, Age, and City
  2. input.php - the form itself
  3. insert.php - takes your form data from input.php and sends it to your newly created MySQL table.
  4. output.php - output of the data from the form/MySQL table
  5. style.css - the name says it all, feel free to customize the look/layout of these pages. This file is straight from one of the websites you had linked earlier so most of what's in it has nothing to do with any of the files above.

To implement this setup you'll need to create a MySQL DB on your server/site. Write down it's host name, DB name, the administrators user name, as well as the administrators password as you'll need these to customize the files provided.

Upload the files to your site once all of the database info has been added and run mysql.php (ie: point your browser to that page). This will create a table within your specified database that will be used later on. From here, kibosh the file for security reasons - it won't be needed again.

I did my best to comment throughout so that it will be easily modified to suit your needs but if you have any questions/concerns feel free to let me know and I'll do my best to sort them out.

Test it out, let me know what you think.
If you have any questions feel free to ask.

Small Print...
There are probably security flaws throughout this as I did my best to get it to you quickly so I take no responsibility for what happens should you actually implement this system.
Basically, use it at your own risk.
 

C0BRA

The Rise of Member
Joined
Jan 31, 2008
Messages
192
Reaction score
340
wow, who'd a thought it. Such great help on a nude forum

teacher01.jpg
 

numbersix

Staff Alumn
Staff Alumn
Joined
Oct 16, 2005
Messages
1,144
Reaction score
2,897
I'd sooner look at boobs than code any day of the week though :headbang:
 

KABOOM

I'm just here for the tits
Staff member
Super Moderator
Joined
Mar 20, 2004
Messages
3,063
Reaction score
11,005
God damn man, that's just a fucking nice thing to do.
 

GrapJ

Balki Bartokamus
Joined
Sep 12, 2006
Messages
1,338
Reaction score
2,540
very well done
btw the files are saved as binary, can you do the same in ascii
again : well done; I nearly placed it on my server.

and -KA- : do you have an own email for personal mail?
 

-KA-

Staff Alumn
Joined
Sep 15, 2006
Messages
12,379
Reaction score
40,213
Thank you so much for your help, numbersix.

But I keep having one problem with insert.php file, it keeps giving me error: Parse error: syntax error, unexpected ';' in .../insert.php on line 15

I ** DEAD LINK REMOVED ** it twice (once version I edited and once version I didn't edit), both ways I get this error

I sent you a PM, if you don't mind.

GrapJ, you can find my email from my profile (MSN address).
 
Last edited:

numbersix

Staff Alumn
Staff Alumn
Joined
Oct 16, 2005
Messages
1,144
Reaction score
2,897
God damn man, that's just a fucking nice thing to do.
Eh, it's winter, I'm out of commission for a while (broken leg), and I'm bored ... had to do something.

very well done
btw the files are saved as binary, can you do the same in ascii
I'm not sure. I don't see why you couldn't.

I sent you a PM, if you don't mind.
Not a problem. Hopefully the reply points you in the right direction.
 

-KA-

Staff Alumn
Joined
Sep 15, 2006
Messages
12,379
Reaction score
40,213
I got it to work..There was a small error in the code. (oh btw...my host is localhost - unbelievable but it is so ;))

Original insert.php. (from line 15)

Code:
echo;
header("Location: output.php");
mysql_close($con)
?>

working code:
Code:
echo
header("Location: output.php");
mysql_close($con);
?>

thanks.gif
 

numbersix

Staff Alumn
Staff Alumn
Joined
Oct 16, 2005
Messages
1,144
Reaction score
2,897
It's funny how it was working fine on my end even with ";"

Anyhoo, you're welcome!

:banana:
 
Top