Skip to content

Instantly share code, notes, and snippets.

✌️
Peace

Amjad amjad

✌️
Peace
Block or report user

Report or block amjad

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@amjad
amjad / json_sync_acf_fields.php
Last active Aug 29, 2019 — forked from superpositif/jp_sync_acf_fields.php
Automatically update Advanced Custom Fields field groups via JSON
View json_sync_acf_fields.php
<?php
/**
*
* Function that will automatically remove ACF field groups via JSON file update
*
*/
function acf_auto_suppr($json_dirs) {
$groups = acf_get_field_groups();
if (empty($groups)) {
@amjad
amjad / SlackClient.cs
Created Feb 5, 2019 — forked from jogleasonjr/SlackClient.cs
A simple C# class to post messages to a Slack channel. You must have the Incoming WebHooks Integration enabled. This class uses the Newtonsoft Json.NET serializer available via NuGet. Scroll down for an example test method and a LinqPad snippet. Enjoy!
View SlackClient.cs
using Newtonsoft.Json;
using System;
using System.Collections.Specialized;
using System.Net;
using System.Text;
//A simple C# class to post messages to a Slack channel
//Note: This class uses the Newtonsoft Json.NET serializer available via NuGet
public class SlackClient
{
@amjad
amjad / OptimizeSqlFile.cs
Created Jun 16, 2018 — forked from jbe2277/OptimizeSqlFile.cs
Convert SQL Compact Edition database file to SQLite database file
View OptimizeSqlFile.cs
// === Convert SQL Compact Edition database file to SQLite database file ===
// Dump SQL Compact Edition data to SQLite compatible SQL file
// - Command line tools: https://github.com/ErikEJ/SqlCeToolbox/wiki/Command-line-tools
// - ExportSQLCE40.exe "Data Source=D:\Northwind.sdf;" Northwind.sql sqlite
// The SQL file created by the SqlCeToolbox contains GUID data as text.
// - Connection string with GUID as text: https://www.connectionstrings.com/sqlite/
// Data Source=c:\mydb.db;Version=3;BinaryGUID=False;
// - Recommended is to store GUID data as binary instead of text (requires less space)
You can’t perform that action at this time.