This is a simple web-based application that identifies the Moroccan region for a given CNIE. Users can input a CNIE, and the system will determine the region based on predefined prefixes for regions codes.
CNIE: Carte Nationale d'Identité Electronique
- The user enters a CNIE in the input field (e.g.,
XX00000
). - The application extracts the first two digits.
- It compares the extracted prefix against predefined mappings for each region:
- Rabat:
A, AA, AC, AJ ...
- Casablanca:
B, BA, BB, BE, BH, BJ, BK, BL, BM, BF, BV, BW ...
- Marrakesh:
E, EE ...
- Rabat:
- The region name is displayed.
- Clone the repository:
git clone https://github.com/taher_el_mehdi/moroccan-cnie-region-finder.git
- Open the
index.html
file in a web browser. - Enter a valid Moroccan CNIE to identify the region.
You can try the application here.
Contributions are welcome! Follow these steps to contribute:
- Fork the repository.
- Create a new branch:
git checkout -b feature-name
- Commit your changes:
git commit -m "Add new feature"
- Push the branch:
git push origin feature-name
- Open a pull request.
This project is open source and available under the MIT License.
For questions or suggestions, feel free to contact me.