• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.
  • The forums have been upgraded with support for dark mode. By default it will follow the setting on your system/browser. You may override it by scrolling to the end of the page and clicking the gears icon.

PHP homework

Joined
Dec 2, 2009
Messages
3,353 (0.59/day)
System Name Dark Stealth
Processor Ryzen 5 5600x
Motherboard Gigabyte B450M Gaming rev 1.0
Cooling Snowman, arctic p12 x2 fans
Memory 16x2 DDR4 Corsair Dominator Pro
Video Card(s) 3080 10gb
Storage 2TB NVME PCIE 4.0 Crucial P3 Plus, 1TB Crucial MX500 SSD, 4TB WD RED HDD
Display(s) HP Omen 34c (34" monitor 3440x1440 165Hz VA panel)
Case Zalman S2
Power Supply Corsair 750TX
Mouse Logitech pro superlight, mx mouse s3, Razer Basiliskx with battery
Keyboard Custom mechanical keyboard tm680
Software Windows 11
Benchmark Scores 70-80 fps 3440x1440 on cyberpunk 2077 max settings
Hi all guys!
I got a new homework about php, but simply i don't know how it is done! :confused:
I got stuck at some point:
we should make a button which opens a page for the people who choose "adult" in radiobutton
and one other page for the people who choose "infant".
Anyone can help me?
 
i would google it if it was me..always worked for me in the past when i needed to know how to do something in whatever language i was working on.... find a few code snippets and go from there.... never done php so i had to google it to find a few code examples to get an idea.. doesn't look too terribly difficult...
 
you make a web page with a form on it that has your input elements, submit the form to a php page where you take the input from $_GET or $_POST and do the right thing
 
I know $_GET and post, but it is another webpage :(
It means if $_GET=="female.com"?? else $_GET=="male.com"?
 
read up on html forms.

when a form is submitted, it sends the form data to an url specified in the <form> tag. make that a php page and your php script sees the form input in either $_GET or $_POST depending on "method" in <form>

all this is documented pretty well, just need to read
 
Back
Top