Home
Softono
b

basemax

Professional software vendor delivering innovative solutions on the Softono platform. Specialized in both open-source and proprietary software development.

Total Products
3

Software by basemax

BrowserFeaturesJs
Open Source

BrowserFeaturesJs

# BrowserFeatures Tiny Library for browser features detection. ![ChangeNumbers.min.js File Size](https://img.shields.io/badge/Compressed%20Size-1.2%20KB-blue.svg) ![ChangeNumbers.min.js Validation Code](https://img.shields.io/badge/Validation%20Code-Check-green.svg) ## Features - Easy - Compact - No dependencies # How to Use? you can access to result of detect and check from variable. type of all variable is `bool`. list of variables : | Variables | Goal | | ------------- | ------------- | | browser.function_generator | | | browser.function_async | | | browser.function_generator_async | | | browser.event_target | | | browser.data_transfer_item | | | browser.data_transfer_item_list | | | browser.broad_cast_channel| | | browser.viewport| | | browser.font | | | browser.custom_element| | | browser.animate| | | browser.svg | | | browser.touch | | | browser.webgl | | ## Samples To view the full details, run the [Example.html](https://github.com/BaseMax/BrowserFeaturesJs/blob/master/Example.html) file. # Example : <script type="text/javascript" src="BrowserFeatures.min.js"></script> <script type="text/javascript"> window.addEventListener("load",function() { document.write("<b>" + "FunctionGenerator" + "</b> : " + browser.function_generator + "<br>"); document.write("<b>" + "FunctionAsync" + "</b> : " + browser.function_async + "<br>"); document.write("<b>" + "FunctionGeneratorAsync" + "</b> : " + browser.function_generator_async + "<br>"); document.write("<b>" + "EventTarget" + "</b> : " + browser.event_target + "<br>"); document.write("<b>" + "DataTransferItem" + "</b> : " + browser.data_transfer_item + "<br>"); document.write("<b>" + "DataTransferItemList" + "</b> : " + browser.data_transfer_item_list + "<br>"); document.write("<b>" + "BroadCastChannel" + "</b> : " + browser.broad_cast_channel + "<br>"); document.write("<b>" + "ViewPort" + "</b> : " + browser.viewport + "<br>"); document.write("<b>" + "Font" + "</b> : " + browser.font + "<br>"); document.write("<b>" + "CustomElement" + "</b> : " + browser.custom_element + "<br>"); document.write("<b>" + "Animate" + "</b> : " + browser.animate + "<br>"); document.write("<b>" + "SVG" + "</b> : " + browser.svg + "<br>"); document.write("<b>" + "Touch" + "</b> : " + browser.touch + "<br>"); document.write("<b>" + "WebGL" + "</b> : " + browser.webgl + "<br>"); }); </script> # Output of Example : FunctionGenerator : true FunctionAsync : true FunctionGeneratorAsync : false EventTarget : true DataTransferItem : true DataTransferItemList : true BroadCastChannel : true ViewPort : false Font : true CustomElement : true Animate : false SVG : true Touch : false WebGL : true *The output may be specific to different browsers and systems.* # License BrowserFeatures is licensed under the [GNU General Public License](https://github.com/BaseMax/BrowserFeaturesJs/blob/master/LICENSE).

JavaScript Libraries & Components Browser Automation
17 Github Stars
BitlyGo
Open Source

BitlyGo

# Bitly Go URL Shortener - Short URLs & Custom Free Link Powered by GoLang and PostgreSQL database. ## Dependencies - Golang 1.18+ - [Tern](https://github.com/jackc/tern) 1.13+ (The SQL Fan's Migrator) ## Getting started - Rename `config.yaml.example` to `config.yaml`, and `tern.conf.example` to `tern.conf`; - Change the database connection info with your own. ### Run without docker ```bash cd cmd/bitlygo/ go run main.go ``` ### Run as a docker container NOTE: Make sure you changed the database connection info in `docker-compose.yaml` file ```bash $ docker-compose build --no-cache $ docker-compose up -d ``` ## Routes ### `GET /` This route will show this README to show the features of the projects to everyone. ### `POST /register` - STRING `username` (required, The minimum length is 4 and maximum length is 88 also does not allow empty username) - STRING `password` (required) This route will make new user if didn't exist Example response: ```json { "username": "john", "api_key": "abcd-efgh-ijkl-mnop-124v-852a" } ``` OR ```json { "status": false, "message": "Error message" } ``` ### `POST /login` - STRING `username` (required) - STRING `password` (required) This route will log into user account if exists Example response: ```json { "status": true } ``` OR ```json { "status": false, "message": "Error message" } ``` ### `GET /search` - STRING `q` (required, The minimum length is 1 and does not allow empty queries also we will trim the value to make it ready to search) We will remove and skip all non-English and non-Digits characters and after that, if `q` is not empty we will search and fetch the results. Otherwise, throw an error! - POSITIVE INT `limit` (default is 10, Minimum value is 1 and Maximum is 100. Otherwise, throw an error!) Example response: ```json { "status": true, "items": { "google": "https://google.com", "facebook": "https://fb.com/?from_my_site", "telegram": "https://t.me/" } } ``` OR ```json { "status": false, "error": "Error message" } ``` ### `GET /top` - POSITIVE INT `limit` (default is 10, Minimum value is 1 and Maximum is 100. Otherwise, throw an error!) Example response: ```json { "status": true, "items": [ { "name": "google", "link": "https://google.com", "visits": 300 }, { "name": "github", "link": "https://github.com/test", "visits": 255 }, { "name": "fb", "link": "https://fb.com", "visits": 200 } ] } ``` OR ```json { "status": false, "error": "Error message" } ``` ### `GET /expire-soon` - POSITIVE INT `limit` (default is 10, Minimum value is 1 and Maximum is 100. Otherwise, throw an error!) Example response: ```json { "status": true, "items": { "google": "https://google.com", "facebook": "https://fb.com/?from_my_site", "telegram": "https://t.me/" } } ``` OR ```json { "status": false, "error": "Error message" } ``` ### `POST /add` or `POST /add/` - STRING `name` (optional, If not defined, we will generate a short and unique random name) - STRING `link` (required, and we will check the link should be valid and pass URL standard format) About link value: we must support **UTF-8** characters or query values. If you send `API-KEY` in the headers, your short link will be alive for ever, otherwise, all links you are creating will only live for 2 days. It should be nice to easily config this limitation inside the source. Note: you cannot create a duplicate name and It should throw an error. But it's okay to store the same link in different names. ### `POST /:name` or `POST /:name/` - STRING `link` (required, and we will check the link should be valid and pass URL standard format) About link value: we must support **UTF-8** characters or query values. If you send `API-KEY` in the headers, your short link will be alive for ever, otherwise, all links you are creating will only live for 2 days. It should be nice to easily config this limitation inside the source. Note: you cannot create a duplicate name and It should throw an error. But it's okay to store the same link in different names. ### `GET /:name` If the name is available on the databases. we will redirect the clients to the target URL. 301 redirect is fine. Otherwise, we should alert that is a 404 (HTTP Status) route and display a 404 warning. ### `UPDATE /:name` - STRING `new_name` (optional) - STRING `link` (required, and we will check the link should be valid and pass URL standard format) About link value: we must support **UTF-8** characters or query values. You can only update a link created by an API-KEY. So if the owner of that link is same as your API-KEY, you are allowed to update that. Note: you cannot change the name, you only can change the link value and link that to another new URL. ### `DELETE /:name` or `DELETE /:name/` You can only delete links created by an API-KEY. So if the owner of that link is same as your API-KEY, you are allowed to delete. Example response: ```json { "status": true } ``` OR ```json { "status": false, "error": "Sorry, no permission" } ``` **Important NOTE:** Note that `search`, `add`, `expire-soon`, and `top` are not allowed for names and we should make sure it's not allowed to create such names. since they are already reserved in the router. The **minimum** allowed name length is 4 and the **maximum** is 25. The name can only contain English and numeric characters. Any other character is ignored. ## Database It's okay to use **PostgreSQL** or **MariaDB**. Note: since this project supports short lifetime links, we can use other databases too. but it's possible to use SQL and delete old rows. ## Authors - Its Joniur - Max Base

Link Shortening & Tracking
11 Github Stars
OnlineMarketplacePHP
Open Source

OnlineMarketplacePHP

# Online Marketplace PHP An online marketplace that allows users to buy and sell products. Users can register for an account, browse products, add products to their cart, and checkout using a payment gateway. Sellers can create and manage their own product listings, including setting the price, description, and uploading product images. Admins can manage user accounts, product listings, and orders. ## Requirements - User registration and login with password hashing - User roles: **buyer**, **seller**, and **admin** - Sellers can create and manage their own product listings - Product listings include title, description, price, category, and images - Users can browse products by category and search for products by keyword - Users can add products to their cart and checkout using a payment gateway (e.g., PayPal) - Orders are tracked and stored in a database - Admins can manage user accounts, product listings, and orders - Proper use of security measures, such as input validation, SQL injection prevention, and CSRF protection - Efficient use of caching mechanisms, such as Redis or Memcached, to improve performance - Use of an MVC architecture (Not Laravel or CodeIgniter) ## API Routes ### Authentication: - `POST /api/login`: Authenticate user and generate access token ```console { "JWT_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c", "email": "[email protected]", "password": "$2y$10$ChXlwPFkN6U/YCTQikrYeu4pRlxx6ZLe.mj0mKwkQC/UJLjfYMsZa" } ``` - `POST /api/register`: Register a new user account ```console { "id": 1, "name": "ali", "email": "[email protected]", "password": "$2y$10$ChXlwPFkN6U/YCTQikrYeu4pRlxx6ZLe.mj0mKwkQC/UJLjfYMsZa", "remember_token": "sskjdh2fudn1" } ``` ### Products: - `GET /api/products`: Retrieve all products - `GET /api/products/{id}`: Retrieve a specific product by ID - `POST /api/products`: Create a new product listing - `PUT /api/products/{id}`: Update a product listing - `DELETE /api/products/{id}`: Delete a product listing ### Orders: - `GET /api/orders`: Retrieve all orders - `GET /api/orders/{id}`: Retrieve a specific order by ID - `POST /api/orders`: Create a new order - `PUT /api/orders/{id}`: Update an existing order - `DELETE /api/orders/{id}`: Delete an order ### Users: - `GET /api/users`: Retrieve all users - `GET /api/users/{id}`: Retrieve a specific user by ID - `PUT /api/users/{id}`: Update a user account - `DELETE /api/users/{id}`: Delete a user account ### Categories: - `GET /api/categories`: Retrieve all categories - `GET /api/categories/{id}`: Retrieve a specific category by ID - `POST /api/categories`: Create a new category - `PUT /api/categories/{id}`: Update a category - `DELETE /api/categories/{id}`: Delete a category ### Payments: - `POST /api/payments`: Process payment using payment gateway (With a good structure that allows us to add more gateways in the future) Example Response: ```console { "payment_uri": "https://nextpay.org/nx/gateway/payment/267a5387-af3a-4063-8d41-87df73f38f60", "trans_id": "267a5387-af3a-4063-8d41-87df73f38f60" } ``` Note: This is just an example, and you may need to modify the routes and methods based on the specific requirements. ## Database Schema ### Users - `id`: int (primary key) - `name`: varchar(255) - `email`: varchar(255) - `password`: varchar(255) - `remember_token`: varchar(100) - `role`: enum('buyer', 'seller', 'admin') - `created_at`: timestamp - `updated_at`: timestamp ### Categories - `id`: int (primary key) - `name`: varchar(255) - `created_at`: timestamp - `updated_at`: timestamp ### Products - `id`: int (primary key) - `title`: varchar(255) - `description`: text - `price`: decimal(8,2) - `category_id`: int (foreign key to Categories table) - `seller_id`: int (foreign key to Users table) - `created_at`: timestamp - `updated_at`: timestamp ### Orders - `id`: int (primary key) - `buyer_id`: int (foreign key to Users table) - `product_id`: int (foreign key to Products table) - `quantity`: int - `amount`: decimal(8,2) - `status`: enum('pending', 'completed', 'cancelled') - `created_at`: timestamp - `updated_at`: timestamp ### Payments - `id`: int (primary key) - `order_id`: int (foreign key to Orders table) - `amount`: decimal(8,2) - `status`: enum('pending', 'completed', 'failed') - `payment_gateway`: varchar(255) - `transaction_id`: varchar(255) - `created_at`: timestamp - `updated_at`: timestamp ## Evaluation Criteria - Correctness and completeness of the implementation - Efficient use of caching mechanisms - Proper use of security measures - Clean and maintainable code - Proper use of error handling and logging - Good coding practices, such as adherence to coding standards and proper documentation ## Installation First step, You need to clone this repository from GitHub to your local environment: ```console git clone https://github.com/BaseMax/OnlineMarketplacePHP.git ``` Now you must run some command to install dependecies and create .env file: ```console composer install ``` ```console cp .env.example .env ``` Now open `.env` file and fill the things that are needed. Navigate to `public` folder and run below command to start serving on the localhost: ```console php -S localhost:5000 ``` ## Authors - Ali Ahmadi - Max Base Copyright 2023, Max Base

Marketplace & Multi-vendor Digital Product Sales
13 Github Stars