HS Banner
HS Codebank Articles
Page 1 of 2

Add a new item to an array, it can be inserted with the help of array_splice() a function of PHP. 09/09/2023

Description:

This function removes a portion of an array and replaces it with something else. If offset and length are such that nothing is removed, then the elements from the replacement array are inserted in the place specified by the offset.

Author: Admin
Language: PHP
Tags: array php insert array_splice
Read More182

Use Sockets to send and receive data over TCP 05/07/2023

Description:

When working with System.Net.Sockets, you represent a network endpoint as an IPEndPoint object. The IPEndPoint is constructed with an IPAddress and its corresponding port number. Before you can initiate a conversation through a Socket, you create a data pipe between your app and the remote destination.

Author: Admin
Language: C#
Tags: sockets send receive tcp cs
Read More398

Unique Random Numbers Within a Range 04/23/2023

Description:

Here's a nice function I found to get 10 unique numbers from a range of numbers.

Author: Admin
Language: PHP
Tags: random numbers range php
Read More202



PHP Shuffle 09/11/2022

Description:

Randomizes the order of the elements in an array.

Author: Admin
Language: PHP
Tags: php shuffle array
Read More481

List All Files in a Directory Using PHP 04/05/2022

Description:

In PHP there are several ways to get a list of files in a PHP application.

Author: Admin
Language: PHP
Tags: list files directory php glob scandir opendir readdir closedir filesystemiterator
Read More430

Bad Word Filter 02/26/2022

Description:

Here's a filter you can use to remove bad words from user submitted data.

Author: Admin
Language: PHP
Tags: php bad word filter
Read More317

PHP whois lookup Class 12/05/2021

Description:

This is a standalone php class to find whois information of a domain or IP.

Author: Guitarman
Language: PHP
Tags: php
Read More461



TcpClient Class 04/01/2021

Description:

This is a class I've used on a network chat program I built.

Author: Guitarman
Language: C#
Tags:
Read More291

Find missing numbers in a sequence. 03/29/2021

Description:

Returns the missing numbers in a sequence.

Author: Admin
Language: Visual Basic .NET
Tags:
Read More354

Get Json String From URL 03/25/2021

Description:

Get Json string from url and convert to DataTable.

Author: Admin
Language: JSON
Tags:
Read More317