Flash Games

 FAQ   Search   Members   Groups   Register  User Control Panel      Login 

Your time now:
Mon Nov 23, 2009 8:14 am

All times are UTC + 1 hour




Post new topic Reply to topic  [ 26 posts ]  Go to page 1, 2  Next Bookmark and Share
Author Message
 Post subject: Text Box that changes current URL
PostPosted: Wed Jul 18, 2007 4:39 pm 
Offline

Joined: Wed Jul 18, 2007 4:30 pm
Posts: 13
I know just about nothing of HTML. Last night, I was trying for hours to make a text box that when you type something and hit submit, it changes the current url to ____.com/(whatever you typed).html

My code looks like this:
<FORM ACTION="">
Your Answer: <INPUT answer="">
<input type="image" name="submit" src="http://www.idiotsguidetowebmarketing.com/images/cool_arrow_v.gif" />
</FORM>

Whenever someone types something in, it tacks on ?=(what was typed in) to the end of the web address. I am not allowed to have ? or = in the address. How do I get it to say (answer).html. When I put ".html" after form action, it just adds .html?=(what was typed in)

Please help, I hardly know anything about HTML


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 18, 2007 10:46 pm 
Offline
500+ Club
User avatar

Joined: Thu Jan 25, 2007 2:10 pm
Posts: 691
Location: Midlands, England
You would need to use somthing else, e.g. javascript. you would need to change the form submit button to:
Code:
<input type="image" name="submit" onClick="Change()"


You will need to have a quick look at javascript but it should be fairly straight forward.

Flabby Rabbit

_________________
http://www.hackthis.co.uk


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 21, 2007 4:36 am 
Offline

Joined: Wed Jul 18, 2007 4:30 pm
Posts: 13
I've been trying for soo long. What goes in Change()? How do I just make it redirect to whatever was put into the box?


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 21, 2007 8:31 pm 
Offline
500+ Club
User avatar

Joined: Thu Jan 25, 2007 2:10 pm
Posts: 691
Location: Midlands, England
you could put what ever you wanted in the onClick property. It will have to link to a javascript function. Google for a peice of javascript code that will redirect the page. Then when you click the button you want it to perform the peice of javascript, so will need to be linked to the function.

I will write you some code as soon as i can, then i will post it for you.

Flabby Rabbit

_________________
http://www.hackthis.co.uk


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jul 22, 2007 11:15 am 
Offline
50+ Club

Joined: Wed Jun 20, 2007 1:51 am
Posts: 91
Location: Australia
kame, try this for your form:
Code:
<form name="frmUrl" method="post" action="url.pl">
Your url: <input type="text" name="txtUrl">
<input type="image" src="manual.jpg" name="submit">
</form>

thats the form (basically) if you need help with the perl program ill post it for you if you like

_________________
I put everything down to this: EWIT (Everything Works In Theory)


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 23, 2007 7:18 pm 
Offline

Joined: Wed Jul 18, 2007 4:30 pm
Posts: 13
Cool! Now it changes the end to just "url.pl" and no more ? or =! I just need to know how to make whatever you typed appear in the url. I thought it was ('txturl'), but that isn't working.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 24, 2007 12:37 pm 
Offline
50+ Club

Joined: Wed Jun 20, 2007 1:51 am
Posts: 91
Location: Australia
ok what we need to do now is make the Perl script (url.pl)

ill post what you need...

Code:
#!/usr/bin/perl -T
# url.pl
# Anthony Gilbert (AKA DDragon)

use CGI ':standard';

my $address, $url;

$address = param('txtUrl');
$url = "http://www." . $address . ".com";

print "Location: $url\n\n";


with this code place it in the cgi-bin directory on your webserver and make sure that before you paste and save the file that the 'txtUrl' matches the exact way it is typed here:
Code:
<form name="frmUrl" method="post" action="url.pl">
Your url: <input type="text" name="txtUrl">
<input type="image" src="manual.jpg" name="submit">
</form>

_________________
I put everything down to this: EWIT (Everything Works In Theory)


Last edited by DDragon on Sun Aug 05, 2007 8:57 am, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 24, 2007 4:00 pm 
Offline

Joined: Wed Jul 18, 2007 4:30 pm
Posts: 13
I copied that both codes and put them in the proper places exactly as you had shown, but it still does url.pl. Am I supposed to customize things in the perl script? I pasted it into a blank file in cgi-bin and named it url.pl.

I hardly know anything about scripting, thank you for being patient.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 28, 2007 4:32 pm 
Offline
50+ Club

Joined: Wed Jun 20, 2007 1:51 am
Posts: 91
Location: Australia
ok have you got this up on a webserver or is it a local site (ie do you use WAMP or something like it to look at your site on your computer?)

_________________
I put everything down to this: EWIT (Everything Works In Theory)


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jul 29, 2007 3:03 am 
Offline

Joined: Wed Jul 18, 2007 4:30 pm
Posts: 13
I don't know. Is filemanager a method? It's tripod.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jul 29, 2007 9:04 am 
Offline
50+ Club

Joined: Wed Jun 20, 2007 1:51 am
Posts: 91
Location: Australia
ok so you have a webhost. what is the address of your site? ill be able to take a look at it then

_________________
I put everything down to this: EWIT (Everything Works In Theory)


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jul 29, 2007 4:41 pm 
Offline

Joined: Wed Jul 18, 2007 4:30 pm
Posts: 13
http://radiumpuzzle.tripod.com


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 30, 2007 1:25 pm 
Offline
50+ Club

Joined: Wed Jun 20, 2007 1:51 am
Posts: 91
Location: Australia
when you edit your site do you use an FTP program like FileZilla, or do you use the tripod file manager page?

_________________
I put everything down to this: EWIT (Everything Works In Theory)


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 30, 2007 4:28 pm 
Offline

Joined: Wed Jul 18, 2007 4:30 pm
Posts: 13
Either the tripod file manager page, or the way where you just click an edit button and it lets you type something right onto the page.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 01, 2007 10:23 am 
Offline
50+ Club

Joined: Wed Jun 20, 2007 1:51 am
Posts: 91
Location: Australia
I took a look at your pages code and as far as i can tell there is not form, without the form the perl script wont work place the text box in the form i made for you and then try it...

Edit: i was looking through my own archive of scripts and such and found one that you might benifit from.. its a piece of JavaScript that i wrote ages ago ill post it for you when i relocate it

_________________
I put everything down to this: EWIT (Everything Works In Theory)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 26 posts ]  Go to page 1, 2  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group - Flash Games - TNX Invitation Code - TNX Review


Webmaster - Excruciating - Johnathan - Kotik - Ash - Tomi - rangana - Phate - dflynn - Medley