Standard buttons for my PHP applications
What is this
A graphical library (css with in-lined images) and a single PHP function that generates
Or look at this CSS only page
- Download and unzip.
Note there are no images because they're packed into the css file.
- Put ctrls-min.css somewhere
- Link to it eg <LINK href='./style/ctrls-min.css' rel='stylesheet' type='text/css'>
Call CtrlBut function to supply complete HTML as an A or SPAN tag.
A typical call might be CtrlBut('change',123,'http:foo.com?id=%%&action=edit','Edit')
Hover over image for name. This will be used as the first argument in CtrlBut()
Calling the CtrlBut() function
Return <A> or <SPAN> styled as one of our standard control buttons
Type is one of the following strings for live buttons
add,back,bottom,change,down,fly (ie.external link)
topx,bottomx,upx,downx (disabled list navigation)
Id is some Id which may be a null string.
In the case of a SPAN this will be used as an element Id
The Id will be substituted into a two percent sign placemarker
Title becomes a hover-over-hint. If not supplied then a default is used.
|URL to index page
||CtrlBut('back','123','http:vulpeculox.net/misc','Back to index')
%% is place holder for id
this is the SPAN element
||CtrlBut('bottomx','','ClicketyClick()','Go to end of list')
The x in the type is the disabling key