Skip to content

Instantly share code, notes, and snippets.

View ahmadnaser's full-sized avatar

Ahmad Naser ahmadnaser

View GitHub Profile
@ahmadnaser
ahmadnaser / ! .gitignore
Created September 9, 2023 18:28 — forked from dphurley/! .gitignore
! .gitignore for Express app
# Logs
logs
*.log
# Runtime data
pids
*.pid
*.seed
# Directory for instrumented libs generated by jscoverage/JSCover
rewrite ^(.*)$ /public/$1 break;
location / {
index index.php index.html;
try_files $uri $uri/ /index.php?$args;
}
@ahmadnaser
ahmadnaser / AhmadNaser Responsive WebSite CSS BASE
Created July 23, 2014 10:23
AhmadNaser Responsive WebSite CSS BASE , Desktop , Tablet , Mobile
/*
Theme Name: AhmadNaser Responsive WebSite CSS BASE
Theme URI: http://ahmadnaser.com/
Author: AhmadNaser
*/
/*
=============================================== 01. BASE STYLES (1140px) ===============================================
@ahmadnaser
ahmadnaser / SingleLine.cs
Created December 8, 2015 09:03
How to draw a single Line in c# and Unity
using UnityEngine;
using System.Collections;
public class SingleLine : MonoBehaviour {
public GameObject circlePointPrefab;
public GameObject currentLineRenderer;
public GameObject lineRendererPrefab;
public Material drawingMaterial;
private Vector3 previousPosition,currentPostion;
private bool clickStarted;
@ahmadnaser
ahmadnaser / JS and jQuery learning resources
Created February 19, 2019 19:01 — forked from esergueev/JS and jQuery learning resources
JS and jQuery learning resources
JavaScript learning resources.
Starting point for those, who have already learned JS, but forgotten. Good article. Quite compact.
https://developer.mozilla.org/en/JavaScript/A_re-introduction_to_JavaScript
Question: what's the best learning source on JS. Some answers.
http://stackoverflow.com/questions/11246/best-resources-to-learn-javascript
http://stackoverflow.com/questions/2687566/learning-javascript-in-one-weekend
http://net.tutsplus.com/tutorials/javascript-ajax/the-best-way-to-learn-javascript/
@ahmadnaser
ahmadnaser / MultipleLines.cs
Last active May 20, 2018 21:32
How to draw multiple lines in Unity and c# with different colors
using UnityEngine;
using System.Collections;
public class MultipleLines : MonoBehaviour
{
public GameObject circlePointPrefab;
public GameObject currentLineRenderer;
public GameObject lineRendererPrefab;
public Material drawingMaterial;
private Vector3 previousPosition, currentPostion;
in the end </head> of template folder, go to the selected theme index.php and apply following code
///Developed By Ahmad Naser Turnkey Solutions LLC - Greenbackend.com
///http://greenbackend.com/developer-hosting
///www.greenbackend.com
// www.khottah.com
///greenbackend@ahmadnaser.com
///copyright © 2018 ANTS LLC. All rights reserved.
@ahmadnaser
ahmadnaser / gist:9d11b092477f9415a5b6
Created August 27, 2014 09:39
optimize wordpress performance on the server
wp-config.php ---> define('ENABLE_CACHE', true);
php.ini ---> memory_limit = 6144M
install wp plugin --> w3-total-cache
optimize table in phpmyadmin
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
using UnityEngine.SceneManagement;
public class LoadingScreenManager : MonoBehaviour {
[Header("Loading Visuals")]
public Image loadingIcon;
public Image loadingDoneIcon;
//Shared on Ahmad Naser.com
func PlayAudioInSwift3() {
var player = AVAudioPlayer()
let audioPath = Bundle.main().pathForResource("2-loader", ofType: "mp3")