login | register
25 Jul 2008 [18:02 UTC]

bitweaver - Web Application Framework and CMS

Web Application Framework and CMS

Stephan Borg

User Page

UserPagewolff_borg

My thoughts on bitweaver is to integrate common business applications such as CRM, HR, Payroll, Accounting, etc into bitweaver - providing single-sign-on and common look-and-feel.

When bitweaver is in a more 'integratable' state, I will be happy to investigate this option further and fund development - but for now, its just a pipe-dream.

User Information

Stephan Borg

Login
wolff_borg
Real Name
Stephan Borg
Country
Australia Australia
Language
English (English, en)
Member since
Sunday 15 of February, 2004
Last Login
Friday 04 of July, 2008 [20:40:04 UTC]
Send Message
Send a personal message to this user

Content List

Select Content Type
You can restrict the content listing to a given content type or apply a filter on content title.
Available Content [ 210 ]
IDTitle ascendingContent TypeAuthorMost recent editorLast Modified
779AJAXWiki PageStephan Borgspiderr09 Nov 2005
170APIDocumentationWiki PageStephan BorgUwe Zimmermann11 Mar 2006
432Bitweaver and Browser CookiesWiki PageStephan BorgStephan Borg01 Sep 2006
13638[bitweaver-core] 1.0.2 Official ReleaseCommentStephan BorgStephan Borg30 Jul 2005
13761[bitweaver-core] AJAX in bitweaver!CommentStephan BorgStephan Borg01 Dec 2005
13637[bitweaver-core] Big Change NotificationCommentStephan BorgStephan Borg27 Jul 2005
13814[bitweaver-core] BitDb->associateSelect()CommentStephan BorgStephan Borg02 Jan 2006
14051[bitweaver-core] Bitweaver and Browser CookiesCommentStephan BorgStephan Borg01 Sep 2006
13647[bitweaver-core] Bitweaver RoadmapCommentStephan BorgStephan Borg24 Aug 2005
13929[bitweaver-core] Bounty SystemCommentStephan BorgStephan Borg18 Feb 2006
13635[bitweaver-core] BugfestCommentStephan BorgStephan Borg24 Jul 2005
13671[bitweaver-core] Bug FestCommentStephan BorgStephan Borg13 Sep 2005
13661[bitweaver-core] BW and AJAXCommentStephan BorgStephan Borg09 Sep 2005
13632[bitweaver-core] BW, IIS and MS-SQLCommentStephan BorgStephan Borg23 Jul 2005
13782[bitweaver-core] Content ApprovalCommentStephan BorgStephan Borg07 Dec 2005
13799[bitweaver-core] Content Linking in HTMLCommentStephan BorgStephan Borg20 Dec 2005
13693[bitweaver-core] Debug PackageCommentStephan BorgStephan Borg18 Sep 2005
13601[bitweaver-core] Developers FAQCommentStephan BorgStephan Borg01 Jul 2005
13582[bitweaver-core] Developers UpdateCommentStephan BorgStephan Borg29 Jun 2005
13629[bitweaver-core] Documentation RequestCommentStephan BorgStephan Borg22 Jul 2005
13703[bitweaver-core] Feature Notification: DB Migration UtilityCommentStephan BorgStephan Borg26 Sep 2005
13963[bitweaver-core] .htaccess / Pretty URLsCommentStephan BorgStephan Borg07 Mar 2006
13776[bitweaver-core] JS Text Scroll ModuleCommentStephan BorgStephan Borg02 Dec 2005
13568[bitweaver-core] LibertyAttachableCommentStephan BorgStephan Borg26 Jun 2005
13612[bitweaver-core] (Oh no) SLDC's Pt 2CommentStephan BorgStephan Borg08 Jul 2005

Recent Blog Posts

Refresh cachePrint

In Smarty, how do I check what browser is being used?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
Here is a code sample for your .tpl:

{if $gBitLoc.browser.client eq 'mz' or $gBitLoc.browser.client eq 'ie'}
    This browser is IE or Mozilla based!
{/if}


the end.
Print

How do I create a LibertyContent Class?

By Stephan Borg
Thursday 29 of December, 2005
Posted to Developer's FAQ
Your best bet to creating a LibertyContent class, is to copy the SamplePackage, BitSample.php file and modify accordingly.

The best approach is to:
  • Modify the verify() function first, making sure each and every field is validated correctly.
  • Modify the store() function, ensuring data is stored in the table correctly.
  • Modify the load() function
  • Modify the getList() function
  • Modify the expunge() function
Print

Can I use strtotime() and strftime()?

By Stephan Borg
Thursday 29 of December, 2005
Posted to Developer's FAQ
We have implement locale timezone formatting using BitDate() class.

For easy access, always use:
$gBitSystem->mServerTimestamp->strtotime(...);
 
and
 
$gBitSystem->mServerTimestamp->strftime(...);
 
as straight replacements.


Inside Smarty templates, use the:
{$timestamp|bit_short_datetime}


Other formats are:
  • bit_date_format
  • bit_long_datetime
  • bit_short_date
  • bit_short_time
  • bit_long_date
  • bit_long_time
  • bit_short_datetime
Print

Can I use strtotime() and strftime()?

By Stephan Borg
Thursday 29 of December, 2005
Posted to Developer's FAQ
We have implement locale timezone formatting using BitDate() class.

For easy access, always use:
$gBitSystem->mServerTimestamp->strtotime(...);
 
and
 
$gBitSystem->mServerTimestamp->strftime(...);
 
as straight replacements.


Inside Smarty templates, use the:
{$timestamp|bit_short_datetime}


Other formats are:
  • bit_date_format
  • bit_long_datetime
  • bit_short_date
  • bit_short_time
  • bit_long_date
  • bit_long_time
  • bit_short_datetime
Print

How do I check in Smarty, if Liberty content is in HTML?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
{if $gContent->mInfo.format_guid == 'bithtml'}
    This is HTML content!
{/if}
Print

How do I check for a preference setting in Smarty?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
{if $gBitSystemPrefs.tinymce_ask eq 'y'}
    This setting is 'yes'!
{else}
    This setting is 'no'!
{/if}
Refresh cachePrint

How do I add an Administration menu to a package?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
Well...
First you need a package/admin/admin_package_inc.php file, which will look something like this:
{code}$formTinyMCEFeatures = array(
"tinymce_ask" => array(
'label' => 'WYSIWYG confirmation',
'note' => 'Ask before using the WYSIWYG editor tinymce when clicking on a textarea. If you disable this feature, we strongly suggest you enable HTML content format as the only content format and also disable quicktags.',
'page' => '',
),
);
$smarty->assign( 'formTinyMCEFea…
Print

How do I check if the current user has a permission?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
if ($gBitUser->hasPermission('bit_p_admin_cms')) {
    This user has permission!
}


NOTE: if you want to exit and display an error message if they don't have permission, then:
$gBitSystem->verifyPermission( 'bit_p_view' );

This displays a standard "You do not have permission!" error message.
Print

How do I get and set preferences?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
To get a preference:
$gBitSystem->getPreference("maxArticles", 10);

Where, "maxArticles" is your preference name, which 10 is your default setting, should it not be set.

To set a preference:
$gBitSystem->storePreference("maxArticles", 10);

Where, "maxArticles" is your preference name, which 10 is your setting you wish to store.
Print

How do I check if a Package is enabled?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
if ($gBitSystem->isPackageActive( 'articles' )) {
    Articles are active!
}


NOTE: if you wish to exit and display an error message, if package is not enabled, use:
$gBitSystem->verifyPackage( 'articles' );
Print

How do I check if a Feature is enabled?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
if( $gBitSystem->isFeatureActive( 'feature_listPages' ) ) {
    Feature List Pages is active!
}


NOTE: if you wish exit and display an error message on failure, use:
$gBitSystem->verifyFeature( 'feature_listPages' );
Print

How do I display a standard error page?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
Very simple:
$gBitSystem->fatalError( "Any error message you want" )
Print

How do I include other package libraries and classes?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
You'd want to check that the package is installed, as some admins may not install everything.
if ($gTikiSystem->isPackageActive( 'categories' )) {
        include_once( CATEGORIES_PKG_PATH.'categ_lib.php');
        ... do something with categories...
}
Print

How do I use the DB functionality?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
Ok,
  • The $this object is usually a class from BitSystem parent.
  • First of all, you should quote your field names in backticks '`'. This is used to ensure portability between different database vendors.
  • Next, you want to prefix your table names with BIT_DB_PREFIX to allow multiple installs of Bitweaver under one database.
  • We use parameterised queries, by using '?' for our values. This also helps remove quoting problems between vendors.
  • Lastly, our sort mode is a function, in the
Print

Do I use the $smarty global variable to display pages?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
Uh, no - we use:
$gBitSystem->display( 'tikipackage:articles/list_articles.tpl', tra("articles") );

Where:
  • 'tikipackage:articles/list_articles.tpl' is a url to find package templates store under package/templates/ directory
  • tra("articles") is used to change the browser title - should be standard practise to do this and indicate where in the CMS you are (and what you're looking at).
Print

How do I check a user permission in Smarty?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
{if $gBitUser->hasPermission( 'bit_p_read_article' )}
  <li><a class="item" href="{$gBitLoc.ARTICLES_PKG_URL}index.php">{biticon ipackage=liberty iname=home iexplain="articles home"} {tr}Articles Home{/tr}</a></li>
  <li><a class="item" href="{$gBitLoc.ARTICLES_PKG_URL}list.php">{bitcon ipackage=liberty iname=list iexplain="list articles"} {tr}List articles{/tr}</a></li>
{/if}
Print

I have a user ID, how do I get information about the user?

By Stephan Borg
Sunday 03 of July, 2005
Posted to Developer's FAQ
Well, in Smarty templates, using the {displayname} tag works a treat. For example, I have a user ID and I want their real name:
The user name is {displayname user_id=$gBitUser->getUserId()}


See Smarty Functions for more short-cut functions.
Print

Is there an easy way to insert data to a DB table?

By Stephan Borg
Friday 15 of July, 2005
Posted to Developer's FAQ
If you had a simple table, say:
'my_faq' => "
	faq_id I4 AUTO PRIMARY,
	question C(255) NOTNULL,
	answer C(255) NOTNULL,
",


And you wanted to insert a record, you would prepare the data in the following array:
$my_data = array(
	'question' => "What is this project?",
	'answer' => "Its Bitweaver Application Framework!",
);


Then to insert it into the database:
$gBitDb->associateInsert( 'my_faq', $my_data );
Print

Is there an easy way to update data to a DB table?

By Stephan Borg
Friday 15 of July, 2005
Posted to Developer's FAQ
If you had a simple table, say:{code}'my_faq' => "
faq_id I4 AUTO PRIMARY,
question C(255) NOTNULL,
answer C(255) NOTNULL,
",{/code}

And you wanted to update a record, you would prepare the data to update in the following array:{code}$my_data = array(
'question' => "What is this project again?",
'answer' => "Its the Bitweaver CMS and Application Framework!",
);{/code}

Next, you would define what record you plan to update. You do this by building a search array.{code}$my_id = ar…
Print

How do I reference an icon?

By Stephan Borg
Saturday 06 of August, 2005
Posted to Developer's FAQ
All icons are stored under /icons directory.

For detailed information on biticon see function_biticon

{biticon ipackage='sheets' iname='icn_budgetgraph' iexplain='Graph'}
Print

SDLC - ContactsPackage

By Stephan Borg
Friday 08 of July, 2005
Posted to Wolffy's Blog
So, I started a new page today called LDAPContactsPackage and thought it a good opportunity to eat my own dog food, and implement a very basic SDLC.

I've completed the Feasibility Study - I need a contacts package! That was easy! :)

So now onto requirements...

I've put down 1 week for a list of requirements - after that, I will try and lock down for version 1.1 (I will try...).

Will try and apply the Six Hats of Critical Thinking during th…
Print

Whats the difference between a Package and a Feature?

By Stephan Borg
Friday 01 of July, 2005
Posted to Developer's FAQ
A package is the name given to the sub-directories found under Bitweaver's root directory. These are usually applications and can be removed or disabled at will.

A feature, is usually a setting within these packages - and its setting, is usually stored as a preference.

For example, Wiki is a package, while Wiki Sandbox is a feature.
Print

Critical Preflight Checks

By Stephan Borg
Tuesday 08 of February, 2005
Posted to Wolffy's Blog
After discussions with Spiderr, we agreed that critical checks will be performed in TikiSystem::checkEnvironment(). Have consolidated methods used to check these settings to ))preflight_inc.php(( and checkEnvironment() will begin to use these functions.

  • Reverted changes made to TikiSystem previously (thanks spiderr)
  • Added simple preflight checks to ))preflight_inc.php(( such as:
    • minimum PHP version
    • minimum PHP extension version
    • file writeable checks
    • directory writeable ch
Print

Design Questions

By Stephan Borg
Sunday 18 of April, 2004
Posted to BWDesigner's Blog

Been wondering

  • whats the use of parameter session_lifetime?
  • whats the use of parameters http_domain / http_prefix? Should all references to $_SERVER["SERVER_NAME"] and TIKI_ROOT_URL point to these instead?
  • when you login to TP, it takes you to /users/my.php - but clicking on My Homepage takes you to /users/index.php?fHomepage=admin - which one is correct? Are they supposed to be the same?
  • should everything in setup_inc.php below ''tiki_lo
Refresh cachePrint

Some structure changes...

By Stephan Borg
Thursday 26 of February, 2004
Posted to Important Stuff
Made some structure and rename changes today.

kernel/local.php is now kernel/config_inc.php
kernel/defaults_inc.php is now kernel/config_defaults_inc.php

Kernel flowchart goes something like this:
  1. /tiki_setup_inc.php is called - this defines TIKI_ROOT_PATH and points to (requires) kernel/setup_inc.php
  2. kernel/setup_inc.php is called - the first two things it does is includes (in case its a virgin install) kernel/config_inc.php and requires kernel/config_defaults_inc.php. This file is

Stephan Borg's shoutbox


Random Image

Please copy the code into the box. Reload if unreadable.

  • Anonymous: G'day, wolffy. Is that you who left a shut at my site? I am not familar with irc. I have been there (freenode) but no one to talk to. Send me an email so I can contact you. (a.yeh at qut dot edu dot au) - 01 Sep 2005 [01:12 UTC]
Read More…

User profile

Stephan Borg

no user avatar uploaded
Last login: 04 Jul 2008