Skip to content

Instantly share code, notes, and snippets.

View necenzurat's full-sized avatar
🥺
I still hate JS

Costin Moise necenzurat

🥺
I still hate JS
View GitHub Profile
# This is the main Apache server configuration file. It contains the
# configuration directives that give the server its instructions.
# See http://httpd.apache.org/docs/2.2/ for detailed information about
# the directives and /usr/share/doc/apache2-common/README.Debian.gz about
# Debian specific hints.
#
#
# Summary of how the Apache 2 configuration works in Debian:
# The Apache 2 web server configuration in Debian is quite different to
# upstream's suggested way to configure the web server. This is because Debian's

Setting up a SSL Cert from Comodo

I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.

These are the steps I went through to set up an SSL cert.

Purchase the cert

<?php
/*replace https uris for facebook, fuck facebook */
function https_to_http(){
$str = preg_replace('#^https?://#', '', get_permalink() );
return "http://".$str;
}
@necenzurat
necenzurat / clean.php
Created December 23, 2014 16:15
Wordpressez fuckedz
<?php
$meh = array(
"/example.com/public/wp-content/plugins/revslider/inc_php/framework/settings_advances.class.php",
);
function clean($filename) {
$file = file($filename);
<?php
/**
* Class to improve the seo of the site
*
* @package OC
* @category SEO
* @author Chema <chema@open-classifieds.com>
* @version 1.0
* @date 21-02-2014
* @url http://garridodiaz.com/phpseo/
@necenzurat
necenzurat / gist:106089093daaba785b0a
Last active August 29, 2015 14:19
căcatul Oanei, no 2
<?php
/*
1. https://graph.facebook.com/949954348389919
2. https://graph.facebook.com/950516285000392
3. https://graph.facebook.com/951077058277648
*/
$post_id = "949954348389919";
var page = require('webpage').create();
page.onConsoleMessage = function(msg) {
console.log(msg);
};
page.open("http://www.dauanunt.ro/cont/login", function(status) {
if ( status === "success" ) {
page.evaluate(function() {
{"location": "26.1037194, 44.4288612"},
{"location": "26.1040413, 44.4279724"},
{"location": "26.1040198, 44.4274668"},
{"location": "26.1041271, 44.4261796"},
{"location": "26.1041057, 44.4257965"},
{"location": "26.1036336, 44.4258118"},
{"location": "26.1018526, 44.4258884"},
{"location": "26.1011445, 44.4259957"},
{"location": "26.1009299, 44.4261796"},
{"location": "26.1009514, 44.4267465"},
### Keybase proof
I hereby claim:
* I am necenzurat on github.
* I am nece (https://keybase.io/nece) on keybase.
* I have a public key whose fingerprint is 6FFD 4432 2020 D4E4 14DF BD9E 6E0C 7AD6 5971 F4D0
To claim this, I am signing this object:
@necenzurat
necenzurat / code.php
Created September 25, 2017 21:50
code
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use \App\Friend;
use \App\Presence;
use \DB;
use \Carbon;