Skip to content

Instantly share code, notes, and snippets.

View Archie22is's full-sized avatar
💭
I may be slow to respond.

ᴀʀᴄʜɪᴇ ᴍᴀᴋᴜᴡᴀ™ Archie22is

💭
I may be slow to respond.
View GitHub Profile
@Archie22is
Archie22is / gist:10331850
Created April 10, 2014 00:05
One Page Smooth Scrolling Script
$('a[href*=#]:not([href=#])').click(function() {
if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'')
|| location.hostname == this.hostname) {
var target = $(this.hash);
target = target.length ? target : $('[name=' + this.hash.slice(1) +']');
if (target.length) {
$('html,body').animate({
scrollTop: target.offset().top
}, 1000);
@Archie22is
Archie22is / gist:10331912
Created April 10, 2014 00:06
Import / Call Web fonts from Google directly from your CSS
/* Web Fonts @import */
@import url(http://fonts.googleapis.com/css?family=Open+Sans:400italic,800italic,400,800);
@import url(http://fonts.googleapis.com/css?family=Droid+Serif:400,700,400italic,700italic);
@Archie22is
Archie22is / gist:247368a91fe311990fd3
Created May 10, 2014 11:07
Rape Crisis Contact Map Script
<a href="https://www.google.co.za/maps/place/60+Hout+St/@-33.9213455,18.4199708,17z/data=!3m1!4b1!4m2!3m1!1s0x1dcc67669e705a2b:0x4fcb1fb3e4439734" target="_blank"><img src="http://maps.google.com/maps/api/staticmap?center=-33.9213455,18.4199708&zoom=16&size=200x200&maptype=roadmap&sensor=false&language=&markers=color:red|label:none|-33.9213455,18.4199708" title="60 hout lane cape town" width="200" height="200"></a>
@Archie22is
Archie22is / gist:c12157dc1d676254afb9
Created May 14, 2014 15:22
Post Type Layout and a bit of notes.... Source: Unknown
<?php
/// @cond private
/*
* [DRAFT]
*
* THE FOLLOWING CODE IS A DRAFT. FEEL FREE TO USE IT TO MAKE SOME EXPERIMENTS, BUT DO NOT USE IT IN ANY CASE IN
* PRODUCTION ENVIRONMENT. ALL CLASSES AND RELATIVE METHODS BELOW CAN CHNAGE IN THE FUTURE RELEASES.
*
*/

#Techniques for Anti-Aliasing @font-face on Windows

It all started with an email from a client: Do these fonts look funky to you? The title is prickly.

The font in question was Port Lligat Sans from Google Web Fonts.

The "prickly" is aliasing caused by lack of hinting

var map = null;
var marker = null;
var infowindow = new google.maps.InfoWindow({size: new google.maps.Size(150, 50)});
function createMarker(latlng, name, html) {
var contentString = html;
var marker = new google.maps.Marker(
{
position: latlng,
map: map,
<?php
/**
* aheadWorks Co.
*
* NOTICE OF LICENSE
*
* This source file is subject to the EULA
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://ecommerce.aheadworks.com/AW-LICENSE.txt
@Archie22is
Archie22is / functions.php
Last active November 2, 2015 08:30
Hide Pods Admin Menu from non-adminitrators
<?php
// add the following script to your theme functions.php
// Archie22is ---> https://github.com/Archie22is
add_action('admin_menu', 'remove_pods_menu', 11);
function remove_pods_menu () {
get_currentuserinfo() ;
global $user_level;
if ($user_level < 10){
@Archie22is
Archie22is / Scripts.html
Last active November 2, 2015 08:29
Scroll to page
<div id="fixed">
My fixed bar
</div>
<div id="targets">
<div id="target-1">
<a href="#target-2">Jump to target 2</a>
</div>
<div id="target-2">
<a href="#target-3">Jump to target 3</a>
@Archie22is
Archie22is / robots.txt
Last active November 2, 2015 08:29 — forked from chuckreynolds/robots.txt
A WordPress robots.txt by Archie22is ----> https://github.com/Archie22is
User-agent: *
# Directories
Disallow: /cgi-bin/
Disallow: /wp-admin/
Disallow: /trackback/
Disallow: /wp-includes/
Disallow: /comment-page-
Disallow: /wp-content/themes/
Disallow: /wp-content/plugins/
# Files