Jump to content

auLib: Difference between revisions

From auWiki
added to PHP:Packages category
 
(44 intermediate revisions by the same user not shown)
Line 1: Line 1:
The auLib package is meant to give [[User:Misterhaan|me]] a common set of functions to use when working on multiple websites, and also avoid having multiple copies of essentially the same code.
[[Category:Library]]
[[Category:PHP]]
{{RightTOC}}
The auLib package is meant to give [[User:misterhaan|me]] a common set of functions to use when working on multiple websites, and also avoid having multiple copies of essentially the same code.


The auLib package is not yet available for download.  It requires PHP 5, but could be modified to use PHP 4
The auLib package is available for download as [http://www.track7.org/analogu/scripts/aulib new layout classes] from the [http://www.track7.org/analogu/scripts/ track7 scripts page].  It requires PHP 5, but could be modified to use PHP 4 if you know some php.


The first site up on the auLib classes was [http://www.track7.org/ track7] in January 2007.  That ordeal was both the first test of the library as well as a lot of tuning to the functions they contain.  They will likely continue to be changed as they are used for more and more sites.
The first site up on the auLib classes was [http://www.track7.org/ track7] in January 2007.  That ordeal was both the first test of the library as well as a lot of tuning to the functions they contain.  They will likely continue to be changed as they are used for more and more sites.


== Files Included ==
== Files Included ==
* auDB.mysql.php : [[PHP:Class:auDB|auDB]], [[PHP:Class:auDBResult|auDBResult]]
* auDB.base.php: [[auDB]], [[auDBResult]]
* auFile.php
** auDB.mysql.php: MySQL implementation of auDB.
* auForm.css
** auDB.mysqli-obj.php: MySQL improved object implementation of auDB.
* auForm.php:  [[PHP Class auForm|auForm]], [[PHP:Class:auFormFieldSet|auFormFieldSet]]
** auDB.mysqli-proc.php:  MySQL improved procedural implementation of auDB.
* auPage.php
* auFeed.php:  [[auFeed]]
* auText.php
* auFile.php:  [[auFile]]
* auTimer.php
* auForm.css:  Some basic CSS to get the forms built by auForm looking better.
* auUser.php
* auForm.php:  [[auFormElement]], [[auFormContainer]], [[auFormField]], [[auForm]], [[auFormFieldSet]], [[auFormData]], [[auFormText]], [[auFormHTML]], [[auFormString]], [[auFormMultiString]], [[auFormPassword]], [[auFormNumber]], [[auFormInteger]], [[auFormInstant]], [[auFormCheckbox]], [[auFormFile]], [[auFormSelect]], [[auFormMultiSelect]], [[auFormButtons]]
* auPage.php:  [[auPage]]
* auSend.php:  [[auSend]]
* auText.php:  [[auText]]
* auTimer.php:  [[auTimer]]
* auUser.php:  [[auUser]]


== Sites Using auLib ==
== Sites Using auLib ==
* [http://www.track7.org/ track7]
* [http://www.track7.org/ track7]


[[Category:PHP|auLib]]
== Releases ==
[[Category:PHP:Packages|auLib]]
=== 0.5.0 ===
not yet released
* [[auForm]] Use HTML 5 input types and required attribute (will no longer validate as XHTML 1.1 but should work correctly in XHTML browsers)
* [[auFormButtons]] Add $cancel parameter.
* [[auFormNumber]] Support non-integer step values.
* [[auDB]] Show smarter page links for split queries.
* [[auPage]] Alow custom general script name in Scripts().
* Avoid PHP warnings.
 
=== 0.4.0 ===
released 1 february, 2011
* [[auFile]] Support transparent backgrounds on resize
* [[auFile]] Convert GIF uploads to PNG (optional via new parameter)
* [[auFile]] Set extension correctly for PNG uploads
* [[auUser]] now uses SHA512 for password hashes.  '''This increases the length of password hashes from 48 to 96 characters''', so make sure you have room in your database.  Optional overridable function [[auUser#UpdatePassword|UpdatePassword]] has been added to re-hash users passwords at login with SHA512 if they were on SHA1.
* [[auLib]] fix split() to explode().
* [[auUser]] don't send redirect header for ajax logins.
* [[auSend]] introduced.
* [[auText]] change [[auText#SmartDate|SmartDate]] and [[auText#SmartTime|SmartTime]] to format same-year like 2nd instead of 02nd.
* [[auPage]] switch from XHTML 1.1 to HTML 5
* [[auPage]] include general.js if it exists, even if there isn't a more specific js file.
* [[auFormFieldSet]] add contents parameter.
 
=== 0.3.1 ===
released 18 Feb 2009, updated 22 Jan 2011
* [[auFile]] Set extension correctly for PNG uploads
==== 0.3.0 ====
* [[auForm]] add support for arrays as field names.
* [[auText]] add [[auText#PhoneFormat|PhoneFormat]].
* [[auForm]] add defaultonly option.
* [[auText]] handle one-line code samples better.
* [[auText]] add assumeP option to BB2HTML.
* [[auLib]] switch comments to [http://www.phpdoc.org/ phpdoc] format.
* [[auForm]] add some abstract classes for common functions.
* [[auForm]] add generic [[auForm#Add|Add]] function.
* [[auForm]] support multiple fields on the same row.
* [[auText]] use htmlspecialchars to convert to html and html_entity_decode to convert back.
* [[auDB]] fixed mysqli implementations for queries other than select.
* [[auFeed]] handle special characters.
* [[auFeed]] include atom:link tag.
* [[auFile]] check file uploads for errors (images only).
* [[auText]] add [[auText#Diff|Diff]].
* [[auUser]] add [[auUser#.24homepage|$homepage]] protected variable.
 
=== 0.2.1 ===
released 01 Oct 2007, updated 22 Jan 2011
* [[auFile]] Set extension correctly for PNG uploads
==== 0.2.0 ====
* [[auDB]] now has 3 more files:
** auDB.base.php - base class that actual auDB classes (including the one in auDB.mysql.php) extend.
** auDB.mysqli-obj.php - implementation using object interface to PHP's MySQL improved functions.
** auDB.mysqli-proc.php - implementation using procedural interface to PHP's MySQL improved functions.
* [[auFile]] fix to resizing in [[auFile#SaveUploadImage|SaveUploadImage]].
* [[auPage]] fix [[auPage#Show404|Show404]] to not show a blank page.
* [[auTimer]] fix possible rounding errors.
* [[auText]], [[auFeed]] support UTF-8 by default instead of ISO-8859-1.
* [[auPage]] add [[auPage#Scripts|Scripts]].
 
=== 0.1.1 ===
updated 22 Jan 2011
* [[auFile]] Set extension correctly for PNG uploads
==== 0.1.0 ====
* [[auDB]] public variables are now declared public instead of var.
* [[auFeed]] added.
* [[auFile]] fixes in [[auFile#SaveUploadImage|SaveUploadImage]].
* [[auForm]] various typos fixed.
* [[auPage]] charset changed from iso-8859-1 to utf-8.
* [[auText]] now uses htmlentities instead of htmlspecialchars; fix handling of <nowiki>[head]</nowiki> and <nowiki>[subhead]</nowiki> in [[auText#BB2HTML|BB2HTML]]; allow links to #id in [[auText#FixLink|FixLink]].
 
=== 0.0.1 ===
updated 22 Jan 2011
* [[auFile]] Set extension correctly for PNG uploads
==== 0.0.0 ====
* Initial release.

Latest revision as of 13:22, 15 February 2012

The auLib package is meant to give me a common set of functions to use when working on multiple websites, and also avoid having multiple copies of essentially the same code.

The auLib package is available for download as new layout classes from the track7 scripts page. It requires PHP 5, but could be modified to use PHP 4 if you know some php.

The first site up on the auLib classes was track7 in January 2007. That ordeal was both the first test of the library as well as a lot of tuning to the functions they contain. They will likely continue to be changed as they are used for more and more sites.

Files Included

Sites Using auLib

Releases

0.5.0

not yet released

  • auForm Use HTML 5 input types and required attribute (will no longer validate as XHTML 1.1 but should work correctly in XHTML browsers)
  • auFormButtons Add $cancel parameter.
  • auFormNumber Support non-integer step values.
  • auDB Show smarter page links for split queries.
  • auPage Alow custom general script name in Scripts().
  • Avoid PHP warnings.

0.4.0

released 1 february, 2011

  • auFile Support transparent backgrounds on resize
  • auFile Convert GIF uploads to PNG (optional via new parameter)
  • auFile Set extension correctly for PNG uploads
  • auUser now uses SHA512 for password hashes. This increases the length of password hashes from 48 to 96 characters, so make sure you have room in your database. Optional overridable function UpdatePassword has been added to re-hash users passwords at login with SHA512 if they were on SHA1.
  • auLib fix split() to explode().
  • auUser don't send redirect header for ajax logins.
  • auSend introduced.
  • auText change SmartDate and SmartTime to format same-year like 2nd instead of 02nd.
  • auPage switch from XHTML 1.1 to HTML 5
  • auPage include general.js if it exists, even if there isn't a more specific js file.
  • auFormFieldSet add contents parameter.

0.3.1

released 18 Feb 2009, updated 22 Jan 2011

  • auFile Set extension correctly for PNG uploads

0.3.0

  • auForm add support for arrays as field names.
  • auText add PhoneFormat.
  • auForm add defaultonly option.
  • auText handle one-line code samples better.
  • auText add assumeP option to BB2HTML.
  • auLib switch comments to phpdoc format.
  • auForm add some abstract classes for common functions.
  • auForm add generic Add function.
  • auForm support multiple fields on the same row.
  • auText use htmlspecialchars to convert to html and html_entity_decode to convert back.
  • auDB fixed mysqli implementations for queries other than select.
  • auFeed handle special characters.
  • auFeed include atom:link tag.
  • auFile check file uploads for errors (images only).
  • auText add Diff.
  • auUser add $homepage protected variable.

0.2.1

released 01 Oct 2007, updated 22 Jan 2011

  • auFile Set extension correctly for PNG uploads

0.2.0

  • auDB now has 3 more files:
    • auDB.base.php - base class that actual auDB classes (including the one in auDB.mysql.php) extend.
    • auDB.mysqli-obj.php - implementation using object interface to PHP's MySQL improved functions.
    • auDB.mysqli-proc.php - implementation using procedural interface to PHP's MySQL improved functions.
  • auFile fix to resizing in SaveUploadImage.
  • auPage fix Show404 to not show a blank page.
  • auTimer fix possible rounding errors.
  • auText, auFeed support UTF-8 by default instead of ISO-8859-1.
  • auPage add Scripts.

0.1.1

updated 22 Jan 2011

  • auFile Set extension correctly for PNG uploads

0.1.0

  • auDB public variables are now declared public instead of var.
  • auFeed added.
  • auFile fixes in SaveUploadImage.
  • auForm various typos fixed.
  • auPage charset changed from iso-8859-1 to utf-8.
  • auText now uses htmlentities instead of htmlspecialchars; fix handling of [head] and [subhead] in BB2HTML; allow links to #id in FixLink.

0.0.1

updated 22 Jan 2011

  • auFile Set extension correctly for PNG uploads

0.0.0

  • Initial release.