Sei sulla pagina 1di 3

Get PHPwiki up and running with mysql | LinuxWebLog.

com

Page 1 of 3

Recent posts

Forum

News

Contact

Secure login

Search

Home Blogs sandip's blog

See Also
PHP

Get PHPwiki up and running with mysql


Submitted by sandip on Thu, 12/16/2004 - 16:02

Ran into some difficulty installing the wiki with mysql backend as the documentation wasn't upto-date. Below are some notes and customization done during the process: 1. 2. 3. 4. 5. 6. 7. 8. Download the latest tarball from SourceForge Extract all files. Copy 'config/config-dist.ini' to 'config/config.ini' and edit the settings. Make sure to set the value of 'DEBUG' to either 1 or 0 and do not comment it out. The install process complains if the DEBUG value is not found. Upload the "passencrypt.php" to the web-server and access it via browser to encrypt password. Use the encrypted password for the 'ADMIN_PASSWD' field and make sure that 'ENCRYPTED_PASSWD = true' is uncommented. Use the ADODB library for data access and set 'DATABASE_TYPE = ADODB'. Use 'DATABASE_PREFIX = phpwiki_' with the EditedMysqlScript imported to the database to create the required tables.
# ================= BEGIN ================= # Table structure for table `phpwiki_link` # DROP TABLE IF EXISTS `phpwiki_link`; CREATE TABLE `phpwiki_link` ( `linkfrom` int(11) NOT NULL default '0', `linkto` int(11) NOT NULL default '0', KEY `linkfrom` (`linkfrom`), KEY `linkto` (`linkto`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_member` # DROP TABLE IF EXISTS `phpwiki_member`; CREATE TABLE `phpwiki_member` ( `userid` char(48) binary NOT NULL default , `groupname` char(48) binary NOT NULL default 'users', KEY `userid` (`userid`), KEY `groupname` (`groupname`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_nonempty` # DROP TABLE IF EXISTS `phpwiki_nonempty`; CREATE TABLE `phpwiki_nonempty` ( `id` int(11) NOT NULL default '0', PRIMARY KEY (`id`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_page` # DROP TABLE IF EXISTS `phpwiki_page`; CREATE TABLE `phpwiki_page` ( `id` int(11) NOT NULL auto_increment, `pagename` varchar(100) binary NOT NULL default , `hits` int(11) NOT NULL default '0', `pagedata` mediumtext NOT NULL, PRIMARY KEY (`id`), UNIQUE KEY `pagename` (`pagename`) ) TYPE=MyISAM AUTO_INCREMENT=320 ; # # Table structure for table `phpwiki_pref` # DROP TABLE IF EXISTS `phpwiki_pref`; CREATE TABLE `phpwiki_pref` ( `userid` varchar(48) binary NOT NULL default , `prefs` text, PRIMARY KEY (`userid`), UNIQUE KEY `userid` (`userid`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_rating`

WTP 0.6.2 Generate a dynamic playlist of mp3 files in a folder with PHP Listing image files in folders and subfolders with PHP Compiling support for XSLT in PHP How to fix _Can't open file: 'sessions.MYI'_ in Drupal Load your PHP pages faster with GZip compression Hosting multiple domains pointed to the same webspace

Navigation
Story links

User login
Username: *

Password: *

Log in
Request new password

Recent blog posts


Adding utf-8 Byte Order Mark to file MySQL Database Restore Access VirtualBox Guest via Host Ensim Zone File Template Changing IP address of Ensim server How to install Icinga (Nagios Fork) in Ubuntu 12.10 server manually updating java in ubuntu Resetting WordPress admin password Install yum from centos vault Disabling IDLE in courier-imap more

Who's online
There are currently 0 users and 22 guests online.

http://www.linuxweblog.com/phpwiki

10/4/2013

Get PHPwiki up and running with mysql | LinuxWebLog.com

Page 2 of 3

# DROP TABLE IF EXISTS `phpwiki_rating`; CREATE TABLE `phpwiki_rating` ( `dimension` int(4) NOT NULL default '0', `raterpage` int(11) NOT NULL default '0', `rateepage` int(11) NOT NULL default '0', `ratingvalue` float NOT NULL default '0', `rateeversion` int(11) NOT NULL default '0', `tstamp` timestamp(14) NOT NULL, PRIMARY KEY (`dimension`,`raterpage`,`rateepage`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_recent` # DROP TABLE IF EXISTS `phpwiki_recent`; CREATE TABLE `phpwiki_recent` ( `id` int(11) NOT NULL default '0', `latestversion` int(11) default NULL, `latestmajor` int(11) default NULL, `latestminor` int(11) default NULL, PRIMARY KEY (`id`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_session` # DROP TABLE IF EXISTS `phpwiki_session`; CREATE TABLE `phpwiki_session` ( `sess_id` varchar(32) NOT NULL default , `sess_data` blob NOT NULL, `sess_date` int(10) unsigned NOT NULL default '0', `sess_ip` varchar(15) NOT NULL default , PRIMARY KEY (`sess_id`), KEY `sess_date` (`sess_date`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_user` # DROP TABLE IF EXISTS `phpwiki_user`; CREATE TABLE `phpwiki_user` ( `userid` char(48) binary NOT NULL default , `passwd` char(48) binary default '', PRIMARY KEY (`userid`), UNIQUE KEY `userid` (`userid`) ) TYPE=MyISAM; # # Table structure for table `phpwiki_version` # DROP TABLE IF EXISTS `phpwiki_version`; CREATE TABLE `phpwiki_version` ( `id` int(11) NOT NULL default '0', `version` int(11) NOT NULL default '0', `mtime` int(11) NOT NULL default '0', `minor_edit` tinyint(4) default '0', `content` mediumtext NOT NULL, `versiondata` mediumtext NOT NULL, PRIMARY KEY (`id`,`version`), KEY `mtime` (`mtime`) ) TYPE=MyISAM; # # ================= END ================= #

9. Specify the Data Source Name, 'mysql://user:password@host/databasename' 10. For true user authentication use ALLOW_ANON_USER = true ALLOW_ANON_EDIT = false ALLOW_BOGO_LOGIN = false ALLOW_USER_PASSWORDS = true 11. Other configs are more general and changed accordingly depending on preferences. 12. Upload all your files to the web-server and pointing your browser for the first time to the index.php will set up your wiki automatically. Bookmark/Search this post with

http://www.linuxweblog.com/phpwiki

10/4/2013

Get PHPwiki up and running with mysql | LinuxWebLog.com

Page 3 of 3

sandip's blog

Post new comment


Subject:

Comment: *

Lines and paragraphs break automatically. You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.

More information about formatting options CAPTCHA This question is for testing whether you are a human visitor and to prevent automated spam submissions.

What code is in the image?: *


Enter the characters shown in the image.

Preview

Home | Forum | Recent Posts | News | Archives | Contact This site houses a collection of Tips, Tricks, Resources and Guides of Individuals, put together and edited for personal reference into a daily web journal... Content may not be reproduced without permission from the Individuals. Copyright post 2003 L I N U X w e B l o g . C O M

http://www.linuxweblog.com/phpwiki

10/4/2013

Potrebbero piacerti anche