Skip to content

Instantly share code, notes, and snippets.

View afidegnum's full-sized avatar

KOKOU AFIDEGNON afidegnum

  • FlashTHub
View GitHub Profile
@afidegnum
afidegnum / index.html
Created June 8, 2019 09:07
Practice: HTML/CSS Layout
<body>
<div id="wrapper">
<div id="header">
<h1>Logo</h1>
<div id="nav">
<ul>
<li><a href="">Home</a></li>
<li><a href="">Products</a></li>
<li><a href="">Services</a></li>
<li><a href="">About</a></li>
cjPath := "cj_items"
files, err := ioutil.ReadDir(cjPath)
if err != nil {
log.Fatal(err)
}
for _, f := range files {
if filepath.Ext(f) == ".txt" {
@afidegnum
afidegnum / recursive.sql
Created August 11, 2017 17:43
link tree and related table
I have 2 tables.
category and products. [from google product](https://www.google.com/basepages/producttype/taxonomy.en-US.txt) taxonomy tree i was able to reconstruct the entire tree.
i have the following tables,
```
CREATE TABLE public.category
(
id integer NOT NULL DEFAULT nextval('category_id_seq'::regclass),
@afidegnum
afidegnum / recursive.sql
Created August 11, 2017 17:43
link tree and related table
I have 2 tables.
category and products. [from google product](https://www.google.com/basepages/producttype/taxonomy.en-US.txt) taxonomy tree i was able to reconstruct the entire tree.
i have the following tables,
```
CREATE TABLE public.category
(
id integer NOT NULL DEFAULT nextval('category_id_seq'::regclass),
@afidegnum
afidegnum / colors.py
Created August 3, 2017 07:28
Fectching Category and Colors
/home/afidegnum/fab/bin/python2.7 /home/afidegnum/Downloads/pycharm-2017.1.5/helpers/pydev/pydevconsole.py 35825 37077
PyDev console: starting.
import sys; print('Python %s on %s' % (sys.version, sys.platform))
sys.path.extend(['/home/afidegnum/PycharmProjects/ladiespage'])
Python 2.7.12 (default, Nov 19 2016, 06:48:10)
[GCC 5.4.0 20160609] on linux2
>>> from app.models import Color
/home/afidegnum/fab/local/lib/python2.7/site-packages/flask_sqlalchemy/__init__.py:800: UserWarning: SQLALCHEMY_TRACK_MODIFICATIONS adds significant overhead and will be disabled by default in the future. Set it to True to suppress this warning.
@afidegnum
afidegnum / myfab_.gitignore
Created June 13, 2017 08:21
sample application using FAB but has few errors i m trying to fix
*.pyc
app.db
./tmp
./build/*
./.idea
./.idea/*
env
venv
*.sublime*