├── robots.txt ├── favicon.ico ├── img ├── bg.png ├── cube.png ├── key.png ├── save.png ├── user.png ├── apple.png ├── inbox.png ├── pencil.png ├── print.png ├── share.png ├── trash.png ├── about │ ├── add.png │ ├── index.png │ ├── shoplist.png │ ├── add_thumbnail.png │ ├── index_thumbnail.png │ └── shoplist_thumbnail.png ├── boxSize.png ├── checkmark.png ├── document.png ├── picture.png ├── shop_cart.png ├── cur_dollar.png ├── ecdb_loggo.png ├── ecdb_loggo.psd ├── icon-search.png ├── round_minus.png ├── round_plus.png ├── spechbubble.png ├── dataBackground.png ├── dataBackground.psd ├── ecdbSpriteV1.png ├── ecdbSpriteV1.psd ├── spechbubble_sq.png ├── checkbox_checked.png ├── checkbox_unchecked.png └── doc_lines_stright.png ├── include ├── autocomplete │ ├── indicator.gif │ ├── autocomplete_name.php │ ├── autocomplete_package.php │ ├── autocomplete_manufacturer.php │ └── jquery.autocomplete.css ├── contact │ └── jquery.validate.pack.js ├── header_public.php ├── login │ ├── config.php │ ├── auth.php │ └── loginmodule.css ├── debug.php ├── style.php ├── mysql_connect.php ├── message.css ├── menu_public.php ├── head.php ├── analytics.php ├── include_proj_update.php ├── include_proj_add.php ├── header.css ├── jquery.tweet.css ├── include_component_add_project.php ├── footer.php ├── include_proj_show_price.php ├── include_shoplist_sum.php ├── header.php ├── include_edit_component_project_menu.php ├── icons.css ├── menu.php ├── include_component_add_category_menu.php ├── include_component_edit_project_add.php ├── include_category_sub.php ├── globalTables.css ├── menu.css ├── include_category_head.php ├── globalForms.css ├── include_component_edit_project_edit.php ├── include_proj_list_projets.php ├── include_shoplist.php ├── include_my_settings.php ├── include_proj_show.php └── include_proj_show_.php ├── .htaccess ├── .gitignore ├── error.php ├── contact.php ├── public.php ├── error ├── 400.html ├── 401.html ├── 404.html ├── 403.html ├── 405.html ├── 500.html ├── 502.html └── 503.html ├── proj_add.php ├── login-exec.php ├── register-success.php ├── README.md ├── donate.php ├── login-failed.php ├── proj_edit.php ├── twitter-proxy.php ├── logout.php ├── proj_list.php ├── register-exec.php ├── register.php ├── login.php ├── about.php ├── terms.php ├── shoplist.php ├── index.php ├── category.php ├── search.php ├── contact_php_mail.php ├── proj_show.php ├── style.css ├── ecdb.sql ├── add.php └── add_based.php /robots.txt: -------------------------------------------------------------------------------- 1 | User-agent: * 2 | Disallow: 3 | -------------------------------------------------------------------------------- /favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/favicon.ico -------------------------------------------------------------------------------- /img/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/bg.png -------------------------------------------------------------------------------- /img/cube.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/cube.png -------------------------------------------------------------------------------- /img/key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/key.png -------------------------------------------------------------------------------- /img/save.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/save.png -------------------------------------------------------------------------------- /img/user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/user.png -------------------------------------------------------------------------------- /img/apple.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/apple.png -------------------------------------------------------------------------------- /img/inbox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/inbox.png -------------------------------------------------------------------------------- /img/pencil.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/pencil.png -------------------------------------------------------------------------------- /img/print.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/print.png -------------------------------------------------------------------------------- /img/share.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/share.png -------------------------------------------------------------------------------- /img/trash.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/trash.png -------------------------------------------------------------------------------- /img/about/add.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/about/add.png -------------------------------------------------------------------------------- /img/boxSize.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/boxSize.png -------------------------------------------------------------------------------- /img/checkmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/checkmark.png -------------------------------------------------------------------------------- /img/document.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/document.png -------------------------------------------------------------------------------- /img/picture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/picture.png -------------------------------------------------------------------------------- /img/shop_cart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/shop_cart.png -------------------------------------------------------------------------------- /img/about/index.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/about/index.png -------------------------------------------------------------------------------- /img/cur_dollar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/cur_dollar.png -------------------------------------------------------------------------------- /img/ecdb_loggo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/ecdb_loggo.png -------------------------------------------------------------------------------- /img/ecdb_loggo.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/ecdb_loggo.psd -------------------------------------------------------------------------------- /img/icon-search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/icon-search.png -------------------------------------------------------------------------------- /img/round_minus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/round_minus.png -------------------------------------------------------------------------------- /img/round_plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/round_plus.png -------------------------------------------------------------------------------- /img/spechbubble.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/spechbubble.png -------------------------------------------------------------------------------- /img/about/shoplist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/about/shoplist.png -------------------------------------------------------------------------------- /img/dataBackground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/dataBackground.png -------------------------------------------------------------------------------- /img/dataBackground.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/dataBackground.psd -------------------------------------------------------------------------------- /img/ecdbSpriteV1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/ecdbSpriteV1.png -------------------------------------------------------------------------------- /img/ecdbSpriteV1.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/ecdbSpriteV1.psd -------------------------------------------------------------------------------- /img/spechbubble_sq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/spechbubble_sq.png -------------------------------------------------------------------------------- /img/checkbox_checked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/checkbox_checked.png -------------------------------------------------------------------------------- /img/about/add_thumbnail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/about/add_thumbnail.png -------------------------------------------------------------------------------- /img/checkbox_unchecked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/checkbox_unchecked.png -------------------------------------------------------------------------------- /img/doc_lines_stright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/doc_lines_stright.png -------------------------------------------------------------------------------- /img/about/index_thumbnail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/about/index_thumbnail.png -------------------------------------------------------------------------------- /img/about/shoplist_thumbnail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/img/about/shoplist_thumbnail.png -------------------------------------------------------------------------------- /include/autocomplete/indicator.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/include/autocomplete/indicator.gif -------------------------------------------------------------------------------- /include/contact/jquery.validate.pack.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jwr/ecDB/HEAD/include/contact/jquery.validate.pack.js -------------------------------------------------------------------------------- /include/header_public.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.htaccess: -------------------------------------------------------------------------------- 1 | ## Default .htaccess file 2 | ## RewriteEngine On 3 | ## RewriteCond %{HTTP_HOST} !^www\.ecdb\.net 4 | ## RewriteRule (.*) http://www.ecdb.net/$1 [R=301,L] -------------------------------------------------------------------------------- /include/login/config.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/debug.php: -------------------------------------------------------------------------------- 1 | 12 | -------------------------------------------------------------------------------- /include/style.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ############ 2 | ## Windows 3 | ############ 4 | 5 | # Windows image file caches 6 | Thumbs.db 7 | 8 | # Folder config file 9 | Desktop.ini 10 | 11 | # MySQL Config files 12 | include/mysql_connect.php 13 | include/login/config.php 14 | /nbproject/private/ -------------------------------------------------------------------------------- /include/mysql_connect.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/message.css: -------------------------------------------------------------------------------- 1 | .message{padding:15px;margin:0 0 20px;} 2 | /* Colors ---------- */ 3 | .green.message{background-color:#c0f48c;} 4 | .red.message{background-color:#ffbbbb;} 5 | .orange.message{background-color:#fccd6d;} 6 | .white.message{background-color:#fff;} 7 | /* Align ---------- */ 8 | .center.message{text-align:center;} 9 | .right.message{text-align:right;} -------------------------------------------------------------------------------- /include/autocomplete/autocomplete_name.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/menu_public.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/autocomplete/autocomplete_package.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/autocomplete/autocomplete_manufacturer.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/login/auth.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/head.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | " media="screen"/> 5 | 6 | 7 | 8 | Home - ecDB 9 | 10 | 11 | -------------------------------------------------------------------------------- /include/analytics.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/include_proj_update.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/login/loginmodule.css: -------------------------------------------------------------------------------- 1 | body { 2 | font: 11px Verdana, Arial, Helvetica, sans-serif; 3 | color: #666666; 4 | margin: 0px; 5 | padding: 20px 10px 0px; 6 | } 7 | .textfield { 8 | font-size: 11px; 9 | color: #333333; 10 | background: #F7F7F7; 11 | border: 1px solid #CCCCCC; 12 | padding-left: 1px; 13 | } 14 | h1 { 15 | color: #99CC00; 16 | margin: 0px 0px 5px; 17 | padding: 0px 0px 3px; 18 | font: bold 18px Verdana, Arial, Helvetica, sans-serif; 19 | border-bottom: 1px dashed #E6E8ED; 20 | } 21 | a { 22 | color: #2D3954; 23 | font-size: 11px; 24 | } 25 | a:hover { 26 | color: #99CC00; 27 | } 28 | .err { 29 | color: #FF9900; 30 | } 31 | th { 32 | font-weight: bold; 33 | text-align: left; 34 | } 35 | -------------------------------------------------------------------------------- /include/include_proj_add.php: -------------------------------------------------------------------------------- 1 | '; 14 | echo 'You have to specify a name!'; 15 | echo ''; 16 | } 17 | else { 18 | $sql="INSERT into projects (project_owner, project_name) VALUES ('$owner', '$name')"; 19 | $sql_exec = mysql_query($sql); 20 | 21 | $proj_id = mysql_insert_id(); 22 | 23 | echo '
'; 24 | echo 'Project added!'; 25 | echo '
'; 26 | } 27 | } 28 | } 29 | } 30 | ?> -------------------------------------------------------------------------------- /include/header.css: -------------------------------------------------------------------------------- 1 | div#header{width:900px;margin:0 auto 15px auto;height:100px;position:relative;} 2 | div#header span.userInfo{color:#666;font-size:12px;text-shadow:0 1px 0 #fff;position:absolute;top:0px;right:0;} 3 | div#header span.userInfo a{color:#000;text-decoration:none;} 4 | div#header div.searchContent{position:absolute;font-size:12px;top:55px;right:0;color:#666;padding:3px;width:230px;background-color:#fff;border-bottom:2px solid #ccc;border-radius:6px;-moz-border-radius:6px;-webkit-border-radius:6px;} 5 | div#header div.searchContent form.search input{border:1px solid #fff !important;font: normal 14px "Century Gothic", arial, sans-serif;background:url("../img/ecdbSpriteV1.png") 209px -140px no-repeat #fff;box-shadow:none;padding:5px 15px 5px 5px;width:200px;} 6 | div.logoWrapper{position:absolute;top:10px;left:0;} 7 | div.logoWrapper a span.logoImage{display:block;width:169px;height:73px;background:url("../img/ecdbSpriteV1.png") no-repeat 0 -5px;} -------------------------------------------------------------------------------- /include/jquery.tweet.css: -------------------------------------------------------------------------------- 1 | .tweet, 2 | .query { 3 | #font: 30px; 4 | #color: #085258; 5 | } 6 | 7 | .tweet_list { 8 | -webkit-border-radius: 0.6em; 9 | -moz-border-radius: 0.6em; 10 | border-radius: 0.6em; 11 | list-style: none; 12 | margin: 0; 13 | font-size:13px; 14 | #color:#333; 15 | #font-family:Arial; 16 | padding: 0; 17 | overflow-y: hidden; 18 | #background-color: #F9F9F9; 19 | } 20 | 21 | .tweet_list li { 22 | overflow-y: auto; 23 | overflow-x: hidden; 24 | padding: 2px; 25 | list-style-type: none; 26 | 27 | } 28 | 29 | .tweet_list li a { 30 | text-decoration:none; 31 | border-bottom: 1px dotted #ccc; 32 | } 33 | 34 | .tweet_list li a:hover { 35 | border-bottom: 1px dotted #000; 36 | } 37 | 38 | .tweet_list .tweet_even { 39 | background-color: #eeeeee; 40 | } 41 | 42 | .tweet_list .tweet_avatar { 43 | padding-right: .5em; float: left; 44 | } 45 | 46 | .tweet_list .tweet_avatar img { 47 | vertical-align: middle; 48 | } -------------------------------------------------------------------------------- /include/include_component_add_project.php: -------------------------------------------------------------------------------- 1 | '; 14 | echo ' - Project - '; 15 | echo ''; 16 | 17 | while ($Project = mysql_fetch_array($sql_exec_projname)) { 18 | echo ''; 31 | } 32 | } 33 | } 34 | ?> -------------------------------------------------------------------------------- /include/footer.php: -------------------------------------------------------------------------------- 1 |
2 |
3 |
© 2010 - ecDB - Created by Nils Fredriksson - Contact us - Terms & Privacy
4 |
5 | 6 | 7 | 8 | members, 9 | 10 | 11 | components and 12 | 13 | 14 | projects. 15 | 16 |
17 |
18 |
19 | Design by 20 |
21 |
-------------------------------------------------------------------------------- /include/include_proj_show_price.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/include_shoplist_sum.php: -------------------------------------------------------------------------------- 1 | 0 ORDER by name ASC"; 13 | 14 | $sql_exec = mysql_Query($GetDataComponentsAll); 15 | while($showDetails = mysql_fetch_array($sql_exec)) { 16 | 17 | $price = $showDetails['price']; 18 | $quantity = $showDetails['order_quantity']; 19 | 20 | $product = $price * $quantity; 21 | $sum[] = $product; 22 | 23 | } 24 | if (isset($sum)) { 25 | echo array_sum($sum); 26 | echo ' '; 27 | echo $personal['currency']; 28 | } 29 | else { 30 | echo '0'; 31 | echo ' '; 32 | echo $personal['currency']; 33 | } 34 | } 35 | } 36 | ?> -------------------------------------------------------------------------------- /include/autocomplete/jquery.autocomplete.css: -------------------------------------------------------------------------------- 1 | .ac_results { 2 | padding: 0px; 3 | border: 1px solid #888; 4 | background-color: white; 5 | box-shadow:0 0 5px #aaa; 6 | overflow: hidden; 7 | z-index: 99999; 8 | min-width:210px; 9 | } 10 | 11 | .ac_results ul { 12 | width: 100%; 13 | list-style-position: outside; 14 | list-style: none; 15 | padding: 0; 16 | margin: 0; 17 | } 18 | 19 | .ac_results li { 20 | margin: 0px; 21 | padding:5px; 22 | cursor: default; 23 | display: block; 24 | /* 25 | if width will be 100% horizontal scrollbar will apear 26 | when scroll mode will be used 27 | */ 28 | /*width: 100%;*/ 29 | font-size: 14px; 30 | /* 31 | it is very important, if line-height not setted or setted 32 | in relative units scroll will be broken in firefox 33 | */ 34 | line-height: 16px; 35 | overflow: hidden; 36 | } 37 | 38 | .ac_loading { 39 | background: white url('indicator.gif') right center no-repeat; 40 | } 41 | 42 | .ac_odd { 43 | background-color: #eee; 44 | } 45 | 46 | .ac_over { 47 | background-color: #404040; 48 | color:#fff; 49 | } 50 | -------------------------------------------------------------------------------- /include/header.php: -------------------------------------------------------------------------------- 1 | 30 | 31 | -------------------------------------------------------------------------------- /include/include_edit_component_project_menu.php: -------------------------------------------------------------------------------- 1 | '; 33 | echo $Project['project_name']; 34 | echo ''; 35 | } 36 | } 37 | } 38 | ?> -------------------------------------------------------------------------------- /include/icons.css: -------------------------------------------------------------------------------- 1 | .icon{border:none;text-indent:-9999px;display:inline-block;background-image:url("../img/ecdbSpriteV1.png");background-repeat:no-repeat;} 2 | /* Sizes ---------- */ 3 | .medium.icon{width:16px; height:16px; margin:0 0 -3px;} 4 | /* Icons ---------- */ 5 | .checkboxChecked.medium{background-position:0 -88px;} 6 | .checkboxUnchecked.medium{background-position:-16px -88px;} 7 | .checkmark.medium{background-position:-32px -88px;} 8 | .document.medium{background-position:-48px -88px;} 9 | .key.medium{background-position:-64px -88px;} 10 | .pencil.medium{background-position:-80px -88px;} 11 | .picture.medium{background-position:-96px -88px;} 12 | .print.medium{background-position:-112px -88px;} 13 | .roundMinus.medium{background-position:-128px -88px;} 14 | .roundPlus.medium{background-position:-144px -88px;} 15 | .save.medium{background-position:-160px -88px;} 16 | .spechBubble.medium{background-position:-176px -88px;} 17 | .spechBubbleSq.medium{background-position:-192px -88px;} 18 | .trash.medium{background-position:-208px -88px;} 19 | .sqPlus.medium{background-position:-224px -88px;} 20 | .documentLines.medium{background-position:0 -104px;} 21 | .blIcon{background:url("../img/ecdbSpriteV1.png") no-repeat 0 -168px;width:77px;height:25px;display:inline-block;border:none;margin-bottom:-8px;} 22 | .packageImage{position:absolute;top:155px;right:125px;} -------------------------------------------------------------------------------- /include/menu.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /include/include_component_add_category_menu.php: -------------------------------------------------------------------------------- 1 | '; 12 | echo ' - Category - '; 13 | echo ''; 14 | 15 | while ($HeadCategory = mysql_fetch_array($sql_exec_headcat)) { 16 | echo ''; 21 | 22 | $subcatfrom = $HeadCategory['id'] * 100; 23 | $subcatto = $subcatfrom + 99; 24 | 25 | $SubCategoryNameQuery = "SELECT * FROM category_sub WHERE id BETWEEN ".$subcatfrom." AND ".$subcatto." ORDER by name ASC"; 26 | $sql_exec_subcat = mysql_Query($SubCategoryNameQuery); 27 | 28 | while ($SubCategory = mysql_fetch_array($sql_exec_subcat)) { 29 | echo ''; 42 | } 43 | } 44 | } 45 | } 46 | ?> -------------------------------------------------------------------------------- /include/include_component_edit_project_add.php: -------------------------------------------------------------------------------- 1 | '; 12 | echo ' - Project - '; 13 | echo ''; 14 | 15 | $GetDataProject = "SELECT * FROM projects WHERE project_owner = '$owner'"; 16 | $sql = mysql_query($GetDataProject); 17 | 18 | while($row1 = mysql_fetch_array($sql)){ 19 | 20 | $query1 = "SELECT projects_data.projects_data_project_id, projects_data.projects_data_component_id FROM projects_data RIGHT JOIN projects ON projects.project_id = projects_data.projects_data_project_id WHERE projects.project_owner = '$owner'"; 21 | 22 | $result1 = mysql_query($query1); 23 | 24 | echo ''; 47 | } 48 | } 49 | } 50 | ?> -------------------------------------------------------------------------------- /error.php: -------------------------------------------------------------------------------- 1 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | Error - ecDB 33 | 34 | 35 | 36 | 37 |
38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | 48 |
49 |
50 | 51 | 52 | 53 | 54 |
55 | 56 | 57 | -------------------------------------------------------------------------------- /contact.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Contact - ecDB 13 | 14 | 15 | 16 | 17 |
18 | '; 21 | include 'include/header.php'; 22 | echo ''; 23 | 24 | echo ''; 25 | include 'include/menu.php'; 26 | echo ''; 27 | } 28 | else { 29 | echo ''; 30 | include 'include/header_public.php'; 31 | echo ''; 32 | 33 | echo ''; 34 | include 'include/menu_public.php'; 35 | echo ''; 36 | } 37 | ?> 38 | 39 |
40 |
41 |
42 |

Contact us

43 | If you have any suggestions, questions or what not. Send us an email to info@ecdb.net 44 |
45 |
46 |
47 |
48 | 49 | 50 | 51 | 52 |
53 | 54 | -------------------------------------------------------------------------------- /include/include_category_sub.php: -------------------------------------------------------------------------------- 1 | '; 32 | echo ''; 51 | echo $ShowDetailsSubCatname['name']; 52 | echo ' '; 53 | } 54 | } 55 | } 56 | ?> -------------------------------------------------------------------------------- /public.php: -------------------------------------------------------------------------------- 1 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | Home - ecDB 16 | 17 | 18 | 19 | 20 | 21 |
22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 |
33 |

Public Components

34 | 35 |
36 | When you add a component there is a button called "public". If you choose to set that to yes, it means that other people can see that you own that component.

37 | 38 | The thought with that setting is, for example; You are building a project and missed to order one component, to skip expensive shipping costs, long shipping time etc. you just make a quick search on ecDB for that component and contact the owner. Hopefully he is kind enough to send you that component quickly for a small charge. 39 |
40 | 41 |

This function is under development...

42 |
43 | 44 | 45 | 46 | 47 |
48 | 49 | 50 | -------------------------------------------------------------------------------- /include/globalTables.css: -------------------------------------------------------------------------------- 1 | table.globalTables{width:100%; position:relative;} 2 | table.globalTables thead tr th{padding:0 0 5px;font-weight:normal;text-transform:uppercase;font-size:11px;border-bottom:2px solid #ccc;} 3 | table.globalTables tbody tr{} 4 | table.globalTables tbody tr:hover{background-color:#f5f5f5;} 5 | table.globalTables.noHover tbody tr:hover{background-color:#fff;} 6 | table.globalTables tbody tr td{text-align:center;padding:5px 0;line-height:18px;} 7 | table.globalTables.leftAlign tbody tr td{text-align:left;} 8 | /* Types ----- */ 9 | table.globalTables tbody tr td.comment div{position:relative;overflow:visible;} 10 | table.globalTables tbody tr td.comment div span.comment{max-height:200px;overflow:hidden;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;box-shadow:0 0 3px #666;-moz-box-shadow:0 0 3px #666;-webkit-box-shadow:0 0 3px #666;padding:8px;display:none;z-index:1000;text-align:left;position:absolute;width:200px;color:#000;top:20px;right:5px;background-color:#fff;} 11 | table.globalTables tbody tr td.comment:hover div span.comment{display:block;} 12 | table.globalTables tbody tr td a.thumbnail{position:relative;} 13 | table.globalTables tbody tr td a.thumbnail span.imgB{background-color:#fff;padding:15px;line-height:0;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;box-shadow:0 0 3px #666;-moz-box-shadow:0 0 3px #666;-webkit-box-shadow:0 0 3px #666;position:absolute;left:32px;bottom:-20px;visibility: hidden;z-index:1;} 14 | table.globalTables tbody tr td a.thumbnail span.imgB img{max-width:260px;} 15 | table.globalTables tbody tr td a.thumbnail:hover span.imgB{visibility: visible;} 16 | table.globalTables tbody tr td.edit{padding-left:3px;} 17 | table.globalTables tbody tr td.edit a{visibility:hidden;} 18 | table.globalTables tbody tr:hover td.edit a{visibility:visible;} -------------------------------------------------------------------------------- /error/400.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 400 - Bad Request! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

You have used invalid syntax.

54 |

Please contact the webmaster with any queries.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /error/401.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 401 - Unauthorized! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

The URL requested requires authorisation.

54 |

Please contact the webmaster with any queries.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /error/404.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 404 - Not Found! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

The requested URL was not found on this server.

54 |

Please check the URL or contact the webmaster.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /error/403.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 403 - Forbidden! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

You are not permitted to access the requested URL.

54 |

Please contact the webmaster with any queries.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /error/405.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 405 - Method Not Allowed! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

The method used is not permitted.

54 |

Please contact the webmaster with any queries.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /include/menu.css: -------------------------------------------------------------------------------- 1 | div#menu{width:870px;padding:0 15px 0 15px;margin:auto;} 2 | div#menu ul{list-style:none;} 3 | div#menu ul li{list-style:none;display:inline-block;} 4 | div#menu ul li a{display:inline-block;color:#2d2d2d;font-size:12px;text-decoration:none;padding:7px 15px 7px 15px;background-color:#f8f8f8;border-radius:4px 4px 0 0;-moz-border-radius:4px 4px 0 0;-webkit-border-top-left-radius:4px;-webkit-border-top-right-radius:4px;} 5 | div#menu ul li a:hover{background-color:#e6e6e6;} 6 | div#menu ul li a.selected{background-color:#fff;cursor:default;} 7 | div#menu ul li.public a{display:inline-block;color:#707070;font-size:12px;text-decoration:none;padding:7px 15px 7px 15px;background-color:#d7eaff;border-radius:4px 4px 0 0;-moz-border-radius:4px 4px 0 0;-webkit-border-top-left-radius:4px;-webkit-border-top-right-radius:4px;} 8 | div#menu ul li.public a:hover{background-color:#e6e6e6;} 9 | div#menu ul li.public a.selected{background-color:#fff;cursor:default;color:#000;} 10 | div.subMenu{text-align: center;} 11 | div.subMenu ul{list-style:none;margin:0;padding:0 0 10px 0;border-bottom:1px dashed #f2f2f2;} 12 | div.subMenu ul li{list-style:none;display:inline-block;margin-bottom: 5px;} 13 | div.subMenu ul li a{display:inline-block;font-size:13px;padding:4px 10px 4px 10px;background-color:#63bd20;color:#fff;margin:0;text-decoration:none;border-radius:2px;-moz-border-radius:2px;-webkit-border-radius:2px;} 14 | div.subMenu ul li a.selected{background-color:#4a8d18;} 15 | div.subMenu ul li a:hover{background-color:#4a8d18;} 16 | div.subSubMenu{} 17 | div.subSubMenu ul{list-style:none;margin:0;padding:6px 0 7px 0;border-bottom:1px dashed #f2f2f2;text-align: center;} 18 | div.subSubMenu ul li{list-style:none;display:inline-block;margin-bottom: 8px;margin-top: 8px;} 19 | div.subSubMenu ul li a{display:inline-block;font-size:13px;padding:4px 10px 4px 10px;background-color:#f2f2f2;color:#000;margin:0;text-decoration:none;border-radius:2px;-moz-border-radius:2px;-webkit-border-radius:2px;} 20 | div.subSubMenu ul li a.selected{background-color:#E0E0E0;} 21 | div.subSubMenu ul li a:hover{background-color:#E0E0E0;} -------------------------------------------------------------------------------- /proj_add.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Add Project - ecDB 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 |

Add Project

29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 57 | 58 | 59 |
Name
50 | AddProj(); 55 | ?> 56 |
60 |
61 | 62 |
63 |
64 | 65 | 66 | 67 | 68 |
69 | 70 | -------------------------------------------------------------------------------- /error/500.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 500 - Internal Server Error! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

The requested URL caused an internal server error.

54 |

If you get this message repeatedly please contact the webmaster.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /error/502.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 502 - Bad Gateway! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

This server received an invalid response from an upstream server it accessed to fulfill the request.

54 |

If you get this message repeatedly please contact the webmaster.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /error/503.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | ERROR 503 - Service Unavailable! 6 | 7 | 8 | 45 | 46 | 47 |
48 | 51 |
52 |

The following error occurred:

53 |

The Service is not available at the moment due to a temporary overloading or maintenance of the server. Please try again later.

54 |

Please contact the webmaster with any queries.

55 |
56 | 59 |
60 | 61 | 62 | -------------------------------------------------------------------------------- /login-exec.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /register-success.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | Login - ecDB 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 27 | 28 | 29 | 30 | 38 | 39 | 40 | 41 |
42 | 43 |

Registration success

44 | 45 | Please login

46 | 47 |
48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 |
Login
Password
 
62 |
63 |
64 | 65 | 66 | 67 | 68 | 69 | 70 |
71 | 72 | 73 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | README 2 | ==== 3 | 4 | ## ecDB and PartsBox 5 | 6 | ecDB, or Electronics Component DataBase, is a project that was created by [Nils Fredriksson](http://nilsf.se) aka. ElectricMan, and designed by [Buildlog](http://buildlog.se). 7 | 8 | In May 2018 ecDB.net was acquired by PartsBox (https://partsbox.com/) and users of the online ecDB service were offered to upgrade/migrate their data. 9 | 10 | PartsBox is an online app that lets you take control of your electronic parts inventory, BOM pricing, and small-scale production. It keeps track of where components are stored, what the current stock levels are, and which components are used in which projects/BOMs. PartsBox significantly expands what ecDB offered, with lots of new features and a blazingly fast parts search. It is available commercially (with features like BOM pricing, barcode scanning, sub-assemblies, file uploads and lots more), but there is also a free hobbyist/maker version, with everything the hobbyist needs. 11 | 12 | PartsBox lets you export everything you entered, anytime. Data export is a fundamental feature: export a JSON data file with a single click. 13 | 14 | ## ecDB Source Code 15 | 16 | While the ownership of ecDB was transferred to PartsBox, there is no intention of pulling the code from the Internet. It will continue to remain freely available for anyone that wishes to build on it, or run their own ecDB instance. This repository will remain public and accessible. 17 | 18 | ## Support 19 | 20 | Please note that this code is unsupported. Please do not try to file issues or issue pull requests, as we have no resources to deal with them. 21 | 22 | ## Documentation 23 | 24 | Currently there is no documentation available. Please feel free to create it! 25 | 26 | ## Installation 27 | 28 | - Check out the git repository. 29 | - Create a MySQL database. 30 | - Import `ecdb_databse.sql` database structure to your MySQL-database. 31 | - Insert your MySQL data in the configuration file, `include/mysql_connect.php`. 32 | - **You are now set to go!** The default username is `demo` and password `demo`. 33 | 34 | ### Requirements 35 | 36 | - Web Server. 37 | - PHP Version 5.2.4 or above. 38 | - MySQL Version 5.0 or above. 39 | 40 | ## License 41 | 42 | - ecDB is licensed under a Creative Commons [Attribution-NonCommercial-ShareAlike 3.0 Unported License](http://creativecommons.org/licenses/by-nc-sa/3.0/). 43 | - The ecDB code is not allowed for public use. 44 | - You are allowed to set up a private ecDB database for yourself, or whithin an organisation. 45 | -------------------------------------------------------------------------------- /donate.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Contact - ecDB 13 | 14 | 15 | 16 | 17 |
18 | '; 21 | include 'include/header.php'; 22 | echo ''; 23 | 24 | echo ''; 25 | include 'include/menu.php'; 26 | echo ''; 27 | } 28 | else { 29 | echo ''; 30 | echo ''; 35 | echo ''; 36 | 37 | echo ''; 38 | echo ''; 46 | echo ''; 47 | } 48 | ?> 49 | 50 |
51 |
52 |
53 |

Donate

54 | ecDB is completely free!
55 | However, if you like ecDB you may use the button below to donate some money to the project!

56 |
57 | 58 | 59 | 60 |
61 |
62 |
63 |
64 |
65 | 66 | 67 | 68 | 69 |
70 | 71 | -------------------------------------------------------------------------------- /login-failed.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | Login - ecDB 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 21 | 22 | 23 | 24 | 32 | 33 | 34 | 35 |
36 | 37 |
38 | Login failed, please try again. 39 |
40 | 41 |
42 |
43 |
44 | 45 |
46 |
47 | 48 |
49 |
50 |
51 | 52 |
53 |
54 |
55 |
56 | 57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 | 65 | 66 | 67 | 68 | 69 | 70 |
71 | 72 | 73 | -------------------------------------------------------------------------------- /include/include_category_head.php: -------------------------------------------------------------------------------- 1 | '; 25 | echo ''; 33 | echo "All"; 34 | echo ' '; 35 | 36 | while ($ShowDetailsCatname = mysql_fetch_array($sql_exec_catname)) { 37 | echo '
  • '; 38 | echo ''; 86 | echo $ShowDetailsCatname['name']; 87 | echo '
  • '; 88 | } 89 | } 90 | } 91 | ?> 92 | 93 | 94 | -------------------------------------------------------------------------------- /proj_edit.php: -------------------------------------------------------------------------------- 1 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | Your Projects - ecDB 30 | 31 | 32 | 33 | 34 | 35 |
    36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
    47 |

    Edit Project

    48 | 49 | AddProj(); 53 | ?> 54 | 55 |
    56 |
    57 | 58 |
    59 |
    60 |
    61 |
    62 | 63 | 64 |
    65 |
    66 |
    67 |
    68 | 69 | 70 | 71 | 72 |
    73 | 74 | -------------------------------------------------------------------------------- /include/globalForms.css: -------------------------------------------------------------------------------- 1 | form textarea, 2 | form input, 3 | form select{padding:6px;font: normal 13px "Century Gothic", arial, sans-serif;border:1px solid #ccc; /* #fff */border-bottom:1px solid #ccc;resize:none;background-color:#fafafa;} 4 | form textarea:focus, 5 | form input:focus, 6 | form select:focus{background-color:#fdfdfd;} 7 | /* Sizes -------- */ 8 | form input.small{width:40px;} 9 | form input.medium{width:200px;} 10 | form input.big{width:300px;} 11 | .globalForms{} 12 | .globalForms.inLine{display:inline-block;} 13 | .globalForms div.textInput, 14 | .globalForms div.radio{margin:0 0 5px;} 15 | .globalForms div.textInput label.keyWord, 16 | .globalForms div.radio label.keyWord{display:inline-block;width:140px;margin:0 5px 0;padding:6px 0;text-align:right;} 17 | .globalForms div.textInput div.input, 18 | .globalForms div.radio div.input{display:inline-block;} 19 | .globalForms div.textInput div.info, 20 | .globalForms div.radio div.info, 21 | .globalForms div.select div.info{margin:0 0 10px 154px;color:#666;font-size:12px;} 22 | /* Textarea ---------- */ 23 | .globalForms div.textBoxInput{margin:0 0 5px;} 24 | .globalForms div.textBoxInput label.keyWord{width:140px;display:inline-block;margin:0 0 3px;} 25 | .globalForms div.textBoxInput div.text{display:block;} 26 | .globalForms div.textBoxInput div.text textarea{width:857px;} 27 | /* Separator ---------- */ 28 | .globalForms div.separator{height:1px; margin:15px 0;} 29 | .globalForms div.separator.dashed{border-bottom:1px dashed #cecece;} 30 | /* Select ---------- */ 31 | .globalForms div.select{margin:0 0 5px;} 32 | .globalForms div.select label.keyWord{display:inline-block;float:left;width:140px;margin:0 7px 0;padding:6px 0;text-align:right;} 33 | .globalForms div.select div.input{display:inline-block;} 34 | .globalForms select{width:214px; } 35 | .globalForms div.buttons{margin:0 0 0 153px;} 36 | .globalForms.noPadding div.buttons{margin:5px 0 0 0;padding:10px 0 0 0;border-top:1px solid #f2f2f2;} 37 | .globalForms div.validating{margin:0 0 20px 170px;color:#e80000;} 38 | button.button{color:#000;cursor: pointer;font: bold 12px arial, sans-serif;line-height:20px;font-size:12px;letter-spacing:.5px;border:0;background-color:#e2e2e2;padding:6px 18px;border-radius:2px;-moz-border-radius:2px;-wekit-border-radius:2px;} 39 | /* Hovers ---------- */ 40 | .button:hover{background-color:#dadada;} 41 | .green.button:hover{background-color:#5aac1e;} 42 | .red.button:hover{background-color:#e3151b;} 43 | /* Sizes ---------- */ 44 | .small.button{padding:1.5px 3px; font-size:10px;} 45 | /* Colors ---------- */ 46 | .white.button{background-color:#fff;padding:0;} 47 | .green.button{background-color:#63bd20; color:#fff;} 48 | .red.button{background-color:#ed4145; color:#fff;} 49 | -------------------------------------------------------------------------------- /twitter-proxy.php: -------------------------------------------------------------------------------- 1 | '', 6 | 'oauth_access_token_secret' => '', 7 | 'consumer_key' => '', 8 | 'consumer_secret' => '', 9 | 'base_url' => 'http://api.twitter.com/1.1/', 10 | //Request specific user 11 | 'screen_name' => '', 12 | 'count' => 3 13 | ); 14 | 15 | $twitter_request = 'statuses/user_timeline.json?screen_name='.$config['screen_name'].'&count='.$config['count']; 16 | 17 | // Parse $twitter_request into URL parameters 18 | $url_part = parse_url($twitter_request); 19 | 20 | /* url_arguments= 21 | * Array 22 | * ( 23 | * [screen_name] => lcherone 24 | * [count] => 3 25 | * ) 26 | */ 27 | parse_str($url_part['query'], $url_arguments); 28 | 29 | $base_url = $config['base_url'].$url_part['path']; 30 | $full_url = $config['base_url'].$twitter_request; 31 | 32 | // Set up the OAuth authorization array 33 | $oauth = array( 34 | 'oauth_consumer_key' => $config['consumer_key'], 35 | 'oauth_nonce' => time(), 36 | 'oauth_signature_method' => 'HMAC-SHA1', 37 | 'oauth_token' => $config['oauth_access_token'], 38 | 'oauth_timestamp' => time(), 39 | 'oauth_version' => '1.0' 40 | ); 41 | 42 | // Build vectors for request 43 | $composite_request = _BaseString($base_url, 'GET', array_merge($oauth, $url_arguments)); 44 | $composite_key = rawurlencode($config['consumer_secret']).'&'.rawurlencode($config['oauth_access_token_secret']); 45 | $oauth_signature = base64_encode(hash_hmac('sha1', $composite_request, $composite_key, true)); 46 | $oauth['oauth_signature'] = $oauth_signature; 47 | 48 | // Make cURL Request 49 | $options = array( 50 | CURLOPT_HTTPHEADER => array(_AuthorizationHeader($oauth),'Expect:'), 51 | CURLOPT_HEADER => false, 52 | CURLOPT_URL => $full_url, 53 | CURLOPT_RETURNTRANSFER => true, 54 | CURLOPT_SSL_VERIFYPEER => false 55 | ); 56 | 57 | $feed = curl_init(); 58 | curl_setopt_array($feed, $options); 59 | $result = curl_exec($feed); 60 | $info = curl_getinfo($feed); 61 | curl_close($feed); 62 | 63 | // Send suitable headers to the end user. 64 | if(isset($info['content_type']) && isset($info['size_download'])){ 65 | header('Content-Type: '.$info['content_type']); 66 | header('Content-Length: '.$info['size_download']); 67 | } 68 | exit($result); 69 | 70 | function _BaseString($base_url, $method, $values) { 71 | $ret = array(); 72 | ksort($values); 73 | foreach($values as $key=>$value) 74 | $ret[] = $key."=".rawurlencode($value); 75 | return $method."&".rawurlencode($base_url).'&'.rawurlencode(implode('&', $ret)); 76 | } 77 | 78 | function _AuthorizationHeader($oauth) { 79 | $ret = 'Authorization: OAuth '; 80 | $values = array(); 81 | foreach($oauth as $key=>$value) 82 | $values[] = $key.'="'.rawurlencode($value).'"'; 83 | $ret .= implode(', ', $values); 84 | return $ret; 85 | } 86 | ?> -------------------------------------------------------------------------------- /include/include_component_edit_project_edit.php: -------------------------------------------------------------------------------- 1 | '; 17 | echo ''; 22 | echo ''; 23 | //echo ''; 24 | //echo ''; 25 | echo ''; 26 | echo ''; 27 | } 28 | 29 | $query1 = "SELECT projects_data.projects_data_project_id, projects_data.projects_data_quantity, projects_data.projects_data_project_id, projects_data.projects_data_component_id, projects.project_id, projects.project_name FROM projects_data, projects WHERE projects_data.projects_data_project_id = projects.project_id AND projects_data.projects_data_component_id = '$id' LIMIT 1,18446744073709551615"; 30 | 31 | $result1 = mysql_query($query1) or die(mysql_error()); 32 | 33 | while($row1 = mysql_fetch_array($result1)){ 34 | echo ''; 35 | echo ''; 36 | echo ''; 37 | echo ''; 38 | echo ''; 39 | echo $row1['project_name']; 40 | echo ''; 41 | echo ''; 46 | echo ''; 47 | //echo ''; 48 | //echo ''; 49 | echo ''; 50 | echo ''; 51 | 52 | } 53 | 54 | if (mysql_num_rows($result) == 0) { 55 | echo ''; 56 | echo ''; 57 | echo ''; 58 | echo ''; 59 | } 60 | } 61 | } 62 | ?> -------------------------------------------------------------------------------- /include/include_proj_list_projets.php: -------------------------------------------------------------------------------- 1 | "; 42 | echo ''; 45 | 46 | echo ''; 47 | echo ''; 50 | echo $showDetails['project_name']; 51 | echo ''; 52 | echo ''; 53 | 54 | echo ""; 55 | $components = mysql_query("SELECT projects_data_project_id FROM projects_data WHERE projects_data_project_id = ".$showDetails['project_id'].""); 56 | $number_components = mysql_num_rows($components); 57 | if ($number_components == 0){ 58 | echo "-"; 59 | } 60 | else{ 61 | echo $number_components; 62 | } 63 | echo ""; 64 | 65 | echo ''; 66 | $GetDataPrice = "SELECT SUM(total) FROM (SELECT projects_data_quantity * price AS total FROM projects_data JOIN `data` WHERE data.id = projects_data_component_id AND projects_data_project_id = ".$showDetails['project_id'].") AS project_total"; 67 | $sql_exec_price = mysql_Query($GetDataPrice) or die(mysql_error()); 68 | 69 | while($showPrice = mysql_fetch_array($sql_exec_price)) { 70 | if ($showPrice['SUM(total)'] == 0){ 71 | echo "-"; 72 | } 73 | else{ 74 | echo $showPrice['SUM(total)']; 75 | echo ' '; 76 | echo $personal['currency']; 77 | } 78 | } 79 | echo ''; 80 | echo ""; 81 | } 82 | } 83 | } 84 | ?> 85 | -------------------------------------------------------------------------------- /logout.php: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | Login - ecDB 19 | 20 | 21 | 22 | 23 | 24 |
    25 | 26 | 27 | 32 | 33 | 34 | 35 | 43 | 44 | 45 | 46 |
    47 |
    48 | You have successfully signed out of your account. 49 |
    50 | 51 |
    52 |
    53 |
    54 | You want to build something and need some components for your project. 55 | You don't know if you have those components, or where they are. 56 | This is a problem many of us recognise. 57 | We want to change that for you by making a online inventory system for your electronic components that is easy to use. 58 | Add your components. Search to find it, and then use it! 59 |
    60 |
    61 |
    62 | 63 |
    64 |
    65 |
    66 | 67 |
    68 |
    69 |
    70 |
    71 | 72 |
    73 |
    74 |
    75 |
    76 |
    77 |
    78 | 79 | 80 |
    81 | 82 | 83 | 84 | 85 | 86 | 87 |
    88 | 89 | 90 | 91 | -------------------------------------------------------------------------------- /proj_list.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | Your Projects - ecDB 15 | 16 | 17 | 18 | 19 | 20 |
    21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 |
    32 | AddProj(); 36 | 37 | $proj_query = mysql_query("SELECT * FROM projects WHERE project_owner= $owner"); 38 | if(mysql_num_rows($proj_query) == 0){ 39 | echo '
    To create a BOM-list (Bill Of Material) you have to first create a project. You will then be able to add your components to your project and automaticly create a BOM-list.
    '; 40 | } 41 | ?> 42 |
    43 |
    44 | 45 |
    46 |
    47 |
    48 |
    49 | 50 |
    51 |
    52 |
    53 | 54 |
    55 | 56 | 57 | 58 | 59 | 60 | 75 | 76 | 77 | 78 | 79 | 80 | ProjList(); 84 | ?> 85 | 86 |
    Name 74 | Number of componentsTotal cost
    87 |
    88 | 89 | 90 | 91 | 92 |
    93 | 94 | 95 | -------------------------------------------------------------------------------- /include/include_shoplist.php: -------------------------------------------------------------------------------- 1 | 0 ORDER by ".$bysql." +0 ".$ordersql.""; 21 | } 22 | else { 23 | 24 | $GetDataComponentsAll = "SELECT * FROM data WHERE owner = ".$owner." AND order_quantity > 0 ORDER by ".$bysql." ".$ordersql.""; 25 | } 26 | } 27 | else { 28 | $GetDataComponentsAll = "SELECT * FROM data WHERE owner = ".$owner." AND order_quantity > 0 ORDER by name ASC"; 29 | } 30 | 31 | 32 | $sql_exec = mysql_Query($GetDataComponentsAll); 33 | 34 | while($showDetails = mysql_fetch_array($sql_exec)) { 35 | echo ""; 36 | 37 | echo ''; 40 | 41 | echo ''; 44 | 45 | echo $showDetails['name']; 46 | echo ""; 47 | 48 | echo ""; 49 | $manufacturer = $showDetails['manufacturer']; 50 | if ($manufacturer == ""){ 51 | echo "-"; 52 | } 53 | else{ 54 | echo $manufacturer; 55 | } 56 | echo ""; 57 | 58 | echo ""; 59 | $package = $showDetails['package']; 60 | if ($package == ""){ 61 | echo "-"; 62 | } 63 | else{ 64 | echo $package; 65 | } 66 | echo ""; 67 | 68 | 69 | echo ""; 70 | $smd = $showDetails['smd']; 71 | if ($smd == "No"){ 72 | echo ''; 73 | } 74 | else{ 75 | echo ''; 76 | } 77 | echo ""; 78 | 79 | echo ""; 80 | $price = $showDetails['price']; 81 | if ($price == ""){ 82 | echo "-"; 83 | } 84 | else{ 85 | echo $price; 86 | } 87 | echo ""; 88 | 89 | echo ""; 90 | $quantity = $showDetails['quantity']; 91 | if ($quantity == ""){ 92 | echo "-"; 93 | } 94 | else{ 95 | echo $quantity; 96 | } 97 | echo ""; 98 | 99 | echo ""; 100 | $order_quantity = $showDetails['order_quantity']; 101 | if ($order_quantity == ""){ 102 | echo "-"; 103 | } 104 | else{ 105 | echo $order_quantity; 106 | } 107 | echo ""; 108 | 109 | $comment = $showDetails['comment']; 110 | if ($comment==""){ 111 | echo '
    '; 112 | echo "-"; 113 | echo '
    '; 114 | } 115 | else{ 116 | echo '
    '; 117 | echo $showDetails['comment']; 118 | echo '
    '; 119 | } 120 | echo ""; 121 | } 122 | } 123 | } 124 | ?> -------------------------------------------------------------------------------- /include/include_my_settings.php: -------------------------------------------------------------------------------- 1 | '; 26 | echo 'First name missing'; 27 | echo ''; 28 | } 29 | elseif (strlen($firstname) <= 2) { 30 | echo '
    '; 31 | echo 'Minimum of 2 chars in first name.'; 32 | echo '
    '; 33 | } 34 | elseif ($lastname == '') { 35 | echo '
    '; 36 | echo 'Last name missing'; 37 | echo '
    '; 38 | } 39 | elseif (strlen($lastname) <= 2) { 40 | echo '
    '; 41 | echo 'Minimum of 2 chars in last name.'; 42 | echo '
    '; 43 | } 44 | elseif ($mail == '') { 45 | echo '
    '; 46 | echo 'Mail missing'; 47 | echo '
    '; 48 | } 49 | elseif (!filter_var($mail, FILTER_VALIDATE_EMAIL)) { 50 | echo '
    '; 51 | echo 'Invalid e-mail address'; 52 | echo '
    '; 53 | } 54 | elseif (!empty($oldpass) && !empty($newpass) && $owner == 4) { 55 | echo '
    '; 56 | echo 'Y NO CHANGE PASSWORD FOR THE DEMO ACCOUNT!!11'; 57 | echo '
    '; 58 | } 59 | elseif (!empty($oldpass) && !empty($newpass) && $oldpass == '') { 60 | echo '
    '; 61 | echo 'Password missing'; 62 | echo '
    '; 63 | } 64 | elseif (!empty($oldpass) && !empty($newpass) && $newpass == '') { 65 | echo '
    '; 66 | echo 'Confirm password missing'; 67 | echo '
    '; 68 | } 69 | elseif (!empty($oldpass) && !empty($newpass) && strlen($newpass) <= 5) { 70 | echo '
    '; 71 | echo 'Minimum of 5 chars in password.'; 72 | echo '
    '; 73 | } 74 | elseif (!empty($oldpass) && !empty($newpass) && strcmp(md5($oldpass), $executesql['passwd']) != 0 ) { 75 | echo '
    '; 76 | echo 'The password is invalid '; 77 | echo '
    '; 78 | } 79 | else { 80 | if (!empty($oldpass) && !empty($newpass)) { 81 | $sql="UPDATE members SET firstname = '$firstname', lastname = '$lastname', mail = '$mail', passwd = '".md5($newpass)."', measurement = '$measurement', currency = '$currency' WHERE member_id = '$owner'"; 82 | $sql_exec = mysql_query($sql); 83 | } 84 | else { 85 | $sql="UPDATE members SET firstname = '$firstname', lastname = '$lastname', mail = '$mail', measurement = '$measurement', currency = '$currency' WHERE member_id = '$owner'"; 86 | $sql_exec = mysql_query($sql); 87 | } 88 | 89 | echo '
    '; 90 | echo 'Settings updated!'; 91 | echo '
    '; 92 | } 93 | } 94 | } 95 | } 96 | ?> -------------------------------------------------------------------------------- /register-exec.php: -------------------------------------------------------------------------------- 1 | 0) { 101 | $errmsg_arr[] = 'Username already in use'; 102 | $errflag = true; 103 | } 104 | @mysql_free_result($result); 105 | } 106 | else { 107 | die("Query failed"); 108 | } 109 | } 110 | 111 | //If there are input validations, redirect back to the registration form 112 | if($errflag) { 113 | $_SESSION['ERRMSG_ARR'] = $errmsg_arr; 114 | session_write_close(); 115 | header("location: register.php"); 116 | exit(); 117 | } 118 | 119 | //Create INSERT query 120 | $qry = "INSERT INTO members(firstname, lastname, login, mail, passwd) VALUES('$fname','$lname','$login','$mail','".md5($_POST['password'])."')"; 121 | $result = @mysql_query($qry); 122 | 123 | //Check whether the query was successful or not 124 | if($result) { 125 | header("location: register-success.php"); 126 | exit(); 127 | }else { 128 | die("Query failed"); 129 | } 130 | ?> -------------------------------------------------------------------------------- /register.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Register - ecDB 13 | 14 | 15 | 16 | 17 | 18 |
    19 | 20 | 21 | 26 | 27 | 28 | 29 | 37 | 38 | 39 | 40 |
    41 | 42 | 0 ) { 44 | echo '
    '; 45 | echo '
      '; 46 | foreach($_SESSION['ERRMSG_ARR'] as $msg) { 47 | echo '
    • ',$msg,'
    • '; 48 | } 49 | echo '
    '; 50 | echo '
    '; 51 | unset($_SESSION['ERRMSG_ARR']); 52 | } 53 | ?> 54 |
    55 |
    56 |
    57 | You want to build something and need some components for your project. 58 | You don't know if you have those components, or where they are. 59 | This is a problem many of us recognise. 60 | We want to change that for you by making a online inventory system for your electronic components that is easy to use. 61 | Add your components. Search to find it, and then use it! 62 |
    63 |
    64 |
    65 | 66 |
    67 |
    68 |
    69 | 70 |
    71 |
    72 |
    73 | 74 |
    75 |
    76 |
    77 | 78 |
    79 |
    80 |
    81 | 82 |
    83 |
    84 |
    85 | 86 |
    87 |
    88 |
    89 | By registering you accept the Terms and Contidions.

    90 |
    91 | 92 |
    93 |
    94 |
    95 |
    96 |
    97 |
    98 |
    99 | 100 | 101 | 102 | 103 | 104 | 105 |
    106 | 107 | 108 | -------------------------------------------------------------------------------- /login.php: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | ecDB - electronics component DataBase 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 |
    30 | 31 | 32 | 37 | 38 | 39 | 40 | 48 | 49 | 50 | 51 |
    52 |
    53 | 0 ) { 55 | echo '
    '; 56 | echo '
      '; 57 | foreach($_SESSION['ERRMSG_ARR'] as $msg) { 58 | echo '
    • ',$msg,'
    • '; 59 | } 60 | echo '
    '; 61 | echo '
    '; 62 | unset($_SESSION['ERRMSG_ARR']); 63 | } 64 | ?> 65 |
    66 | 67 |
    68 |
    69 |
    70 | 80 |
    81 |
    82 |
    83 | You want to build something and need some components for your project. 84 | You don't know if you have those components, or where they are. 85 | This is a problem many of us recognise. 86 | We want to change that for you by making a online inventory system for your electronic components that is easy to use. 87 | Add your components. Search to find it, and then use it! 88 |
    89 | 90 |
    91 |
    92 | 93 |
    To try ecDB, login with demo:demo
    94 |
    95 |
    96 | 97 |
    98 |
    99 |
    100 |
    101 | 102 |
    103 |
    104 |
    105 |
    106 |
    107 |
    108 |
    109 | 110 | 111 | 112 | 113 | 114 | 115 |
    116 | 117 | 118 | -------------------------------------------------------------------------------- /about.php: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | About - ecDB 12 | 13 | 14 | 15 | 16 |
    17 | 18 | 19 | 24 | 25 | 26 | 27 | 35 | 36 | 37 | 38 |
    39 |
    40 |
    41 |
    42 | Check out the new ecDB blog. Or follow @ecDBnet at Twitter to get the latest updates! 43 |
    44 |

    What is ecDB?

    45 | 46 | ecDB is basically a place where you, as an electronics hobbyist (or professional) can add your own components to your personal database to keep track of what components you own, where they are, how many you own and so on. 47 | 48 |

    49 | 50 |

    51 |

    Who & Why?

    52 | 53 | ecDB is created by Nils Fredriksson and designed by Buildlog.

    54 | 55 | Me, Nils, have always wanted to have a system like this to keep track of what component I own. Before I created this system I (I guess you too...) had to dig through boxes filled with components to maybe find that component I needed. This is an unnecessary task to do, it not only takes time, and it also can be really frustrating not to find that component you are looking for. So I ended up creating this website where I easily can keep track of my components! 56 | 57 |

    58 |

    What does it cost?

    59 | 60 | ecDB is completely free!
    61 | But if you like ecDB you can use this button to donate us some money. 62 |
    63 | 64 | 65 | 66 |
    67 | 68 |
    69 |

    Is ecDB really done?

    70 | No! ecDB is still under development. Here are some of the upcoming features:

    71 | 72 | - Public components - a place where you easily can trade components.
    73 | - View to physically print the personal database. Old-school typewritten text and nice colums!
    74 | - Datasheet and picture uploading.
    75 | - Advanced component search with parameters.
    76 | - Log for each component. See when the component last was used/edited/bought etc.
    77 | - Barcode implementation for easy storage management.
    78 | - Import and export of personal database to text/spreadsheet.
    79 | - Quick edit function of component data directly from the database view.
    80 | - Add personal categories and fields.
    81 | - Borrow component data from other components in the database to easily add components. 82 |
    83 |
    84 |
    85 |
    86 | 87 | 88 | 89 | 90 | 91 | 92 |
    93 | 94 | -------------------------------------------------------------------------------- /terms.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Terms & Privacy - ecDB 13 | 14 | 15 | 16 |
    17 | '; 20 | include 'include/header.php'; 21 | echo ''; 22 | 23 | echo ''; 24 | include 'include/menu.php'; 25 | echo ''; 26 | } 27 | else { 28 | echo ''; 29 | include 'include/header_public.php'; 30 | echo ''; 31 | 32 | echo ''; 33 | include 'include/menu_public.php'; 34 | echo ''; 35 | } 36 | ?> 37 | 38 |
    39 |

    Terms and Conditions & Privacy Policy

    40 | 41 |

    1. Terms

    42 | 43 | By accessing this web site, you are agreeing to be bound by these web site Terms and Conditions of Use, all applicable laws and regulations, and agree that you are responsible for compliance with any applicable local laws. If you do not agree with any of these terms, you are prohibited from using or accessing this site. The materials contained in this web site are protected by applicable copyright and trademark law.

    44 | 45 |

    2. Membership

    46 | 47 | As a condition to using the services you are required to register with ecDB. By registering with ecDB you certify that you always provide valid, and updated information, you are an individual (i.e., not a corporate entity) and that you have the legal rights to enter such an agreement. The ID and password (from now referred to as "login-data") is the sole responsibility. It is required that you, as a registered ecDB user maintain the safety of your own login-data.

    48 | 49 | ecDB maintains the right to terminate your membership at any time, with or without motivation or warning. All members are responsible for the consequences of use of this website. In cases of conflict with one or more non-members or members, will ecDB not be liable for any damages caused, in the current situation or future, resulting from the conflict.

    50 | 51 | As a registered ecDB user you warrant and agree to the fact that you will not contribute any content that (a) infringes, violates or otherwise interferes with any copyright or trademark of another party, (b) reveal any trade secret, unless you own the trade secret or has the owner’s permission to post it, (c) infringes any intellectual property right of another or the privacy or publicity rights of another, (d) is libelous, defamatory, abusive, threatening, harassing, hateful, offensive or otherwise violates any law or right of any third party.

    52 | 53 |

    3. Disclaimer

    54 | 55 | ecDB reserves all rights and disclaims all liability. ecDB makes no guarantee of reliability, safety or operation of this site.
    56 | As a registered user, you have full responsibility, without contradiction, for the information you publish and make widely available here.

    57 | 58 |

    4. Ownership

    59 | 60 | It is strictly forbidden to copy, distribute, or modify any material from ecDB. You may print material for private use. For all other use requires permission from ecDB.

    61 | 62 |

    5. Site Terms of Use Modifications

    63 | 64 | ecDB may revise these terms of use at any time without notice. By using ecDB you are agreeing to be bound by the then current version of these Terms and Conditions of Use.

    65 | 66 |

    Privacy Policy

    67 | 68 | ecDB handles your personal information in accordance with the European data protection laws.

    69 | 70 | Third parties can get access to all the information you intended to make public through your settings. Your email address or other personal data is NEVER shared by us to third parties. 71 |
    72 | 73 | 74 | 75 | 76 |
    77 | 78 | 79 | -------------------------------------------------------------------------------- /include/include_proj_show.php: -------------------------------------------------------------------------------- 1 | "; 41 | 42 | echo ''; 45 | 46 | echo ''; 49 | 50 | echo $showDetails['name']; 51 | echo ""; 52 | 53 | echo ""; 54 | 55 | if ($showDetails['category'] < 999) { 56 | $head_cat_id = substr($showDetails['category'], -3, 1); 57 | } 58 | else { 59 | $head_cat_id = substr($showDetails['category'], -4, 2); 60 | } 61 | $subcatid = $showDetails['category']; 62 | 63 | $CategoryName = "SELECT * FROM category_head WHERE id = ".$head_cat_id.""; 64 | $sql_exec_catname = mysql_Query($CategoryName); 65 | 66 | while($showDetailsCat = mysql_fetch_array($sql_exec_catname)) { 67 | $catname = $showDetailsCat['name']; 68 | } 69 | 70 | echo $catname; 71 | echo ""; 72 | 73 | echo ""; 74 | $manufacturer = $showDetails['manufacturer']; 75 | if ($manufacturer == ""){ 76 | echo "-"; 77 | } 78 | else{ 79 | echo $manufacturer; 80 | } 81 | echo ""; 82 | 83 | echo ""; 84 | $package = $showDetails['package']; 85 | if ($package == ""){ 86 | echo "-"; 87 | } 88 | else{ 89 | echo $package; 90 | } 91 | echo ""; 92 | 93 | echo ""; 94 | $smd = $showDetails['smd']; 95 | if ($smd == "No"){ 96 | echo ''; 97 | } 98 | else{ 99 | echo ''; 100 | } 101 | echo ""; 102 | 103 | echo ""; 104 | $price = $showDetails['price']; 105 | if ($price == ""){ 106 | echo "-"; 107 | } 108 | else{ 109 | echo $price; 110 | } 111 | echo ""; 112 | 113 | echo ""; 114 | $quantity = $showDetails['quantity']; 115 | if ($quantity == ""){ 116 | echo "-"; 117 | } 118 | else{ 119 | echo $quantity; 120 | } 121 | echo ""; 122 | 123 | echo ""; 124 | 125 | $comp_id = $showDetails['id']; 126 | $ShowQuant = mysql_query("SELECT projects_data_quantity FROM projects_data WHERE projects_data_component_id = '$comp_id' AND projects_data_project_id = '$project_id'"); 127 | $quant = mysql_fetch_assoc($ShowQuant); 128 | 129 | $quantity = $quant['projects_data_quantity']; 130 | if ($quantity == ""){ 131 | echo "-"; 132 | } 133 | else{ 134 | echo $quantity; 135 | } 136 | 137 | 138 | echo ""; 139 | 140 | echo ""; 141 | } 142 | } 143 | } 144 | ?> 145 | -------------------------------------------------------------------------------- /shoplist.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | Shopping list - ecDB 15 | 16 | 17 | 18 | 19 |
    20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 |
    28 | 29 | 30 | 31 | 32 | 33 | 34 | 36 | 51 | 66 | 81 | 95 | 110 | 125 | 140 | 143 | 144 | 145 | 146 | ShoplistList(); 150 | ?> 151 | 152 |
    35 | Name 50 | Manufacturer 65 | Package 80 | SMD 94 | Price 109 | Quantity 124 | Quantity to order 139 | 141 | Comment 142 |
    153 |
    154 | ShoplistPriceSum(); 158 | ?> 159 |
    160 |
    161 | 162 | 163 | 164 | 165 |
    166 | 167 | 168 | -------------------------------------------------------------------------------- /index.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | Home - ecDB 15 | 16 | 17 | 18 | 19 |
    20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 |
    28 | 38 | 39 | 40 | 41 | 42 | 44 | 60 | 76 | 92 | 108 | 111 | 114 | 129 | 145 | 161 | 164 | 165 | 166 | 167 | Index(); 172 | ?> 173 | 174 |
    43 | 45 | Name 59 | 61 | Category 75 | 77 | Package 91 | 93 | Pins 107 | 109 | Image 110 | 112 | Datasheet 113 | 115 | SMD 128 | 130 | Price 144 | 146 | Quantity 160 | 162 | Comment 163 |
    175 |
    176 | 177 | 178 | 179 | 180 |
    181 | 182 | 183 | -------------------------------------------------------------------------------- /category.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Category - ecDB 13 | 14 | 15 | 16 | 17 |
    18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 |
    26 | 36 |
    37 |
      38 | Sub(); 43 | ?> 44 |
    45 |
    46 | 47 | 48 | 49 | 50 | 51 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | Category(); 105 | ?> 106 | 107 |
    NameCategoryPackagePinsImageDatasheetSMDPriceQuantityComment
    108 |
    109 | 110 | 111 | 112 | 113 |
    114 | 115 | 116 | -------------------------------------------------------------------------------- /search.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Home - ecDB 13 | 14 | 15 | 16 | 17 |
    18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 |
    26 |

    Search results

    27 | 28 | 29 | 30 | 31 | 32 | 48 | 64 | 80 | 96 | 112 | 115 | 118 | 133 | 149 | 165 | 168 | 169 | 170 | 171 | Search(); 176 | ?> 177 | 178 |
    33 | Name 47 | 49 | Category 63 | 65 | Manufacturer 79 | 81 | Package 95 | 97 | Pins 111 | 113 | Image 114 | 116 | Datasheet 117 | 119 | SMD 132 | 134 | Price 148 | 150 | Quantity 164 | 166 | Comment 167 |
    179 |
    180 | 181 | 182 | 183 | 184 |
    185 | 186 | 187 | -------------------------------------------------------------------------------- /include/include_proj_show_.php: -------------------------------------------------------------------------------- 1 | "; 49 | 50 | echo 'Edit'; 53 | 54 | echo ''; 57 | 58 | echo $showDetails['name']; 59 | echo ""; 60 | 61 | echo ""; 62 | 63 | if ($showDetails['category'] < 999) { 64 | $head_cat_id = substr($showDetails['category'], -3, 1); 65 | } 66 | else { 67 | $head_cat_id = substr($showDetails['category'], -4, 2); 68 | } 69 | $subcatid = $showDetails['category']; 70 | 71 | $CategoryName = "SELECT * FROM category_head WHERE id = ".$head_cat_id.""; 72 | $sql_exec_catname = mysql_Query($CategoryName); 73 | 74 | while($showDetailsCat = mysql_fetch_array($sql_exec_catname)) { 75 | $catname = $showDetailsCat['name']; 76 | } 77 | 78 | echo $catname; 79 | echo ""; 80 | 81 | echo ""; 82 | $manufacturer = $showDetails['manufacturer']; 83 | if ($manufacturer == ""){ 84 | echo "-"; 85 | } 86 | else{ 87 | echo $manufacturer; 88 | } 89 | echo ""; 90 | 91 | echo ""; 92 | $package = $showDetails['package']; 93 | if ($package == ""){ 94 | echo "-"; 95 | } 96 | else{ 97 | echo $package; 98 | } 99 | echo ""; 100 | 101 | echo ""; 102 | $pins = $showDetails['pins']; 103 | if ($pins == ""){ 104 | echo "-"; 105 | } 106 | else{ 107 | echo $pins; 108 | } 109 | echo ""; 110 | 111 | echo ''; 112 | $image = $showDetails['url1']; 113 | if ($image==""){ 114 | echo "-"; 115 | } 116 | else{ 117 | echo ''; 122 | } 123 | 124 | echo ''; 125 | $datasheet = $showDetails['datasheet']; 126 | if ($datasheet==""){ 127 | echo "-"; 128 | } 129 | else{ 130 | echo 'Download PDF'; 133 | } 134 | 135 | echo ""; 136 | $smd = $showDetails['smd']; 137 | if ($smd == "No"){ 138 | echo ''; 139 | } 140 | else{ 141 | echo ''; 142 | } 143 | echo ""; 144 | 145 | echo ""; 146 | $price = $showDetails['price']; 147 | if ($price == ""){ 148 | echo "-"; 149 | } 150 | else{ 151 | echo $price; 152 | } 153 | echo ""; 154 | 155 | echo ""; 156 | $quantity = $showDetails['quantity']; 157 | if ($quantity == ""){ 158 | echo "-"; 159 | } 160 | else{ 161 | echo $quantity; 162 | } 163 | echo ""; 164 | 165 | $comment = $showDetails['comment']; 166 | if ($comment==""){ 167 | echo '
    '; 168 | echo "-"; 169 | echo '
    '; 170 | } 171 | else{ 172 | echo '
    Comment'; 173 | echo $showDetails['comment']; 174 | echo '
    '; 175 | } 176 | echo ""; 177 | } 178 | } 179 | } 180 | } 181 | ?> -------------------------------------------------------------------------------- /contact_php_mail.php: -------------------------------------------------------------------------------- 1 | 8 | ' . "\r\n" . 'Reply-To: ' . $email; 57 | 58 | mail($emailTo, $subject, $body, $headers); 59 | $emailSent = true; 60 | } 61 | } 62 | ?> 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | Home - ecDB 71 | 72 | 73 | 74 | 75 | 76 | 81 | 82 | 83 | 84 |
    85 | '; 88 | include 'include/header.php'; 89 | echo ''; 90 | 91 | echo ''; 92 | include 'include/menu.php'; 93 | echo ''; 94 | } 95 | else { 96 | echo ''; 97 | echo ''; 102 | echo ''; 103 | 104 | echo ''; 105 | echo ''; 112 | echo ''; 113 | } 114 | ?> 115 | 116 |
    117 |

    Contact us

    118 | If you have a suggestion for ecDB please use this form to let us know about it!

    119 | 120 | '; 123 | echo 'Please check if you have filled all the fields with valid information.'; 124 | echo '
    '; 125 | } 126 | 127 | if(isset($emailSent) && $emailSent == true) { 128 | echo '
    '; 129 | echo 'Thank you '; 130 | echo $name; 131 | echo '!
    Your message was successfully sent.'; 132 | echo '
    '; 133 | } 134 | ?> 135 | 136 |
    137 |
    138 | 139 |
    140 |
    141 |
    142 | 143 |
    144 |
    145 |
    146 | 147 |
    148 |
    149 |
    150 | 151 |
    152 |
    153 |
    154 | 155 |
    156 | 157 |
    158 |
    159 |
    160 |
    161 | 162 |
    163 |
    164 |
    165 | 166 |
    167 | 168 | 169 | 170 | 171 | 172 | 173 | 174 | -------------------------------------------------------------------------------- /proj_show.php: -------------------------------------------------------------------------------- 1 | 9 | 10 | 11 | 12 | 13 | 14 | "/> 27 | 28 | 29 | 30 | Viewing project - <?php 31 | // Visar projektets namn. 32 | include('include/mysql_connect.php'); 33 | $project_id = mysql_real_escape_string($_GET["proj_id"]); 34 | $owner = $_SESSION['SESS_MEMBER_ID']; 35 | 36 | $result = mysql_query("SELECT project_name FROM projects WHERE project_owner = ".$owner." AND project_id = ".$project_id.""); 37 | 38 | while($row = mysql_fetch_array($result)) 39 | { 40 | echo $row['project_name']; 41 | } 42 | ?> - ecDB 43 | 44 | 45 | 46 | 47 |
    48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 |
    56 |

    Viewing project 57 | "; 68 | echo $row['project_name']; 69 | echo ""; 70 | } 71 | ?> 72 |

    73 | 74 | 75 | 76 | 77 | 78 | 94 | 110 | 126 | 142 | 157 | 173 | 189 | 205 | 206 | 207 | 208 | ProjectShowComponents(); 213 | ?> 214 | 215 |
    79 | Name 93 | 95 | Category 109 | 111 | Manufacturer 125 | 127 | Package 141 | 143 | SMD 156 | 158 | Price 172 | 174 | Quantity in stock 188 | 190 | Quantity in project 204 |
    216 | 217 |
    218 | ProjectSumTotal(); 223 | ?> 224 |
    225 |
    226 | 227 | 228 | 229 | 230 |
    231 | 232 | 233 | -------------------------------------------------------------------------------- /style.css: -------------------------------------------------------------------------------- 1 | /*-------------------------------------------*/ 2 | /* --------- Style for ______ -------------- */ 3 | /* ----------------------------------------- */ 4 | /* 5 | Created: 2010-09-03 6 | Last edit: 2012-01-28 7 | by Adis Kurtalic 8 | */ 9 | /* ----------------------------------------- */ 10 | /* ----------------------------------------- */ 11 | @import url('globalForms.css'); 12 | @import url('menu.css'); 13 | @import url('message.css'); 14 | @import url('header.css'); 15 | @import url('globalTables.css'); 16 | @import url('icons.css'); 17 | 18 | /* ----------------------------------------- */ 19 | /* ------------- Main colors --------------- */ 20 | /* ----------------------------------------- */ 21 | /* 22 | #1e68a6 23 | #f2f2f2 24 | #63bd20 25 | #666666 26 | 27 | */ 28 | /* ----------------------------------------- */ 29 | /* ----------------------------------------- */ 30 | /* ----------------------------------------- */ 31 | *{ 32 | margin: 0; 33 | padding: 0; 34 | } 35 | a{ 36 | color: #1e68a6; 37 | text-decoration: none; 38 | } 39 | a:focus { 40 | outline: none; 41 | } 42 | a:hover{ 43 | cursor:pointer; 44 | } 45 | a.sort{ 46 | color:#666; 47 | text-decoration:underline; 48 | } 49 | body{ 50 | color: #000; 51 | margin:0; 52 | letter-spacing:0.2px; 53 | padding:0; 54 | border-top:10px solid #74839C; 55 | background-color:#f8f8f8; 56 | font: normal 12px "Century Gothic", arial, sans-serif; 57 | } 58 | /* ----------------------------------------- */ 59 | /* ----------------------------------------- */ 60 | /* ----------------------------------------- */ 61 | h1{ 62 | font-size:16px; 63 | color:#333; 64 | font-weight:normal; 65 | padding:0 0 20px 0; 66 | } 67 | 68 | /* ----------------------------------------- */ 69 | /* ----------------------------------------- */ 70 | /* ----------------------------------------- */ 71 | div#wrapper{ 72 | padding:10px; 73 | width:900px; 74 | margin:auto; 75 | } 76 | /* ----------------------------------------- */ 77 | /* ----------------------------------------- */ 78 | /* ----------------------------------------- */ 79 | ul.error{list-style:none;} 80 | /* ----------------------------------------- */ 81 | /* ----------------------------------------- */ 82 | /* ----------------------------------------- */ 83 | .boldText{font-weight:bold;} 84 | /* ----------------------------------------- */ 85 | /* ----------------------------------------- */ 86 | /* ----------------------------------------- */ 87 | div#content{ 88 | background-color:#fff; 89 | position:relative; 90 | border-radius:6px; 91 | -moz-border-radius:6px; 92 | -webkit-border-radius:6px; 93 | border-bottom:2px solid #ccc; 94 | width:870px; 95 | margin:0 auto 0 auto; 96 | padding:15px 15px 35px 15px; 97 | } 98 | /* ----------------------------------------- */ 99 | /* ----------------------------------------- */ 100 | /* ----------------------------------------- */ 101 | div#copyText{ 102 | width:880px; 103 | font-size:11px; 104 | margin:10px auto 30px auto; 105 | padding:0 10px 0 10px; 106 | color:#444; 107 | height:25px; 108 | overflow:auto; 109 | line-height:20px; 110 | } 111 | div#copyText div.leftBox{ 112 | float:left; 113 | } 114 | div#copyText div.rightBox{ 115 | float:right; 116 | text-align:right; 117 | } 118 | /* ----------------------------------------- */ 119 | /* ------- Table style for My Components --- */ 120 | /* ----------------------------------------- */ 121 | table.myComponents{ 122 | width:100%; 123 | margin:10px 0 0 0; 124 | } 125 | table.myComponents tr{ 126 | } 127 | table.myComponents tr:hover{ 128 | background-color:#FAFAFA; 129 | } 130 | table.myComponents tr td{ 131 | text-align:center; 132 | padding:5px 0 5px 0; 133 | color:#777; 134 | } 135 | table.myComponents tr td.what{ 136 | font-weight:bold; 137 | color:#666; 138 | text-align:center; 139 | } 140 | table.myComponents tr:hover td.what{ 141 | background-color:#fff; 142 | } 143 | table.myComponents tr td.comment div{ 144 | position:relative; 145 | overflow:visible; 146 | } 147 | table.myComponents tr td.comment div span{ 148 | display:none; 149 | position:absolute; 150 | text-align:left; 151 | padding:10px; 152 | border-radius:6px; 153 | -moz-border-radius:6px; 154 | -webkit-border-radius:6px; 155 | -moz-box-shadow:0px 0px 5px #111; 156 | -webkit-box-shadow:0px 0px 5px #111; 157 | top:0; 158 | left:-100px; 159 | } 160 | table.myComponents tr td.comment:hover div span{ 161 | display:block; 162 | width:150px; 163 | background-color:#000; 164 | color:#fff; 165 | position:absolute; 166 | top:0; 167 | right:0; 168 | z-index:10; 169 | } 170 | table.myComponents tr td.edit a{ 171 | visibility:hidden; 172 | } 173 | table.myComponents tr:hover td.edit a{ 174 | visibility:visible; 175 | } 176 | /* ----------------------------------------- */ 177 | /* ----------------------------------------- */ 178 | /* ----------------------------------------- */ 179 | .totalSumWrapper{border-top:2px solid #444;padding:10px 0 0 0;font-size:16px;font-weight:bold;} 180 | /* ----------------------------------------- */ 181 | /* -------- View component tabel ----------- */ 182 | /* ----------------------------------------- */ 183 | table.viewComponent{ 184 | padding:10px 0 10px 0; 185 | } 186 | table.viewComponent tr{ 187 | } 188 | table.viewComponent tr td{ 189 | color:#777; 190 | height:25px; 191 | width:250px; 192 | } 193 | table.viewComponent tr td.what{ 194 | font-weight:bold; 195 | color:#666; 196 | width:120px; 197 | } 198 | /* ----------------------------------------- */ 199 | /* ----------------------------------------- */ 200 | /* ----------------------------------------- */ 201 | div.componentComment{ 202 | padding:0 0 15px 10px; 203 | color:#666; 204 | overflow:hidden; 205 | font-style:italic; 206 | border-bottom:1px dashed #DEDEDE; 207 | } 208 | /* ----------------------------------------- */ 209 | /* ----------------------------------------- */ 210 | /* ----------------------------------------- */ 211 | div.uploadedImags{border-top:1px dashed #DEDEDE;padding:15px 0 0 0;margin:15px 0 20px 0;text-align:right;} 212 | div.uploadedImags ul{list-style:none;} 213 | div.uploadedImags ul li{padding:15px;line-height:0;list-style:none;margin:0 0 0 10px;display:inline-block;background-color:#fff;border-radius:3px;-moz-border-radius:3px;-webkit-border-radius:3px;} 214 | div.uploadedImags ul li:hover{box-shadow:0 0 3px #666;-moz-box-shadow:0 0 3px #666;-webkit-box-shadow:0 0 3px #666;} 215 | div.uploadedImags ul li img{max-height:120px;} 216 | /* ----------------------------------------- */ 217 | /* ----------------------------------------- */ 218 | /* ----------------------------------------- */ 219 | 220 | 221 | /* ----------------------------------------- */ 222 | /* ----------------------------------------- */ 223 | /* ----------------------------------------- */ 224 | .submit { 225 | background: url(http://electricman.se/php/ecdb/img/button_submit.png) no-repeat; 226 | height: 24px; 227 | width: 80px; 228 | border: none; 229 | cursor: pointer; 230 | } 231 | 232 | /* ----------------------------------------- */ 233 | /* ----------------------------------------- */ 234 | /* ----------------------------------------- */ 235 | 236 | .main_category{background-color:#DCDCC3;font-weight:bold;} 237 | 238 | /* ----------------------------------------- */ 239 | /* ----------------------------------------- */ 240 | /* ----------------------------------------- */ 241 | 242 | #contact-wrapper { 243 | width:430px; 244 | border:1px solid #e2e2e2; 245 | background:#f1f1f1; 246 | padding:20px; 247 | } 248 | #contact-wrapper div { 249 | clear:both; 250 | margin:1em 0; 251 | } 252 | #contact-wrapper label { 253 | display:block; 254 | float:none; 255 | font-size:16px; 256 | width:auto; 257 | } 258 | form#contactform input { 259 | border-color:#B7B7B7 #E8E8E8 #E8E8E8 #B7B7B7; 260 | border-style:solid; 261 | border-width:1px; 262 | padding:5px; 263 | font-size:16px; 264 | color:#333; 265 | } 266 | form#contactform textarea { 267 | font-family:Arial, Tahoma, Helvetica, sans-serif; 268 | font-size:100%; 269 | padding:0.6em 0.5em 0.7em; 270 | border-color:#B7B7B7 #E8E8E8 #E8E8E8 #B7B7B7; 271 | border-style:solid; 272 | border-width:1px; 273 | } 274 | 275 | /* ----------------------------------------- */ 276 | /* ----------------------------------------- */ 277 | /* ----------------------------------------- */ 278 | div.loginWrapper{overflow:auto;} 279 | div.loginWrapper div.left{float:left;width:620px;} 280 | div.loginWrapper div.right{float:right;background:url("../img/indexBG.png") no-repeat center 0;width:240px;height:370px;} 281 | div.loginWrapper div.aboutECDB{margin:0 0 100px 0;} 282 | 283 | hr{ 284 | background-color:#999999; 285 | border:0 none; 286 | height:1px; 287 | margin:10px 0px; 288 | } 289 | 290 | -------------------------------------------------------------------------------- /ecdb.sql: -------------------------------------------------------------------------------- 1 | -- phpMyAdmin SQL Dump 2 | -- version 3.4.5 3 | -- http://www.phpmyadmin.net 4 | -- 5 | -- Värd: localhost 6 | -- Skapad: 04 nov 2012 kl 15:17 7 | -- Serverversion: 5.5.16 8 | -- PHP-version: 5.2.17 9 | 10 | SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; 11 | SET time_zone = "+00:00"; 12 | 13 | 14 | /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; 15 | /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; 16 | /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; 17 | /*!40101 SET NAMES utf8 */; 18 | 19 | -- 20 | -- Databas: `ecdb` 21 | -- 22 | 23 | -- -------------------------------------------------------- 24 | 25 | -- 26 | -- Tabellstruktur `category_head` 27 | -- 28 | 29 | CREATE TABLE IF NOT EXISTS `category_head` ( 30 | `id` int(11) NOT NULL, 31 | `name` varchar(64) NOT NULL 32 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 33 | 34 | -- 35 | -- Dumpning av Data i tabell `category_head` 36 | -- 37 | 38 | INSERT INTO `category_head` (`id`, `name`) VALUES 39 | (1, 'Cable'), 40 | (2, 'Capacitor'), 41 | (3, 'Connector'), 42 | (4, 'Diode'), 43 | (5, 'IC'), 44 | (6, 'Inductor'), 45 | (7, 'Mechanic'), 46 | (16, 'Module'), 47 | (8, 'Opto'), 48 | (18, 'Oscillator'), 49 | (13, 'Resistor'), 50 | (15, 'Sensor'), 51 | (10, 'Switch'), 52 | (11, 'Transformer'), 53 | (12, 'Transistor'), 54 | (14, 'Display'), 55 | (17, 'Miscellaneous'); 56 | 57 | -- -------------------------------------------------------- 58 | 59 | -- 60 | -- Tabellstruktur `category_sub` 61 | -- 62 | 63 | CREATE TABLE IF NOT EXISTS `category_sub` ( 64 | `id` int(11) NOT NULL, 65 | `name` varchar(64) NOT NULL 66 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8; 67 | 68 | -- 69 | -- Dumpning av Data i tabell `category_sub` 70 | -- 71 | 72 | INSERT INTO `category_sub` (`id`, `name`) VALUES 73 | (101, 'Ribbon'), 74 | (102, 'Coax'), 75 | (199, 'Misc'), 76 | (201, 'Ceramic'), 77 | (202, 'Electrolytic'), 78 | (203, 'Polyester'), 79 | (204, 'Tantalum'), 80 | (205, 'Variable'), 81 | (299, 'Misc'), 82 | (301, 'Audio'), 83 | (302, 'Coax'), 84 | (303, 'DC'), 85 | (304, 'D-Sub'), 86 | (399, 'Misc'), 87 | (401, 'Rectifier'), 88 | (402, 'Schottky'), 89 | (403, 'Small Signal'), 90 | (404, 'Zener'), 91 | (499, 'Misc'), 92 | (501, '4xxx'), 93 | (502, '74xx'), 94 | (503, 'Microcontroller'), 95 | (504, 'Comparator'), 96 | (505, 'Op. Amp.'), 97 | (506, 'Temperature'), 98 | (507, 'Timer & Osc.'), 99 | (508, 'Voltage Ref.'), 100 | (509, 'Voltage Reg.'), 101 | (599, 'Misc'), 102 | (601, 'Ferrite'), 103 | (602, 'Filter'), 104 | (603, 'Inductor'), 105 | (699, 'Misc'), 106 | (701, 'Box'), 107 | (702, 'Distance'), 108 | (703, 'Fuse'), 109 | (704, 'Motor'), 110 | (705, 'Screw'), 111 | (799, 'Misc'), 112 | (801, 'Reflex coupler'), 113 | (802, 'Laser'), 114 | (803, 'LED'), 115 | (804, 'LED 3mm'), 116 | (805, 'LED 5mm'), 117 | (806, 'Optocoupler'), 118 | (899, 'Misc'), 119 | (901, 'Crystal'), 120 | (902, 'Resonator'), 121 | (999, 'Misc'), 122 | (1001, 'Keypad'), 123 | (1002, 'Momentary'), 124 | (1003, 'PCB Mounted'), 125 | (1004, 'Rotary Encoder'), 126 | (1005, 'Toggle Switch'), 127 | (1099, 'Misc'), 128 | (1101, 'Power Supply'), 129 | (1102, 'Transformer'), 130 | (1103, 'Wall Adapter'), 131 | (1199, 'Misc'), 132 | (1201, 'BJT'), 133 | (1202, 'JFET'), 134 | (1203, 'MOSFET'), 135 | (1204, 'NPN'), 136 | (1205, 'PNP'), 137 | (1299, 'Misc'), 138 | (1301, '1/4W Carbon'), 139 | (1302, '1/4W Metal'), 140 | (1303, '1/6W Carbon'), 141 | (1304, '1/6W Metal'), 142 | (1305, '0603'), 143 | (1306, '0805'), 144 | (1307, '1206'), 145 | (1308, 'Effect'), 146 | (1309, 'Photo'), 147 | (1399, 'Misc'), 148 | (1601, 'GSM'), 149 | (1602, 'GPS'), 150 | (1699, 'Misc'), 151 | (1401, 'LCD'), 152 | (1402, 'VFD'), 153 | (1404, 'LED'), 154 | (1403, 'TFT'), 155 | (807, 'IR LED'), 156 | (1499, 'Misc'), 157 | (708, 'IC Socket'), 158 | (709, 'Heat Sink'), 159 | (510, 'Data Converter'), 160 | (511, 'A/D Multiplexer'), 161 | (512, 'Driver'), 162 | (513, 'Opto Driver'), 163 | (514, 'DC/DC Converter'), 164 | (515, 'Audio/Video'), 165 | (516, 'Memory'), 166 | (1311, 'Temperature'), 167 | (1310, 'Network'), 168 | (305, 'HF'), 169 | (710, 'Knob'), 170 | (711, 'Meter'), 171 | (103, 'Standard'), 172 | (104, 'Mains'), 173 | (105, 'Signal/Data'), 174 | (106, 'Fiber optic'), 175 | (306, 'PCB'), 176 | (1603, 'Bluetooth'), 177 | (1604, 'WLAN'), 178 | (1605, 'ZigBee'), 179 | (1606, 'RFID'), 180 | (307, 'Mains'), 181 | (1501, 'Moisture'), 182 | (1502, 'Temperature'), 183 | (1503, 'Pressure'), 184 | (1504, 'Magnetic'), 185 | (1505, 'Hall Effect'), 186 | (1506, 'Gas'), 187 | (1507, 'Accelerometer'), 188 | (1508, 'Light'), 189 | (1509, 'Proximity'), 190 | (1599, 'Misc'), 191 | (1799, 'Misc'), 192 | (517, 'Logic'), 193 | (1312, 'Potentiometer'), 194 | (1006, 'Relay'), 195 | (308, 'Data'), 196 | (1801, 'Crystal'), 197 | (1802, 'Resonator'), 198 | (1899, 'Misc'), 199 | (1007, 'DIP'), 200 | (406, 'Bridge'), 201 | (1206, 'Triac'), 202 | (1313, '1/3W Carbon'), 203 | (1314, '1/3W Metal'), 204 | (1315, 'Precision'); 205 | 206 | -- -------------------------------------------------------- 207 | 208 | -- 209 | -- Tabellstruktur `data` 210 | -- 211 | 212 | CREATE TABLE IF NOT EXISTS `data` ( 213 | `id` int(11) NOT NULL AUTO_INCREMENT, 214 | `owner` int(11) NOT NULL, 215 | `name` varchar(64) NOT NULL, 216 | `manufacturer` varchar(64) NOT NULL, 217 | `package` varchar(64) NOT NULL, 218 | `pins` varchar(11) NOT NULL, 219 | `smd` varchar(3) NOT NULL DEFAULT 'No', 220 | `quantity` varchar(11) NOT NULL, 221 | `order_quantity` varchar(11) NOT NULL, 222 | `location` varchar(32) NOT NULL, 223 | `scrap` varchar(3) NOT NULL DEFAULT 'No', 224 | `width` varchar(11) DEFAULT NULL, 225 | `height` varchar(11) DEFAULT NULL, 226 | `depth` varchar(11) DEFAULT NULL, 227 | `weight` varchar(11) DEFAULT NULL, 228 | `datasheet` varchar(256) NOT NULL, 229 | `comment` text NOT NULL, 230 | `category` varchar(11) NOT NULL, 231 | `public` varchar(3) NOT NULL DEFAULT 'No', 232 | `url1` varchar(256) NOT NULL, 233 | `url2` varchar(256) NOT NULL, 234 | `url3` varchar(256) NOT NULL, 235 | `url4` varchar(256) NOT NULL, 236 | `price` varchar(11) NOT NULL, 237 | KEY `Id` (`id`), 238 | KEY `owner` (`owner`) 239 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ; 240 | 241 | -- 242 | -- Dumpning av Data i tabell `data` 243 | -- 244 | 245 | INSERT INTO `data` (`id`, `owner`, `name`, `manufacturer`, `package`, `pins`, `smd`, `quantity`, `order_quantity`, `location`, `scrap`, `width`, `height`, `depth`, `weight`, `datasheet`, `comment`, `category`, `public`, `url1`, `url2`, `url3`, `url4`, `price`) VALUES 246 | (1, 4, '1N4148', 'ST', 'SOT-21', '2', 'No', '100', '20', 'Drawer', 'No', '', '', '', '', '', '', '401', 'Yes', '', '', '', '', '0.001'); 247 | 248 | -- -------------------------------------------------------- 249 | 250 | -- 251 | -- Tabellstruktur `members` 252 | -- 253 | 254 | CREATE TABLE IF NOT EXISTS `members` ( 255 | `member_id` int(11) NOT NULL AUTO_INCREMENT, 256 | `firstname` varchar(32) NOT NULL, 257 | `lastname` varchar(32) NOT NULL, 258 | `login` varchar(32) NOT NULL, 259 | `mail` varchar(32) NOT NULL, 260 | `passwd` varchar(32) NOT NULL, 261 | `admin` int(11) NOT NULL DEFAULT '0', 262 | `measurement` int(11) NOT NULL DEFAULT '1', 263 | `currency` varchar(3) NOT NULL DEFAULT 'USD', 264 | `reg_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, 265 | PRIMARY KEY (`member_id`) 266 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1800 ; 267 | 268 | -- 269 | -- Dumpning av Data i tabell `members` 270 | -- 271 | 272 | INSERT INTO `members` (`member_id`, `firstname`, `lastname`, `login`, `mail`, `passwd`, `admin`, `measurement`, `currency`) VALUES 273 | (4, 'Demo', 'Demo', 'demo', 'mail@mailen.com', 'fe01ce2a7fbac8fafaed7c982a04e229', 0, 1, 'USD'); 274 | 275 | -- -------------------------------------------------------- 276 | 277 | -- 278 | -- Tabellstruktur `members_stats` 279 | -- 280 | 281 | CREATE TABLE IF NOT EXISTS `members_stats` ( 282 | `members_stats_id` int(11) NOT NULL AUTO_INCREMENT, 283 | `members_stats_member` int(11) NOT NULL, 284 | `members_stats_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, 285 | PRIMARY KEY (`members_stats_id`) 286 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ; 287 | 288 | -- 289 | -- Dumpning av Data i tabell `members_stats` 290 | -- 291 | 292 | INSERT INTO `members_stats` (`members_stats_id`, `members_stats_member`, `members_stats_time`) VALUES 293 | (1, 4, '2012-11-04 14:14:36'); 294 | 295 | -- -------------------------------------------------------- 296 | 297 | -- 298 | -- Tabellstruktur `projects` 299 | -- 300 | 301 | CREATE TABLE IF NOT EXISTS `projects` ( 302 | `project_id` int(11) NOT NULL AUTO_INCREMENT, 303 | `project_owner` int(11) NOT NULL, 304 | `project_name` varchar(64) NOT NULL, 305 | PRIMARY KEY (`project_id`), 306 | KEY `project_owner` (`project_owner`) 307 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ; 308 | 309 | -- 310 | -- Dumpning av Data i tabell `projects` 311 | -- 312 | 313 | INSERT INTO `projects` (`project_id`, `project_owner`, `project_name`) VALUES 314 | (1, 4, 'Robot'); 315 | 316 | -- -------------------------------------------------------- 317 | 318 | -- 319 | -- Tabellstruktur `projects_data` 320 | -- 321 | 322 | CREATE TABLE IF NOT EXISTS `projects_data` ( 323 | `projects_data_id` int(11) NOT NULL AUTO_INCREMENT, 324 | `projects_data_owner_id` int(11) NOT NULL, 325 | `projects_data_project_id` int(11) NOT NULL, 326 | `projects_data_component_id` int(11) NOT NULL, 327 | `projects_data_quantity` int(11) NOT NULL, 328 | PRIMARY KEY (`projects_data_id`), 329 | KEY `owner_id` (`projects_data_owner_id`), 330 | KEY `project_id` (`projects_data_project_id`), 331 | KEY `component_id` (`projects_data_component_id`) 332 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ; 333 | 334 | -- 335 | -- Dumpning av Data i tabell `projects_data` 336 | -- 337 | 338 | INSERT INTO `projects_data` (`projects_data_id`, `projects_data_owner_id`, `projects_data_project_id`, `projects_data_component_id`, `projects_data_quantity`) VALUES 339 | (1, 4, 1, 1, 10); 340 | 341 | /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; 342 | /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; 343 | /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; 344 | -------------------------------------------------------------------------------- /add.php: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | Add component - ecDB 21 | 22 | 23 | 24 | 25 | 26 | 36 | 46 | 56 | 57 | 58 | 59 | 60 |
    61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 |
    72 | 73 | 74 | Add(); 78 | ?> 79 | 80 | 81 |
    82 |
    83 | 84 |
    85 | 86 |
    87 |
    88 | 89 | 90 | 91 | 94 | 97 | 100 | 110 | 113 | 116 | 117 | 118 | 121 | 124 | 127 | 130 | 133 | 136 | 137 | 138 | 141 | 144 | 147 | 150 | 153 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 166 | 169 | 181 | 184 | 196 | 199 | 211 | 212 | 213 | 214 | 215 | 216 | 217 | 218 | 219 | 220 | 221 | 224 | 227 | 230 | 233 | 234 | 235 | 236 | 237 | 238 | 239 | 242 | 245 | 246 | 247 | 248 | 249 | 252 | 255 | 258 | 261 | 262 | 263 | 264 | 265 | 266 | 267 | 268 | 269 | 270 | 271 | 272 | 273 | 274 | 275 | 278 | 281 | 284 | 287 | 289 | 291 | 292 | 293 | 296 | 299 | 302 | 305 | 307 | 309 | 310 | 311 | 312 | 315 | 318 | 319 | 320 | 321 | 322 | 323 | 324 | 333 | 336 | 337 | 338 | 339 | 340 | 341 |
    92 | Name 93 | 95 | 96 | 98 | Category 99 | 101 | 109 | 111 | Quantity 112 | 114 | 115 |
    119 | Manufacturer 120 | 122 | 123 | 125 | Package 126 | 128 | 129 | 131 | Pins 132 | 134 | 135 |
    139 | Location 140 | 142 | 143 | 145 | Price 146 | 148 | 149 | 151 | To order 152 | 154 | 155 |
    167 | SMD 168 | 170 | Yes '; 173 | echo ' No'; 174 | } 175 | else{ 176 | echo ' Yes '; 177 | echo ' No'; 178 | } 179 | ?> 180 | 182 | Scrap 183 | 185 | Yes '; 188 | echo ' No'; 189 | } 190 | else{ 191 | echo ' Yes '; 192 | echo ' No'; 193 | } 194 | ?> 195 | 197 | Public 198 | 200 | Yes '; 203 | echo ' No'; 204 | } 205 | else{ 206 | echo ' Yes '; 207 | echo ' No'; 208 | } 209 | ?> 210 |
    222 | Weight 223 | 225 | 226 | 228 | Width 229 | 231 | 232 |
    240 | Depth 241 | 243 | 244 |
    250 | Datasheet URL 251 | 253 | 254 | 256 | Height 257 | 259 | 260 |
    276 | Image URL 1 277 | 279 | 280 | 282 | Image URL 2 283 | 285 | 286 | 288 | 290 |
    294 | Image URL 3 295 | 297 | 298 | 300 | Image URL 4 301 | 303 | 304 | 306 | 308 |
    313 | Add component to project 314 | 316 | Quantity 317 |
    325 | 332 | 334 | 335 |
    342 |
    343 |
    344 | 345 |
    346 |
    347 |
    348 |
    349 | 350 | 351 | 352 | 353 |
    354 | 355 | -------------------------------------------------------------------------------- /add_based.php: -------------------------------------------------------------------------------- 1 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | Add component - ecDB 55 | 56 | 57 | 58 | 59 |
    60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 |
    71 | 72 |

    Add new component based on

    73 | 74 | Add(); 78 | ?> 79 | 80 |
    81 |
    82 | 83 |
    84 | 85 |
    86 |
    87 | 88 | 89 | 90 | 93 | 96 | 99 | 134 | 137 | 140 | 141 | 142 | 145 | 148 | 151 | 154 | 157 | 160 | 161 | 162 | 165 | 168 | 171 | 174 | 177 | 180 | 181 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | 193 | 205 | 208 | 220 | 223 | 235 | 236 | 237 | 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 248 | 251 | 254 | 257 | 258 | 259 | 260 | 261 | 262 | 265 | 268 | 269 | 270 | 271 | 272 | 275 | 278 | 281 | 284 | 285 | 286 | 287 | 288 | 289 | 290 | 291 | 292 | 293 | 294 | 295 | 296 | 297 | 300 | 303 | 306 | 309 | 311 | 313 | 314 | 315 | 318 | 321 | 324 | 327 | 329 | 331 | 332 | 333 | 334 | 337 | 340 | 341 | 342 | 343 | 344 | 345 | 346 | 355 | 358 | 359 | 360 | 361 | 362 | 363 |
    91 | Name 92 | 94 | 95 | 97 | Category 98 | 100 | 133 | 135 | Quantity 136 | 138 | 139 |
    143 | Manufacturer 144 | 146 | 147 | 149 | Package 150 | 152 | 153 | 155 | Pins 156 | 158 | 159 |
    163 | Location 164 | 166 | 167 | 169 | Price 170 | 172 | 173 | 175 | To order 176 | 178 | 179 |
    191 | SMD 192 | 194 | Yes '; 197 | echo ' No'; 198 | } 199 | else{ 200 | echo ' Yes '; 201 | echo ' No'; 202 | } 203 | ?> 204 | 206 | Scrap 207 | 209 | Yes '; 212 | echo ' No'; 213 | } 214 | else{ 215 | echo ' Yes '; 216 | echo ' No'; 217 | } 218 | ?> 219 | 221 | Public 222 | 224 | Yes '; 227 | echo ' No'; 228 | } 229 | else{ 230 | echo ' Yes '; 231 | echo ' No'; 232 | } 233 | ?> 234 |
    246 | Weight 247 | 249 | 250 | 252 | Width 253 | 255 | 256 |
    263 | Depth 264 | 266 | 267 |
    273 | Datasheet URL 274 | 276 | 277 | 279 | Height 280 | 282 | 283 |
    298 | Image URL 1 299 | 301 | 302 | 304 | Image URL 2 305 | 307 | 308 | 310 | 312 |
    316 | Image URL 3 317 | 319 | 320 | 322 | Image URL 4 323 | 325 | 326 | 328 | 330 |
    335 | Add component to project 336 | 338 | Quantity 339 |
    347 | 354 | 356 | 357 |
    364 |
    365 |
    366 | 367 |
    368 |
    369 |
    370 |
    371 | 372 | 373 | 374 | 375 | 376 |
    377 | 378 | 379 | --------------------------------------------------------------------------------