| | #1 |
| Success Feels Good War Room Member Join Date: 2005
Posts: 395
Thanks: 69
Thanked 108 Times in 63 Posts
|
Is there way to dynamically display content on a page based on content in the URL? For example, say the URL is www.site.com/12345. If someone clicks that link, can you make the "12345" show up somewhere on the page - dynamically displaying whatever content comes after the forward slash? Brandon |
| |
| | #2 |
| Success Feels Good War Room Member Join Date: 2005
Posts: 395
Thanks: 69
Thanked 108 Times in 63 Posts
|
Nevermind, I found how to do it. Just in case anyone else has this question, I found the answer here: Creating Dynamic Pages with php Using the GET Function Very simple. Brandon |
| |
| | #3 |
| Peaceful Warrior War Room Member Join Date: 2009 Location: Calgary
Posts: 277
Thanks: 16
Thanked 106 Times in 63 Posts
|
Yup, that's the basics right there. www.site.com/?number=1234 will be accessible by $_GET['number'] Just so you know, it is also possible to get the same result using a "pretty" link like www.site.com/1234 and still be able to access the value. That uses something called ReWrite Rules. Many CMS systems such as Wordpress rely on it to make their nicely formatted URLs. -Ryan |
| FREE WSO: Protect and Automatically Deliver Your Digital Products Ask the Internet Marketing Geek <-- Happy to help with technical challenges MiniSiteMaker.org <-- Free software to make your mini-sites fast and easy | |
| |
| The Following User Says Thank You to theIMgeek For This Useful Post: |
| | #4 |
| Success Feels Good War Room Member Join Date: 2005
Posts: 395
Thanks: 69
Thanked 108 Times in 63 Posts
|
Thanks Ryan, especially for the ReWrite Rule tip. Brandon |
| |
| | #5 | |
| WebNinja Join Date: 2010 Location: Atlanta GA
Posts: 444
Thanks: 19
Thanked 54 Times in 34 Posts
|
| |
| |
|
| Bookmarks |
| Tags |
| content, display, dynamically, url |
| |