473,395 Members | 1,456 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

How to Use SEO URLS for Simple GET Form

59
Hi
I am trying to make a simple get form that asks the user to enter their name and then it returns their name on the next page, i have managed to do this but now i would like to have nice clean SEO Urls insted of the ugly get urls. How do i make do this?

I am currently doing:
Index.php
Expand|Select|Wrap|Line Numbers
  1. <html>
  2. <form action="welcome.php" method="get">
  3. Name: <input type="text" name="name" />
  4.  
  5. <input type="submit" />
  6. </form>
  7. </html>
and

welcome.php
Expand|Select|Wrap|Line Numbers
  1. <html>
  2. Welcome <?php echo $_GET["name"]; ?>.<br />
  3.  
  4.  
  5. </html>
So my question is how to make this have clean urls such as domain.com/'search-phrase'?

Thanks
Oct 5 '08 #1
6 3356
bnashenas1984
258 100+
Hi
Why don't you use POST instead of GET to hide your variables?
Then there will be nothing shown in the URL
Oct 5 '08 #2
pbmods
5,821 Expert 4TB
Heya, ojsimon.

Look into using mod_rewrite to do this.
Oct 5 '08 #3
Markus
6,050 Expert 4TB
Hey there.

Check out this tutorial on 'pretty urls'.

Markus.
Oct 5 '08 #4
ojsimon
59
yeh i know about mod rewrite but i am struggling to implement it into my situation. Can anyone help me?

Thanks
Oct 6 '08 #5
pbmods
5,821 Expert 4TB
I'll go ahead and move this to the Apache forum to see if we can get some more Experts in on this.
Oct 6 '08 #6
ojsimon
59
thanks for that mod, sorry i didnt realise there was one.
Anyone able to help?

Thanks
Oct 7 '08 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: DM | last post by:
I'm working on a site with more than 1700 HTML files. We'll be moving files around on this site a lot because we're reorganizing it. I'm thinking of writing a script that will convert all URLs in...
3
by: Philip Herlihy | last post by:
I'm using a number of hyperlinks on an Intranet I'm developing which refer to documents on a network server. The URLs I'm using have the form: file://<server>/<path>/<file>.pdf <server> is an...
1
by: Michael Ferrier | last post by:
Hi, I've used fopen() extensively to open web pages. I've found that there is a small minority of web pages that open fine in a browser, but are inaccessible using fopen(). Here are two such...
7
by: AES | last post by:
Encountered a URL containing a comma the other day -- the first time I've ever noticed that, so far as I can recall. It worked fine, however, and I gather commas are legal in URLs. Out of...
10
by: tom | last post by:
hi group, i desperately need a function that will transform relative URLs to absolute URLs in the SRC part of <img> tags. ie: function makeAbsolute($html,$basehref) { //if regex match =...
10
by: jflash | last post by:
Hello all, I feel dumb having to ask this question in the first place, but I just can not figure it out. I am wanting to set my site up using dynamic urls (I'm assuming that's what they're...
2
by: Simon Wigzell | last post by:
I have inherited a database driven website that comes with a table of image links. The images are scattered all of the internet and there are thousands of them. I would like to write an asp script...
8
by: Bruno Rafael Moreira de Barros | last post by:
I have this framework I'm building in PHP, and it has Search Engine Friendly URLs, with site.com/controller/page/args... And on my View files, I have <?=$this->baseURL;?to print the base URL on the...
4
by: Guy Macon | last post by:
As a personal learning experience with limited practical use, I have been doing some experiments with using .htaccess to redirect mis-typed URLs to a preferred canonical form. I have set up a...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.