Skip to content

Instantly share code, notes, and snippets.

NES RAM map

CPU Memory

NES Mega Man 5

  • $00B0: M. Buster - 00 to 9C (max)
  • $00BD: Number of E energy tanks - 80 to 89
  • $00BE: Number of M - 80 to 89
  • $00BF: Number of lives - 00 to 09
@odan
odan / Program.md
Last active January 10, 2023 15:07
MySqlMigrationSqlGenerator Example

MySqlMigrationSqlGenerator Example

dotnet add package MySql.Data.EntityFramework
using System.Configuration;
using System.Data;
using System.Data.Common;
@odan
odan / twitter-images.md
Last active March 25, 2023 11:26
Twitter images

Twitter Images (2020)

  • Header photo: 1500 x 500 px

  • Profile photo: 400 x 400 px

  • Tweet image: Recommended: 1200 x 628

  • Image types include: JPG, GIF or PNG.

Source

@odan
odan / splitting-pdf.md
Last active March 25, 2023 11:26
Spliting a PDF file into multiple PDF files

Spliting a PDF file into multiple PDF files

This function extracts all of the pages from a larger PDF file into single-page PDF files.

Installation

composer require setasign/fpdi-fpdf
@odan
odan / aspnet-core-2-ubuntu-setup.md
Last active March 25, 2023 11:26
Installing ASP.NET Core 2.1 on Ubuntu 18.4 Linux

Remove HTML tags

<?php

$html = '<div class="cc">
    Explore the use of simple 
    <a class="keyword_w_elaboration">technologies</a>
    <div class="elaboration" style="text-decoration:none">
 
<?php
use PhpOffice\PhpSpreadsheet\Cell\Coordinate;
use PhpOffice\PhpSpreadsheet\Reader\Xlsx;
/**
* ExcelFileReader.
*/
class ExcelFileReader
{
@odan
odan / mocking-interface-phpunit.md
Last active March 29, 2023 12:32
Mocking Interfaces with PHPUnit

Mocking Interfaces with PHPUnit

Using the MockBuilder

To mock an interface with PHPUnit we have to pass all methods of the given Interface.

 $reflection = new \ReflectionClass(UserRepositoryInterface::class);

$methods = [];
@odan
odan / xmapp-replacing-mariadb-with-mysql.md
Last active June 4, 2023 19:44
XAMPP - Replacing MariaDB with MySQL

XAMPP - Replacing MariaDB with MySQL

This post has been deleted.