From 782523510a048f6a2a591cedf8b4cdd2daa6d703 Mon Sep 17 00:00:00 2001 From: Photosynthesis Date: Mon, 23 Sep 2013 16:01:36 -0700 Subject: [PATCH 1/9] Update README.md --- README.md | 34 ++++++++++++++++++++++++++++++++-- 1 file changed, 32 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9f8450b..e8d8959 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,34 @@ -datagridle +Datagridle ========== -An ultra-rapid PHP/MySQL database content editing interface. +###Readme +Datagridle is a rapidly-deployable, feature-rich and customizable open-source database content editing system. It is built to be embedded as an admin interface in other applications, or used as a stand-alone database editor. + +Please send bug reports and feature requests by email to adam@photosynth.ca, or on our Github repo at https://github.com/Photosynthesis/Datagridle + +For documentation, please see [http://www.photosynth.ca/code/datagridle/docs](http://www.photosynth.ca/code/datagridle/docs). + +###Ultra-rapid development: create a full-featured DB interface with just a few lines of code. +Using just the table name and DB info, Datagridle can create a feature-packed DB backend interface for use in custom applications and modules. + +###Super embeddable +Datagridle is designed to be seamlessly embedded into other applications. It uses unique GET prefixes for URL variables to eliminate conflicts within an application, and preserves all existing URL variables. This makes it a breeze to integrate into existing applications, plugins, or modules. HTML headers can be turned on or off, enabling either stand-alone or embedded operation. + +###Highly customizable +- Define callback functions for display, editing, or saving for any specific field +- Allow or deny editing, adding, or deleting records with permissions settings +- Use template display types with data placeholders to display images, hyperlinks, and more in the grid +- Specify style information for edit and display of individual fields +- Built-in TinyMCE wysiwyg content editor +- Advanced form fields such as calendar date selector and multiple checkbox + +###Multi-table capable +Parent and child table relationships can be defined to allow editing of child records through a pop-out sub-grid, and population of descriptive fields from a parent table into foreign key fields. + +###Comes with standard features too +Compact search, pagination and sorting functions give your users control of the grid. + +###Caveats +Your application must take care of user control and authentication. +Datagridle has not been tested on very large data sets, and has not been optimized for this. If you use it for editing a large table (> 10,000 records) please let us know, and report any performance issues. + From a8725a9602df1539ce52ea176ecec13492b5de24 Mon Sep 17 00:00:00 2001 From: omphalosskeptic Date: Sat, 28 Sep 2013 19:47:03 -0700 Subject: [PATCH 2/9] Update dg_paths.php MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit You have the default path using the old name, 'datagrid', instead of what folks get when they download it now — 'Datagridle'. This fixes it. --- dg_paths.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dg_paths.php b/dg_paths.php index 236813d..6b3c3f7 100644 --- a/dg_paths.php +++ b/dg_paths.php @@ -3,9 +3,9 @@ // Use absolute paths for client-side files (CSS and JS) to enable grids at different levels of client side depth $this->paths = array( - css_path => '/common/libraries/datagrid/css/', - js_path => '/common/libraries/datagrid/js/', - tiny_mce_path => '/common/libraries/datagrid/js/tiny_mce/', + css_path => '/common/libraries/Datagridle/css/', + js_path => '/common/libraries/Datagridle/js/', + tiny_mce_path => '/common/libraries/Datagridle/js/tiny_mce/', classes_path => '../../../' ); From 870000828bb0e0e8030cc23676a816de054aeeec Mon Sep 17 00:00:00 2001 From: omphalosskeptic Date: Sun, 29 Sep 2013 22:18:29 -0700 Subject: [PATCH 3/9] The new theme and fonts --- css/datagrid.css | 165 +++++++++++++++++++++++++++++++--------- datagrid.class.php | 18 ++--- dg_paths.php | 6 +- fonts/custom-icons.eot | Bin 0 -> 2354 bytes fonts/custom-icons.svg | 14 ++++ fonts/custom-icons.ttf | Bin 0 -> 2160 bytes fonts/custom-icons.woff | Bin 0 -> 1508 bytes js/datagrid.js | 8 +- 8 files changed, 160 insertions(+), 51 deletions(-) create mode 100644 fonts/custom-icons.eot create mode 100644 fonts/custom-icons.svg create mode 100644 fonts/custom-icons.ttf create mode 100644 fonts/custom-icons.woff diff --git a/css/datagrid.css b/css/datagrid.css index 6d2d42f..bcc2de7 100644 --- a/css/datagrid.css +++ b/css/datagrid.css @@ -1,8 +1,9 @@ /* CSS for non table-specific stuff */ body{ - font-family: arial; - color:color: #449977; + font-family: Ubuntu, helvetica; + color: #333; + font-size: 18px; } @@ -47,64 +48,74 @@ button.query{ } #dg_edit_buttons input{ - margin:2px; - padding: 1px; - border: 1px solid #999999; + margin: 3px; + padding-right:5px; + border: none; float: left; + background: none; + cursor: pointer; } input.update{ - background-color: #ffffff; + font-size: 1.6em !important; + color:#117; } input.delete{ - background-color: #eeccbb; + color:#711; + } input.copy{ - background-color: #bbffbb; - padding-top: -2px; - font-family: arial; - line-height: 12px; - padding: 0px; + color:#161; } input.update:hover{ - background-color: #aabbee; + color: #39f; } input.delete:hover{ - background-color: red; + color:red; } input.copy:hover{ - background-color: #449944; + color:#0d0; } /* Table display styles */ td.dataheader, td.dataheadersort{ padding: 0px; + border-collapse: collapse; } + +.add_button{ + padding-left: 0 !important; +} + a.dataheader, a.dataheadersort{ padding: 1px 3px 1px 3px; font-weight: bold; display:block; - font-family: arial; + font-family: Ubuntu, hevetica, arial; text-decoration: none; text-align: center; + border-left:1px solid #ddd; } a.dataheader{ - color: #556699; - background-color:#EBEADB; - border-bottom: 2px solid #dd9933; + color: #666; + background-color:#eee; + border-bottom: 2px solid #888; + padding:5px; + } a.dataheader:hover{ - background-color:#cBcAdB; + background-color:#777; color: #ffffff; } a.dataheadersort{ - border-bottom: 2px solid red; - background-color:#EBEADB; - color: #000000; + border-bottom: 2px solid #dd4814; + background-color:#888; + color: #ffffff; + padding: 5px; } span.dataheader{ padding: 1px 3px 1px 3px; @@ -116,6 +127,7 @@ span.dataheader{ text-align: center; background-color:#EBEADB; border-bottom: 2px solid #dd9933; + border-collapse: collapse; } span.help{ cursor: help; @@ -124,28 +136,36 @@ span.help{ table.datatable{ background-color: #ffffff; font-size: 13px; + border-collapse: collapse; } td.datafield{ padding: 3 8 3 8px; + border:1px solid #ddd; + margin:0; } .datafield2{ - background-color: #faf5ed; + background-color: #eee; } + tr.datafield1:hover, tr.datafield2:hover{ background-color: #caf5cd; border: 1px solid black; } .hidefield{ - font-family: arial; - margin-top: 1px; + font-family: Ubuntu, helvetica, arial; display: block; - background-color: #ccddee; + background-color: #bbb; + color:#fff; + border-collapse: collapse; + padding: 2px; font-weight:bold; font-size: 11px; text-align: center; text-decoration: none; + border-right: 1px solid #ddd; + /*box-shadow: 0px 5px 5px 0px gray;*/ } @@ -221,18 +241,33 @@ input.query, select.query{ background-color:#eeeeee; } -input.dg_add{ - background-color:#ccffcc; - border: 1px solid #999999; - margin: 0px; - float:none +.dg_add { + height: 45px; + width: 100%; + border-collapse: collapse; + background: #3e779d; + background: -webkit-gradient(linear, left top, left bottom, from(#ccc), to(#999)); + background: -moz-linear-gradient(top, #ccc, #999); + padding: 5px 10px; + border-radius: 2px; + border:none; + text-shadow: rgba(255,255,255,.4) 0 1px 0; + color: black; + font-size: 14px; + text-decoration: none; + vertical-align: middle; +} +.dg_add:hover { + border-top-color: #28597a; + background: #888; + color:white; + box-shadow: 0 0 5px 2px #666 inset; +} +.dg_add:active { + border-top-color: #1b435e; + background: #1b435e; + outline: 0; } - -button.dg_add:hover{ - background-color: #44cc88; - margin: 0px; -} - .querybox{ margin-top: 20px; background-color: #fcfcfc; @@ -291,3 +326,57 @@ button.dg_add:hover{ #close_window_button: hover{ } + + +/* THE ICON FONT */ + +@charset "UTF-8"; + +@font-face { + font-family: "custom-icons"; + src:url("/common/libraries/Datagridle/fonts/custom-icons.eot"); + src:url("/common/libraries/Datagridle/fonts/custom-icons.eot?#iefix") format("embedded-opentype"), + url("/common/libraries/Datagridle/fonts/custom-icons.ttf") format("truetype"), + url("/common/libraries/Datagridle/fonts/custom-icons.svg#custom-icons") format("svg"), + url("/common/libraries/Datagridle/fonts/custom-icons.woff") format("woff"); + font-weight: normal; + font-style: normal; + +} + + +[class^="icon-"], +[class*=" icon-"], +.icon { + font-family: "custom-icons"; + font-style: normal; + font-weight: normal; + font-variant: normal; + text-transform: none !important; + speak: none; + display: inline-block; + text-decoration: none; + width: 1em; + font-size: 1.5em; + line-height: 1em; + -webkit-font-smoothing: antialiased; +} + + +/* +.icon-edit:before { + content: "a"; +} + +.icon-delete:before { + content: "b"; +} + +.icon-new:before { + content: "c"; +} + +.icon-search:before { + content: "d"; +} +*/ \ No newline at end of file diff --git a/datagrid.class.php b/datagrid.class.php index 34b40a9..f2948a0 100644 --- a/datagrid.class.php +++ b/datagrid.class.php @@ -932,7 +932,7 @@ private function make_grid(){ $trend = ' '; - $out .= '
'; + $out .= '"; + target_url->get($this->GET_pfx()."hide_field=$fid")."\">» hide «"; }else{ $columnhead = " "; } $out .= $columnhead; @@ -1142,7 +1142,7 @@ function edit_form($id){ $out .= $this->target_url->get_hidden_inputs(); $out .= " GET_pfx()."action\" value=\"copy\" /> - + $keyinput "; @@ -1154,7 +1154,7 @@ function edit_form($id){ $out .= $this->target_url->get_hidden_inputs(); $out .= " GET_pfx()."action\" value=\"edit\" /> - + $keyinput "; @@ -1166,7 +1166,7 @@ function edit_form($id){ $out .= " GET_pfx()."action\" value=\"delete\" /> $keyinput - + "; } @@ -1176,11 +1176,11 @@ function edit_form($id){ function start_row($keyval,$oddrow){ if($oddrow == 1){ - $bg = 'f4efdd'; + $bg = 'fdfdfd'; }else{ - $bg = 'faf5ed'; + $bg = 'f8f8f8'; } - return "rowcount."\" bgcolor=\"#$bg\" onClick=\"highlightRow('".$this->rowcount."','#$bg')\">"; + return "rowcount."\" cellspacing=\"0\" bgcolor=\"#$bg\" onClick=\"highlightRow('".$this->rowcount."','#$bg')\">"; } diff --git a/dg_paths.php b/dg_paths.php index 236813d..6b3c3f7 100644 --- a/dg_paths.php +++ b/dg_paths.php @@ -3,9 +3,9 @@ // Use absolute paths for client-side files (CSS and JS) to enable grids at different levels of client side depth $this->paths = array( - css_path => '/common/libraries/datagrid/css/', - js_path => '/common/libraries/datagrid/js/', - tiny_mce_path => '/common/libraries/datagrid/js/tiny_mce/', + css_path => '/common/libraries/Datagridle/css/', + js_path => '/common/libraries/Datagridle/js/', + tiny_mce_path => '/common/libraries/Datagridle/js/tiny_mce/', classes_path => '../../../' ); diff --git a/fonts/custom-icons.eot b/fonts/custom-icons.eot new file mode 100644 index 0000000000000000000000000000000000000000..4d885e0fb9365245c82e0245ea33cb3121f3f60b GIT binary patch literal 2354 zcmcgtO=ufO6n<}awY#zu%W}NCssAE*^^;VQV@uYmmg8E`MCngTjGcxwX=vrhc1-+- z?SR`$4ed3}p^!tNPy#&}N_!}wX2Fk)yG)24HTA(O7oDc<0q>>rv`A|-hc-{s zRG~D@(2{FQ(;$GsM|6{p1Ghq}7$a~Ip!#V5$Y;j_NGxXuZIDdkrP8rC=Q{VlNTeTw zwfpeFLnRs_75WhL$kECDneh)#S1{-V^y6n1%FD`4|9jAXMtgm>yt-VkBNFNR;MZs8 z-=F#Mw}oGcCAbMeaH zyP*U3D9|{i8;hlW_^H9`x46bvq3YftA{4%>^;^{6z;n%wB!)CeaV;916xjg@AiK7r zP(dsaZOPrO>;5WKw}yg>UB-$!?x#@ zWyRM>+Vc+l-|_2IV~0P$DH821?cj_@xu}-SQTl)7Kt&)6FmhK8nS7%GhR?iNlODHEgbW4%nv34+buqA0<3gZ*H z-#Jvf6VPSmSNkMpsn4CccE=8@eZc^?x#~cN!iLOvMO8}G?{SsC#oweMA0g_ZIC7CS zY$KQLk?fph=dw0#f^FD2h&eeLw)5F=)UY=r+i?oH@hiETRJdsQwiK=1Z&LCkH(r734GdiRfhCCcFS|*?3 zSR$8;CpezW<`VHwElmprrm|y`BL(Kd$mCmv0>`ETcb#~gW67bR1dxgEcD2adG8N;( zfr(=y!_316CdaZsh4}6RUFSRuFb8@Pgl}2ON(o1RLlRA z&Ze>C)l{>v@$y#$@C9I3Xw+^ z150K&J)F)A3 + + +This SVG font generated by Fontastic.me + + + + + + + + + + \ No newline at end of file diff --git a/fonts/custom-icons.ttf b/fonts/custom-icons.ttf new file mode 100644 index 0000000000000000000000000000000000000000..f93e7a3d61c6ef5359b249218f89b3e566d3c3fc GIT binary patch literal 2160 zcmcgtPiP!f82`SR*_qkwHk(Z|Gd2IZo7q3D+f9?*?5x=|X2EvrUmB7cYHQI=H%UYD zk0gcY#eiO`2cZW+kb>L!H_fU2PEI#uwM z#3&0|ztW72B-o9YNNnIiI@cUaQ`y8%LS@C*XxfuF|F1q9RAYzV##bad=$;al+UQw& z4yTaDIH?&~Bkv>=AyzFjZ)Nh%C_7{9SY{7*Xljc4l8I3s$~z;Ru}oMc?LJL~&N8!X zX?8BICG$?!+|Q<=)}n`^-Isi-qEy6kus5hM@6}Z4K!>^Azb`1r-d4ZbsT z&hd%r1dnx1bov7U{gBS@M^n+ZuJ3$4Nv`;Ovhqon-V*ak?V2vhc`pQrrs=Jc)b00g z_XcIoPgW;C>YV7*SxX^~Xs}9o^6_$@k7Va8JD0U_5^TfHfz8R$u$|9_qlUe; zxmn%Xx_r4>6vN~TH_c16-%|WiDrK66VH6ElQDmwWQ+#1d^j@NN+(_H#eTWVc#S_T{ zny4Bk&I}r6p^bLpFk?Y`A;?1kp=I(JjwN!rc!J}}Y%UT1(9*O}U^+WCIZ|LQj7+{- zC~#~#aL zfW|!_#`;}zK4@pvBvIPCE%g?LolM2a7hUc_zi653f#5ESoix=H^8A%r0P literal 0 HcmV?d00001 diff --git a/fonts/custom-icons.woff b/fonts/custom-icons.woff new file mode 100644 index 0000000000000000000000000000000000000000..8049f7f7e9292de24d865952f46b716c7622d7f9 GIT binary patch literal 1508 zcmZXTc{tQ*0LR}kW=saFG30KPrlK^442cHKIKo&*Y^$fAF~%*|VjShlwvHU7B0PAa zSgpj$5e+sbN8{+(qO^`0M+mWYT(dv5Pyg)uJfG)%zn}MhpXZHa(CG|kX9fVM_W%pv zf*}CJPW}I4L8lV{Kwtn6s|Elm=KGJ>GdkVb4sJKVqm^M)eU*=CS)QiRVfS(;!w>)& zh%=mykzuz8XB!yEq2z*zXP`$g0OBX%Y!0t$BQ}C|_3`px!7d(lIxq%X!rm1hSi|h8 zEuCqNy@I|UU*b42-{n8^cM^VIzp|e+URH*gF`%fU+7No6DE(l2h(R9GUSo-SEbqP7 z@?}xp8eh)AMII+!62XERF1}u!^$M$wff|GcI4LXY+KNAVG}iv9qr9HvO~3F}-%(wz zsQpla6Jy38fWDo^PWJ1==;UP&2fVJZNJ%w2`lv|PbVFv!G&)|r)Dq)*LTdWf;%S~r zzMoI(yR3t$3u_Z2Bd*5VXFl;VG7J@0ymPEW!;`N+Pd}xonK@k0yII88lw( z-tzKwg~dxAMRU*-4?~Eo?mJ<%|bD1Oi?=71zZPDTfU9&OaG$z%)s_B}M z{c)zXcfFqTQPPUpOt|iLMaRKyVgYkUNLY zl6G5NiedbTk}+2qz9Cgx5>BAy%PcKNM_^mI3u6rL=ReGD`XE)prHzb|3ZK-;H`~}d zhHfjq{ZRQ}Zk=ot&|X0$>SK-E+~QR$2K0zog&WaGO|v>@>;sdaNnu@0{-^N|-E2zw zF9(fk>W7LIo?UnLdEMp_deacm$yA%wsd5&30}#w{5!Pb|;rRCR6s5Y(=gkkx04^L&#jP zABn?Qh1q!oLsl#+kJv>KB1wHR2#va}+^I%2M_`l?SRpp~>pl>~j)#=cbhKqbwea-)54jph)@ozR4%VGeym@TMAohCACZv+V0=hI|Jzx?MB~O| z@2<~pV!g)LOppNICmORZLUvwGZ%%NRK|j<7MoC!RZ{y!??Ho!Di6L!!LM$rE7O>AF z`S52J`wu_?+5iU!-~fO1oq4&LZ8jZLJdI!HOU0+EMBW_kNoKj16&r8t5+;@(aKKp& zT?m(TjRd}y z-ok5cHf`;u5X<9O)da@fe#4^QXGNB+CfVoiIe#A~pPA~i$yQu@kV%_)waq6vGSy~f zdu#+}P7U&ohdNt^ayWxe^yj1IQr@}JI3a>Pj%>S(uW!Q!NuoX}IyE&LAq~JG7epff F{{lCiX)XW& literal 0 HcmV?d00001 diff --git a/js/datagrid.js b/js/datagrid.js index 8ec5384..501ee6f 100644 --- a/js/datagrid.js +++ b/js/datagrid.js @@ -27,11 +27,17 @@ function submitform(){ } function highlightRow(row_id,default_color){ - var hlbg = '#aaddaa'; + var hlbg = '#aaa'; + var light = '#fff'; + var dark = '#333'; + if (document.getElementById(row_id).bgColor == hlbg){ document.getElementById(row_id).bgColor = default_color; + document.getElementById(row_id).style.color = dark; + }else{ document.getElementById(row_id).bgColor = hlbg; + document.getElementById(row_id).style.color = light; } } From 2c2bb31b9bca0a23174f3e63bb9634c80196c798 Mon Sep 17 00:00:00 2001 From: Photosynthesis Date: Mon, 14 Oct 2013 13:34:21 -0700 Subject: [PATCH 4/9] Update README --- README | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/README b/README index 664c23a..e128130 100644 --- a/README +++ b/README @@ -3,27 +3,26 @@ Datagridle is a rapidly-deployable, feature-rich and customizable open-source da Please send bug reports and feature requests by email to adam@photosynth.ca, or on our Github repo at https://github.com/Photosynthesis/Datagridle +####Features -###Ultra-rapid development: create a full-featured DB interface with just a few lines of code. -Using just the table name and DB info, Datagridle can create a feature-packed DB backend interface for use in custom applications and modules. +-Fast: set up a database content editing grid with a few lines of code +-Multi-table capable +-Define save, edit, and display callbacks for arbitrary customization +-WYSIWYG editor +-Heuristic setup based on database table features +-12 pre-defined field types including calendar date picker and select boxes populated from other database tables +-Unique url string prefixes allow painless embedding in other aplications +-Use template display types with data placeholders to display images, hyperlinks, and more in the grid +-Specify style information for edit and display of individual fields +-Specify edit, add, and delete privileges +-Users can hide columns in the grid display for convenient browsing +-Sort, search, and pagination -###Super embeddable -Datagridle is designed to be seamlessly embedded into other applications. It uses unique GET prefixes for URL variables to eliminate conflicts within an application, and preserves all existing URL variables. This makes it a breeze to integrate into existing applications, plugins, or modules. HTML headers can be turned on or off, enabling either stand-alone or embedded operation. -###Highly customizable -Define callback functions for display, editing, or saving for any specific field -Allow or deny editing, adding, or deleting records with permissions settings -Use template display types with data placeholders to display images, hyperlinks, and more in the grid -Specify style information for edit and display of individual fields -Built-in TinyMCE wysiwyg content editor -Advanced form fields such as calendar date selector and multiple checkbox +####Sample usage -###Multi-table capable -Parent and child table relationships can be defined to allow editing of child records through a pop-out sub-grid, and population of descriptive fields from a parent table into foreign key fields. +include('datagrid.class.php'); -###Comes with standard features too -Compact search, pagination and sorting functions give your users control of the grid. +$grid = new datagrid('pages'); -###Caveats -Your application must take care of user control and authentication. -Datagridle has not been tested on very large data sets, and has not been optimized for this. If you use it for editing a large table (> 10,000 records) please let us know, and report any performance issues. \ No newline at end of file +echo $grid->grid(); From 3b7d7d685b0833149395bd3f3456e64f4b1229e2 Mon Sep 17 00:00:00 2001 From: Photosynthesis Date: Mon, 14 Oct 2013 13:35:01 -0700 Subject: [PATCH 5/9] Update README.md --- README.md | 40 +++++++++++++++++----------------------- 1 file changed, 17 insertions(+), 23 deletions(-) diff --git a/README.md b/README.md index e8d8959..e128130 100644 --- a/README.md +++ b/README.md @@ -1,34 +1,28 @@ -Datagridle -========== - ###Readme Datagridle is a rapidly-deployable, feature-rich and customizable open-source database content editing system. It is built to be embedded as an admin interface in other applications, or used as a stand-alone database editor. Please send bug reports and feature requests by email to adam@photosynth.ca, or on our Github repo at https://github.com/Photosynthesis/Datagridle -For documentation, please see [http://www.photosynth.ca/code/datagridle/docs](http://www.photosynth.ca/code/datagridle/docs). - -###Ultra-rapid development: create a full-featured DB interface with just a few lines of code. -Using just the table name and DB info, Datagridle can create a feature-packed DB backend interface for use in custom applications and modules. +####Features -###Super embeddable -Datagridle is designed to be seamlessly embedded into other applications. It uses unique GET prefixes for URL variables to eliminate conflicts within an application, and preserves all existing URL variables. This makes it a breeze to integrate into existing applications, plugins, or modules. HTML headers can be turned on or off, enabling either stand-alone or embedded operation. +-Fast: set up a database content editing grid with a few lines of code +-Multi-table capable +-Define save, edit, and display callbacks for arbitrary customization +-WYSIWYG editor +-Heuristic setup based on database table features +-12 pre-defined field types including calendar date picker and select boxes populated from other database tables +-Unique url string prefixes allow painless embedding in other aplications +-Use template display types with data placeholders to display images, hyperlinks, and more in the grid +-Specify style information for edit and display of individual fields +-Specify edit, add, and delete privileges +-Users can hide columns in the grid display for convenient browsing +-Sort, search, and pagination -###Highly customizable -- Define callback functions for display, editing, or saving for any specific field -- Allow or deny editing, adding, or deleting records with permissions settings -- Use template display types with data placeholders to display images, hyperlinks, and more in the grid -- Specify style information for edit and display of individual fields -- Built-in TinyMCE wysiwyg content editor -- Advanced form fields such as calendar date selector and multiple checkbox -###Multi-table capable -Parent and child table relationships can be defined to allow editing of child records through a pop-out sub-grid, and population of descriptive fields from a parent table into foreign key fields. +####Sample usage -###Comes with standard features too -Compact search, pagination and sorting functions give your users control of the grid. +include('datagrid.class.php'); -###Caveats -Your application must take care of user control and authentication. -Datagridle has not been tested on very large data sets, and has not been optimized for this. If you use it for editing a large table (> 10,000 records) please let us know, and report any performance issues. +$grid = new datagrid('pages'); +echo $grid->grid(); From d5689364f1206969b3e48dafdc0eb9f885d348bc Mon Sep 17 00:00:00 2001 From: Photosynthesis Date: Mon, 14 Oct 2013 13:36:05 -0700 Subject: [PATCH 6/9] Update README.md --- README.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index e128130..143fb01 100644 --- a/README.md +++ b/README.md @@ -5,18 +5,18 @@ Please send bug reports and feature requests by email to adam@photosynth.ca, or ####Features --Fast: set up a database content editing grid with a few lines of code --Multi-table capable --Define save, edit, and display callbacks for arbitrary customization --WYSIWYG editor --Heuristic setup based on database table features --12 pre-defined field types including calendar date picker and select boxes populated from other database tables --Unique url string prefixes allow painless embedding in other aplications --Use template display types with data placeholders to display images, hyperlinks, and more in the grid --Specify style information for edit and display of individual fields --Specify edit, add, and delete privileges --Users can hide columns in the grid display for convenient browsing --Sort, search, and pagination +- Fast: set up a database content editing grid with a few lines of code +- Multi-table capable +- Define save, edit, and display callbacks for arbitrary customization +- WYSIWYG editor +- Heuristic setup based on database table features +- 12 pre-defined field types including calendar date picker and select boxes populated from other database tables +- Unique url string prefixes allow painless embedding in other aplications +- Use template display types with data placeholders to display images, hyperlinks, and more in the grid +- Specify style information for edit and display of individual fields +- Specify edit, add, and delete privileges +- Users can hide columns in the grid display for convenient browsing +- Sort, search, and pagination ####Sample usage From 8c8cdb25b069b29ad7e03be70be1674dcd9368ac Mon Sep 17 00:00:00 2001 From: Photosynthesis Date: Mon, 14 Oct 2013 13:36:29 -0700 Subject: [PATCH 7/9] Update README.md --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 143fb01..5976a66 100644 --- a/README.md +++ b/README.md @@ -20,9 +20,10 @@ Please send bug reports and feature requests by email to adam@photosynth.ca, or ####Sample usage - +``` include('datagrid.class.php'); $grid = new datagrid('pages'); echo $grid->grid(); +``` From c5942c323a38d65a299d01c33cd84258348e4cee Mon Sep 17 00:00:00 2001 From: omphalosskeptic Date: Tue, 15 Oct 2013 22:18:18 -0700 Subject: [PATCH 8/9] Update README.md Add link to docs (got removed in last commit?) --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index 5976a66..dd5541f 100644 --- a/README.md +++ b/README.md @@ -27,3 +27,7 @@ $grid = new datagrid('pages'); echo $grid->grid(); ``` + +#### Documentation + +Full documentation can be found at: (http://photosynth.ca/code/datagridle/docs) From 32e31889cbdb0c34d84e1ebba461b74eb4c88db9 Mon Sep 17 00:00:00 2001 From: omphalosskeptic Date: Tue, 15 Oct 2013 22:20:02 -0700 Subject: [PATCH 9/9] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index dd5541f..7d6e34b 100644 --- a/README.md +++ b/README.md @@ -30,4 +30,4 @@ echo $grid->grid(); #### Documentation -Full documentation can be found at: (http://photosynth.ca/code/datagridle/docs) +Full documentation can be found [here.](http://photosynth.ca/code/datagridle/docs)
'; if(strpos($this->settings['privileges'],'add') !== false){ $out .= $this->add_button(); @@ -961,12 +961,12 @@ private function make_grid(){ if($fieldattribs['type'] != 'derivative'){ $columnhead = " target_url->get($this->GET_pfx()."sorttable=$table&".$this->GET_pfx()."sortfield=$field&".$this->GET_pfx()."sorttype=$new_sort")."\">$fieldattribs[title] - target_url->get($this->GET_pfx()."hide_field=$fid")."\">>hide< $fieldattribs[title] - target_url->get().$this->GET_pfx()."hide_field=$fid\">>hide< + target_url->get().$this->GET_pfx()."hide_field=$fid\">» hide «