Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6073305
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T10:15:24+00:00 2026-05-23T10:15:24+00:00

I am fairly new to PHP, as I mostly skilled in the front end

  • 0

I am fairly new to PHP, as I mostly skilled in the front end aspects of the web, but I have to create a form for a House Maid service in which you enter your zip code, and it would determine if you’re within their service area. I thought about using Google’s map API, but fear that would over complicate the service area of about 25 miles(i.e. Half of “smalltownville” is serviced while the other half isn’t wouldn’t pan out well due to the word of mouth aspect of the industry). So I thought it would be best to keep it to the zip codes. I can’t seem to get this to work, although I am pretty sure the syntax is correct. Any help would be greatly appreciated.

Here is the code I have so far:

<form method="post" action="zip-code.php">
  Zip Code: <input name="zip" type="text" /><br />
  <input type="submit" />
</form>

and the PHP:

<?php
  $zip = $_REQUEST['zipcode'] ;
  $zipcode=("z");
    if ($z=="1")
        echo "You are serviced by branch 1!";
    elseif ($z=="2")
        echo "You are serviced by branch 2!";
    else
        echo "You are not serviced.";
?>

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T10:15:24+00:00Added an answer on May 23, 2026 at 10:15 am
    <?php
    $zip = $_REQUEST['zip'] ;
    if ($zip=="1")
        echo "You are serviced by branch 1!";
    elseif ($zip=="2")
        echo "You are serviced by branch 2!";
    else
        echo "You are not serviced.";
    ?>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am fairly new to web programming, I have mainly used java to create
I am fairly new to php but I have an index file in my
I'm fairly new to PHP and have built a medium sized website using standard
I'm fairly new to HTML, PHP, CSS and Javascript. I do have a bit
I'm trying to parse a quite large XML-sheet with PHP, but I'm fairly new
I am fairly new to php and have not figured out how I would
I'm fairly new to PHP so I have a small problem as I'm learning:
Notes: I'm still fairly new to php This login form seems to work perfectly
Fairly new to PHP but in the middle of building an admin panel for
i'll try my best to explain the situation but i'm fairly new to php

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.