phpslash-commit Mailing List for phpSlash (Page 68)
Brought to you by:
joestewart,
nhruby
This list is closed, nobody may subscribe to it.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(11) |
Nov
(59) |
Dec
(60) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(52) |
Feb
(77) |
Mar
(118) |
Apr
(76) |
May
(106) |
Jun
(145) |
Jul
(9) |
Aug
(15) |
Sep
(78) |
Oct
(83) |
Nov
(105) |
Dec
(51) |
2003 |
Jan
(105) |
Feb
(100) |
Mar
(111) |
Apr
(149) |
May
(95) |
Jun
(56) |
Jul
(8) |
Aug
(2) |
Sep
|
Oct
(22) |
Nov
(117) |
Dec
(6) |
2004 |
Jan
(1) |
Feb
|
Mar
(3) |
Apr
(25) |
May
|
Jun
(11) |
Jul
(26) |
Aug
(85) |
Sep
(119) |
Oct
(312) |
Nov
(271) |
Dec
(5) |
2005 |
Jan
(6) |
Feb
|
Mar
|
Apr
(12) |
May
(7) |
Jun
(8) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2009 |
Jan
(5) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Joe S. <joe...@us...> - 2002-12-20 16:30:02
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv3895/phpslash-ft Modified Files: CHANGES Log Message: display partial IP of comment author Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.636 retrieving revision 1.637 diff -C2 -d -r1.636 -r1.637 *** CHANGES 19 Dec 2002 23:36:54 -0000 1.636 --- CHANGES 20 Dec 2002 16:29:58 -0000 1.637 *************** *** 13,16 **** --- 13,25 ---- 9 - Removal of something (kill -9 :) + 2002-December-20 9:00AM CST Joe Stewart <joe...@us...> + [F] - Comment.class, comment.php3, commentDisplay.tpl - Seth Hall's comment + patch. Summary of changes - No default subject shown in input form, + IP/host partially shown to non-privileged users. Privileged users + can see the entire IP/Host. + slash-all.sql, 65_to_7.sql - added new commentViewIP permission to + "comment" group. Changed default setting to allow comment poster + to set their name and email. + 2002-December-19 18:30 EST Matthew Leingang <sym...@us...> [D] - Added verbose documentation to config-dist.ini.php3. |
From: Joe S. <joe...@us...> - 2002-12-20 16:30:01
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv3895/phpslash-ft/public_html Modified Files: comment.php3 Log Message: display partial IP of comment author Index: comment.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/comment.php3,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** comment.php3 13 Dec 2002 17:34:33 -0000 1.25 --- comment.php3 20 Dec 2002 16:29:58 -0000 1.26 *************** *** 47,50 **** --- 47,51 ---- case "save": + case "Submit Comment": $content .= "<BR>Click <A HREF=\"" . $return_link . "\">here</A> to go back<BR>\n"; *************** *** 74,77 **** --- 75,79 ---- $content .= getError($cmt->getMessage()); } + header("Location: $return_link"); break; *************** *** 107,111 **** if ($parent_ary[subject] == "") { ! $ary[subject] = pslgetText("No Subject Given"); } elseif( preg_match ("/Re\:/i",$parent_ary['subject'])) { $ary[subject] = $parent_ary[subject]; --- 109,113 ---- if ($parent_ary[subject] == "") { ! //$ary[subject] = pslgetText("No Subject Given"); } elseif( preg_match ("/Re\:/i",$parent_ary['subject'])) { $ary[subject] = $parent_ary[subject]; |
From: Matthew L. <sym...@us...> - 2002-12-20 15:36:04
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv16975 Modified Files: config-dist.ini.php3 Log Message: added much verbose documentation Index: config-dist.ini.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config-dist.ini.php3,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** config-dist.ini.php3 12 Dec 2002 14:43:46 -0000 1.9 --- config-dist.ini.php3 20 Dec 2002 15:36:01 -0000 1.10 *************** *** 1,53 **** ; <?php die(); DO NOT REMOVE THIS LINE ;;;;;;;;;; ! ; config.ini.php3 - Configuration File for PHPSlash ! ; $Id$ ;;;;;;;;;; ! ;;;;; ! ;; Site determinant variables ! ;; basedir -> Complete filesystem path to the pages ! basedir = "/home/nathan/webDevel/phpslash-ft/public_html" ! ;; classdir -> Path to the class directory ! classdir = "/home/nathan/webDevel/phpslash-ft/class" ! ;; rooturl -> The base URL for the phpslash site ! rooturl = "http://fatboy.mystic/nate/phpslash-ft/public_html" ;; Database variables DB_Host = "localhost" ! DB_Database = "psl" ! DB_User = "psl" ! DB_Password = "foo" ! ! ;; Location of PHPLIB prepend file ! ; Used only if the location is not defined in local php.ini or .htaccess ! ; prependfile = "/home/nathan/webDevel/php-lib-stable/php/prepend.php" ! ;; These values are used in your RSS Feeds generated by backend.php3 as ! ;; well as by phpslash for the pages your views see. Please take a moment ! ;; and adjust these to the correct value ! ; Name of the site site_name = "PHPSlash" ! ! ; Email address to reach a human ! site_owner = "in...@ph..." ! ! ; A catch phrase for your site site_slogan = "Slash for you, Slash for me" ! ! ; A Longer version of the title site_title = "PHPSlash: The Web Stops Here" ! ;; END RSS EXPORTER VALUES ! ! ; The subject for the headline email mailinglist_subject = "PHPSlash Times" ! ;; A secret string used when generating site unique variables magic = "ChangeThisToSomethingUnique" ;; End of Site determinant variables --- 1,175 ---- ; <?php die(); DO NOT REMOVE THIS LINE ;;;;;;;;;; ! ;; config.ini.php3 - Configuration File for PHPSlash ! ;; $Id$ ;;;;;;;;;; ! ;;; ! ;; Welcome to PHPSlash! ! ;; ! ;; This file controls many aspects of PHPSlash's behavior. To avoid ! ;; having your settings clobbered on future updates, rename it from ! ;; $RCSfile$ to something else, such as "config.ini.php3". Specify ! ;; that filename in config.php3 or config-dist.php3, the script which ! ;; parses this one and fills in derived values. ! ;; ! ;; This file contains information which you obviously do not want ! ;; world-visible. To protect it, do one of the following: ! ;; ! ;; - Place it outside the web filesystem (UNIX standards would probably ! ;; suggest that it go in an "etc" directory). Make sure the parser ! ;; script knows the full path. ! ;; ! ;; - Keep it in the main web directory of your site, but KEEP THE PHP ! ;; FILE EXTENSION AND TAGS. That way, if someone types the filename ! ;; in the browser URL bar, all that will be displayed is a parse ! ;; error. Giving this file an unparsed extension such as ".ini" will ! ;; probably cause the entire file to be displayed as plain text. ! ;; ! ;; Users familiar with INI files can skip down to the first directive, ! ;; which is 'basedir' below. Otherwise, please read these first ! ;; comments carefully. ! ;; ! ;; The syntax of the file is extremely simple. Whitespace and lines ! ;; beginning with a semicolon are silently ignored (as you probably guessed). ! ;; Section headers mean that configuration will be placed in a subarray. ! ;; ! ;; Directives are specified using the following syntax: ! ; directive = value ! ;; Directive names are *case sensitive* - foo=bar is different from FOO=bar. ! ;; ! ;; The value can be a string, a number, a PHP constant (e.g. E_ALL or ! ;; M_PI), one of the INI constants (On, Off, True, False, Yes, No and ! ;; None) or an expression (e.g. E_ALL & ~E_NOTICE), or a quoted string ! ;; ("foo"). Use double quotes for strings. ! ;; ! ;; This file format is built for speed. Expressions in the INI file are ! ;; limited to bitwise operators (|,&,~,!) and parentheses. If you need ! ;; to make more complex configurations, put them in a copy of ! ;; config-dist.php3 ! ;; ! ;; Boolean flags can be turned on using the values 1, On, True or Yes. ! ;; They can be turned off using the values 0, Off, False or No. ! ;; ! ;; An empty string can be denoted by simply not writing anything after ! ;; the equals sign, or by using the None keyword: ! ;; ! ; foo = ; sets foo to an empty string ! ; foo = none ; sets foo to an empty string ! ; foo = "none" ; sets foo to the string 'none' ! ;;; ! ;;; ! ;; To Developers or extenders of PHPSlash code: ! ;; ! ;; These values all go into the $_PSL array. For information on how ! ;; this file is parsed see http://www.php.net/parse_ini_file ! ;; ! ;; We are trying to migrate to a dotted-keyword form for configuration ! ;; directives e.g., "config.ini_file". Section headers ARE currently ! ;; being utilized, but keep keywords globally scoped all the same. ! ;; ! ;; GOOD: ! ;[mymodule] <-- Norms for use of section headers have not been determined. ! ;; For now, call them optional. ! ;mymodule.enabled = true ! ;mymodule.file = "foo.php" ! ;; ! ;; BAD: ! ;[mymodule] ! ; enabled = true ! ; file = "foo.php" ! ;; ! ;; This allows for maximum clarity to the configurer of a PHPSlash site, ! ;; who may or may not be a hacker. ! ;; ! ;; Comment Customs: ! ;; Two semicolons mark comments which are interesting to humans. ! ;; One semicolon marks comments which are disabling actual code. ! ;;; ! ;;; ! ;; Here is where the configuration actually begins! ! ;;; ! ;;;; ! ;; Site determinant variables ! ;; ! ;; 'dir' means this path is a directory in the complete filesystem ! ;; 'url' means this path is interpreted by the web server ! ;; Thus 'basedir' and 'rooturl' are front and back doors to the same place. ! ;; No trailing slashes on either! ! ;; ! ;; The complete filesystem path to the pages ! basedir = "/home/leingang/src/phpslash-ft/public_html" ! ;; ! ;; The complete filesystem path to the class directory ! classdir = "/home/leingang/src/phpslash-ft/class" ! ;; ! ;; The base URL for the phpslash site ! rooturl = "http://marlowe.rutgers.edu/phpslash" + ;;; ;; Database variables + ;; + ;; Make sure you initialize the database with one of the sql scripts in + ;; the PHPSLASH distribution and create the user below. DB_Host = "localhost" ! DB_Database = "phpslash" ! DB_User = "phpslash" ! DB_Password = "phpslash" ! ;; end of database variables ! ;;; ! ;;; ! ;; PHPLIB configuration ! ;; ! ;; directory where PHPLIB classes and functions can be found ! phplibdir = "/home/leingang/src/phplib-0.74.20021205.dev/php/" ! ;; Used only if the location is not defined in local php.ini or .htaccess ! ;; DEPRECATED -- replaced by loadLibrary("phplib") (MPL 2002/12/19) ! ;prependfile = "/home/nathan/webDevel/php-lib-stable/php/prepend.php" ! ;; end of PHPLIB config ! ;;; ! ;;; ! ;; RSS Exporter Values: ! ;; ! ;; These values are used in your RSS Feeds generated by backend.php3 as ! ;; well as by phpslash for the pages your views see. Please take a ! ;; moment and adjust these to the correct value ! ;; ! ;; Name of the site. This appears for example on the titlebar of ! ;; browser windows. site_name = "PHPSlash" ! ;; ! ;; Email address to reach a human. ! site_owner = "lei...@ma..." ! ;; ! ;; A catch phrase for your site. site_slogan = "Slash for you, Slash for me" ! ;; ! ;; A Longer version of the title. site_title = "PHPSlash: The Web Stops Here" + ;; + ;; end RSS exporter values + ;;; ! ;;; ! ;; Mailing list configuration ! ;; ! ;; Use this for the subject of periodic e-mails with headlines sent to ! ;; users of your site. mailinglist_subject = "PHPSlash Times" + ;; end of mailing list configuration + ;;; ! ;;; ! ;; randomization ! ;; ! ;; Use this secret string when generating site unique variables. For ! ;; security's sake, change this to something, anything. magic = "ChangeThisToSomethingUnique" + ;;; ;; End of Site determinant variables *************** *** 57,103 **** ;; Optional Configuration ! ; Sets the default skin for a site ! ; no css skin - "default" defaultskin = "basic" ! ; allow self registration. ! ; set to 'reg' for self registration, 'log' otherwise. authmode = "reg" ! ;; turns the Admin link on in the navbar show_admin_on_navbar = false ;;; ;; TopicBar Options ! ; These following two variables control ! ; how the topic icons get organized after submitting a story: ! ! ; automatically reorganizes the topic icons ! ; after publishing a new article auto_renorm = false ! ! ; default number of icons in bar bar_limit = 5 ;;; ;;; ;; Comment Options ! ; The comment_defaultmode variable allows you to define how the comments ! ; will look the first time a visitor views a story. It can be one of the ! ; following options: ! ; thread: the first comment is displayed, the replies are then listed in ! ; index style ! ; index: the subject/author/date is listed. you have to click on the ! ; link to get the full subject ! ; nested: all the comments are displayed and are indented to show the ! ; parent/child relationship between the comments. ! ; flat: all the comments are displayed like the nested view but without ! ; any indentation. ! ; none: no comments are displayed. ! comment_defaultmode = "nested" ! ! ; decides if new comments are marked pending ! ; basically allows you to moderate the posts. default_pending = false ;;; end of Comment Options --- 179,240 ---- ;; Optional Configuration ! ;; The "skin" is the basic look for your site. PHPSlash ships with two, ! ;; both HTML 4.0 Transitional. The "basic" skin does all formatting ! ;; with CSS, whereas the "default" skin uses <font> tags and such. defaultskin = "basic" ! ;;; ! ;; Registration mode: ! ;; 'reg' - allow users to register themselves and create accounts on your site ! ;; 'log' - restrict the creation of new accounts to administrators authmode = "reg" + ;;; ! ;;; ! ;; NavBar settings ! ;; The Navigation bar gives links to various areas of the site. ! ;; ! ;; Turn the Admin link on/off in the navbar ! ;; Joe Stewart writes: ! ;; ! ;; "The login/logout links are available in the menuarray now. This was ! ;; the last of the navbar links that were in NavBar.class instead of the ! ;; data array. Now you can just comment out the login link and still ! ;; have the logout link available." show_admin_on_navbar = false + ;; end of NavBar settings + ;;; ;;; ;; TopicBar Options ! ;; ! ;; These following two variables control how the topic icons get ! ;; organized after submitting a story: ! ;; ! ;; Automatically reorganize the topic icons after publishing a new article auto_renorm = false ! ;; ! ;; Put this number of icons in the topic bar bar_limit = 5 + ;; end of TopicBar settings ;;; ;;; ;; Comment Options ! ;; The comment_defaultmode variable allows you to define how the comments ! ;; will look the first time a visitor views a story. It can be one of the ! ;; following options: ! ;; thread: the first comment is displayed, the replies are then listed in ! ;; index style ! ;; index: the subject/author/date is listed. you have to click on the ! ;; link to get the full subject ! ;; nested: all the comments are displayed and are indented to show the ! ;; parent/child relationship between the comments. ! ;; flat: all the comments are displayed like the nested view but without ! ;; any indentation. ! ;; none: no comments are displayed. comment_defaultmode = "nested" ! ;; ! ;; Mark new comments pending (basically allows you to moderate the posts). default_pending = false ;;; end of Comment Options *************** *** 105,138 **** ;;; ;; Poll Options ! ! ; When creating a poll, you have a question ! ; and at least this number of blanks. poll_min_answers = 8 ! ;;; end of Poll Options ! ! ;; Search Options ! ; the number of results to return when searching search_maxresults = 20 ! ! ; Do we allow search of the comments as well? allow_comment_search = true ;;; end of Search Options ! ;; Submission Options ! ! ; if set to true then when you click "edit as story", the submission ! ; will automatically be deleted wheather or not you finished saving ! ; the story submission_autodelete = false ;;; end of Submission Options ! ;; Article(Story) Options ! ! ; Next/Prev link on article page article_nextprevlinks = true ! ! ; Keeps track of hits on a story ! ; the drawback is an extra DB query. article_updatehits = true ;;; end of Article Options --- 242,272 ---- ;;; ;; Poll Options ! ;; ! ;; When creating a poll, you have a question and at least this number of ! ;; blanks. poll_min_answers = 8 ! ;; end of Poll Options ! ;;; ! ;;; ! ;; Search Page Options ! ;; ! ;; Return this many results when searching search_maxresults = 20 ! ;; Allow search of the comments as well allow_comment_search = true ;;; end of Search Options ! ;;; Submission Options ! ;; ! ;; Delete submission when "edit as story" is clicked on the submissions ! ;; page submission_autodelete = false ;;; end of Submission Options ! ;;; Article(Story) Options ! ;; Put Next and Previous story links on each article page article_nextprevlinks = true ! ;; Keep track of hits on a story (the drawback is an extra DB query). article_updatehits = true ;;; end of Article Options *************** *** 140,220 **** ;;; ;; Block Options ! ! ; the minimum number of options available for a block. block_optioncount = 4 ;;; end of Block Options home_section_id = 3 ! site_homesection = "Home" mainpage = "index.php3" ! ; Seconds to cache the formatted output in a serialized variable ! ; saveStory clears the cache. Default is no cache. ! ; always set expirerelated >= expirestory expirestory = 0 expirerelated = 14400 ;;; ;; Debug options ! ; true for on, false for off debug = false ! ; Debug type: ! ; 'now' for output to the browser ! ; 'log' for output to the admin log ! ; 'mail' to e-mail output ! debug_type = now ! ; Mail debug output to (e.g., "web...@ph..."); ! ; CAUTION: Generates one message per debug call, not per page. ! debug.mailto = '' ! ; Recurse through data structures down this far. ! ; Use -1 if you are not afraid of circular references, or ! ; 1 for previous behavior debug.max_recursion_level = 10 ! ; Escape html in debug output debug.escape_html = true ! ;;; end of Debug Options ! ;; Informational Logging ! ; true for on, false for off use_infolog = true ;;; ;; Locale Options ! ; ;; Default language ( ISO format) language = "en" ! [locale] ! ;; You can enter a locale name for any of the categories except LC_ALL. ! ;; For instance, LC_TIME is used for formatting of date and time strings LC_TIME = "en_US" ! ! ;; LC_MESSAGES could be used for translation of messages. ! ;; Currently, it is derived from $_PSL['language'] LC_MESSAGES = "en" ! ! ;;; end of locale definitions ! ;;; ;; Timezone Options - ; [timezone] ! ! ;; Set this to something true if you want times to be calculated in a different time zone. engine = true ! ;; Now you have to choose the implementation of time zones. If you are ;; on a UNIX platform and can set environment variables, native is probably ;; the implemention for you. native = true ! ;; Otherwise, you can use the time zone classes which interface the ;; time zone database, if you have one. Specify the directory here (good ;; to do even if you are using native time zones): dir = "/usr/share/zoneinfo" ! ;; If you can't do that either, you are stuck specifying time zones as ;; POSIX-compatible strings. In any case, you need to specify the --- 274,370 ---- ;;; ;; Block Options ! ;; Use this number as the minimum number of options available for a block. block_optioncount = 4 ;;; end of Block Options + ;;; + ;; Homepage options + ;; + ;; Name of the default section (what you want browsers to see when they + ;; first enter the site + site_homesection = "Home" + ;; ID in the database of the above section home_section_id = 3 ! ;; use this script as the default for the site (relative to rooturl) mainpage = "index.php3" + ;;; end of Homepage options ! ;;; ! ;; Story Cache options ! ;; ! ;; Cache the formatted output of the story in a serialized variable for ! ;; this many seconds. Zero seconds => never cache the story. ! ;; FYI: 3600 seconds == 1 hour; 86400 seconds == 1 day. expirestory = 0 + + ;; Cache the "related links" of the story in a serialized variable for + ;; this many seconds. + ;; WARNING: always set expirerelated >= expirestory expirerelated = 14400 + ;; end of Story Cache options + ;;; ;;; ;; Debug options ! ;; ! ;; Debug variables and messages (i.e., do not suppress output from calls ! ;; to the debug function) debug = false ! ;; Send debugging information here. Use: ! ;; 'now' for output to the browser ! ;; 'log' for output to the admin log ! ;; 'mail' to e-mail output ! debug_type = "now" ! ;; Mail debug output here (e.g., "web...@ph..."); ! ;; CAVEAT: Generates one message per debug call, not per page. ! debug.mailto = ! ;; Recurse through data structures down this far. ! ;; Use -1 if you are not afraid of circular references, or ! ;; 1 for pre-M7 behavior debug.max_recursion_level = 10 ! ;; Escape html in debug output debug.escape_html = true ! ;; end of Debug Options ! ;;; + ;;; ;; Informational Logging ! ;; Log messages from PHPSlash to administrators in the database use_infolog = true + ;;; ;;; ;; Locale Options ! ;; ;; Default language ( ISO format) language = "en" ! ;; [locale] ! ;; Use this locale for formatting date and time strings LC_TIME = "en_US" ! ;; Use this locale for the translation of messages ! ;; (NOT USED -- use 'language' directive instead) LC_MESSAGES = "en" ! ;; end of locale definitions ! ;;; ;;; ;; Timezone Options [timezone] ! ;; Set this to something true if you want times to be calculated in a ! ;; different time zone. engine = true ! ;; ;; Now you have to choose the implementation of time zones. If you are ;; on a UNIX platform and can set environment variables, native is probably ;; the implemention for you. native = true ! ;; ;; Otherwise, you can use the time zone classes which interface the ;; time zone database, if you have one. Specify the directory here (good ;; to do even if you are using native time zones): dir = "/usr/share/zoneinfo" ! ;; ;; If you can't do that either, you are stuck specifying time zones as ;; POSIX-compatible strings. In any case, you need to specify the *************** *** 222,251 **** ;; want the default to be the actual server's setting, enter it this ;; way (find the right path): ! ;; default = ":/etc/localtime"; ! ;; If you are not using native timezones, but are using the time zone ;; database, specify a meaningful time zone name here. You can also use ;; this to fake the server's time zone. - name = "America/Chicago"; ! ;; Finally, if all you are able to do is specify a string, do it like this: ! ! ;; name = "GMT+0BST,M4.1.0/1,M10.5.0/2"; ! ! ;;; end of timezone definitions ! ;;; ;; Metatag Definitions ! ; ;; Metatags that may need to be overwritten later (article description). ;; Other metatags should probably just reside in slashHead.tpl [metatags] - keywords = "weblog, content management, php" ! ! ; Note that this too is used by the backend module in your RSS feed. ! ; Please change it! description = "phpSlash is a port of the slash-0.2 code from Perl to PHP. Since it was first started, phpslash has become a different beast of its own. It currently boasts full HTML templates, an OO design, the ability to operate in a hosted environment, and a bunch of other goodies." ;;; end of metatags definitions --- 372,402 ---- ;; want the default to be the actual server's setting, enter it this ;; way (find the right path): ! ; default = ":/etc/localtime"; ! ;; ;; If you are not using native timezones, but are using the time zone ;; database, specify a meaningful time zone name here. You can also use ;; this to fake the server's time zone. name = "America/Chicago"; ! ;; ;; Finally, if all you are able to do is specify a string, do it like this: ! ; name = "GMT+0BST,M4.1.0/1,M10.5.0/2"; ! ;; end of timezone definitions ! ;;; ;;; ;; Metatag Definitions ! ;; ! ;; Metatags will be inserted into your site's pages as ... <meta> tags. ! ;; They are useful for explaining to robots like search engines just ! ;; what it is your site is concerned with. ! ;; ;; Metatags that may need to be overwritten later (article description). ;; Other metatags should probably just reside in slashHead.tpl [metatags] keywords = "weblog, content management, php" ! ;; ! ;; Short summary of your site. ! ;; Note that this too is used by the backend module in your RSS feed. ! ;; Please change it! description = "phpSlash is a port of the slash-0.2 code from Perl to PHP. Since it was first started, phpslash has become a different beast of its own. It currently boasts full HTML templates, an OO design, the ability to operate in a hosted environment, and a bunch of other goodies." ;;; end of metatags definitions *************** *** 253,272 **** ;;; ;; Module registration ! ; [module] ! ;; true => on, false => off Glossary = true MailingList = true Block = true Comment = true TopicBar = true NavBar = true Poll = true Section = true Story = true Submission = true Infolog = true Author = true Variable = false Group = true ;;; end of module definitions --- 404,448 ---- ;;; ;; Module registration ! ;; ! ;; Modules add functionality to PHPSlash. [module] ! ;; Turn any of these off, and the link will not appear on the navbar, ! ;; nor will the excess code be compiled. Make sure you're really not ! ;; using it, though! ! ;; ! ;; Set up a glossary page where administrators can insert ! ;; term definitions Glossary = true + ;; Allow users to subscribe to a mailing list to get + ;; headlines (the actual mailing is handled elsewhere; see the file + ;; cronmail.php3 MailingList = true + ;; Provide a container for small bits of HTML to be incorporated into + ;; side columns of pages. Block = true + ;; Allow users of your site to leave and peruse comments. Comment = true + ;; Show a row of icons relating to topics for which stories have been + ;; posted recently. TopicBar = true + ;; Show a row of links relating to various modules within the site. NavBar = true + ;; Allow administrators to create polls on your site. Poll = true + ;; Allow administrators to create and modify site sections Section = true + ;; Allow administrators to create, modify, and post stories Story = true + ;; Allow users to submit new stories (they won't appear until posted by + ;; trusted author, however) Submission = true + ;; Allow administrators to view the informational log Infolog = true + ;; Allow administrators to create/modify/delete authors Author = true + ;; Allow administrators to modify site variables + ;; (Not sure how much this is used) Variable = false + ;; Allow administrators to create and modify user groups. Group = true ;;; end of module definitions *************** *** 275,281 **** ;;; ;; Approved HTML tags for user comments ! ; ! ; 2 means accept all qualifiers: <foo bar> ! ; 1 means accept the tag only: <foo> [approvedtags] p = 1 --- 451,457 ---- ;;; ;; Approved HTML tags for user comments ! ;; ! ;; 2 means accept all qualifiers: <foo bar> ! ;; 1 means accept the tag only: <foo> [approvedtags] p = 1 |
From: Matthew L. <sym...@us...> - 2002-12-19 23:36:57
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv11728 Modified Files: CHANGES Log Message: dox added to config-dist.ini.php3 Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.635 retrieving revision 1.636 diff -C2 -d -r1.635 -r1.636 *** CHANGES 19 Dec 2002 16:19:18 -0000 1.635 --- CHANGES 19 Dec 2002 23:36:54 -0000 1.636 *************** *** 13,16 **** --- 13,19 ---- 9 - Removal of something (kill -9 :) + 2002-December-19 18:30 EST Matthew Leingang <sym...@us...> + [D] - Added verbose documentation to config-dist.ini.php3. + 2002-December-19 10:00AM CST Joe Stewart <joe...@us...> [B] - poll.php3 - IP address available with register_globals off. *************** *** 19,22 **** --- 22,29 ---- [WS] - removed old logging_mod and associated db table - affected files: slash-all.sql and all files in logging_mod/ directory. + + 2002-December-19 07:30 EST Matthew Leingang <sym...@us...> + [B] - Fixed a bug in pslGetClass that had caused it to do nothing except + return its input. 2002-December-16 23:00 GMT Matthew Leingang <sym...@us...> |
From: Joe S. <joe...@us...> - 2002-12-19 16:19:22
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv3338/phpslash-ft/public_html Modified Files: poll.php3 Log Message: can vote with register_globals off now Index: poll.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/poll.php3,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** poll.php3 11 Dec 2002 21:25:54 -0000 1.20 --- poll.php3 19 Dec 2002 16:19:19 -0000 1.21 *************** *** 61,65 **** switch ($ary['submit']) { case "vote": ! if($poll->vote($question_id, $ary['answer_id'], $REMOTE_ADDR)) { $content .= pslgetText('VOTE: ') . $poll->message . "<BR>\n"; } else { --- 61,65 ---- switch ($ary['submit']) { case "vote": ! if($poll->vote($question_id, $ary['answer_id'], $_SERVER['REMOTE_ADDR'])) { $content .= pslgetText('VOTE: ') . $poll->message . "<BR>\n"; } else { |
From: Joe S. <joe...@us...> - 2002-12-19 16:19:22
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv3338/phpslash-ft Modified Files: CHANGES Log Message: can vote with register_globals off now Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.634 retrieving revision 1.635 diff -C2 -d -r1.634 -r1.635 *** CHANGES 19 Dec 2002 16:12:15 -0000 1.634 --- CHANGES 19 Dec 2002 16:19:18 -0000 1.635 *************** *** 14,17 **** --- 14,20 ---- 2002-December-19 10:00AM CST Joe Stewart <joe...@us...> + [B] - poll.php3 - IP address available with register_globals off. + + 2002-December-19 10:00AM CST Joe Stewart <joe...@us...> [WS] - removed old logging_mod and associated db table - affected files: slash-all.sql and all files in logging_mod/ directory. |
From: Joe S. <joe...@us...> - 2002-12-19 16:12:21
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/logging_mod In directory sc8-pr-cvs1:/tmp/cvs-serv28048/phpslash-ft/public_html/logging_mod Removed Files: README chart_pie.php3 doc.html gif11.php3 graph_func.php3 logit.inc referrer.php3 report.php3 rpt_func.inc Log Message: remove old logging_mod --- README DELETED --- --- chart_pie.php3 DELETED --- --- doc.html DELETED --- --- gif11.php3 DELETED --- --- graph_func.php3 DELETED --- --- logit.inc DELETED --- --- referrer.php3 DELETED --- --- report.php3 DELETED --- --- rpt_func.inc DELETED --- |
From: Joe S. <joe...@us...> - 2002-12-19 16:12:21
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv28048/phpslash-ft Modified Files: CHANGES Log Message: remove old logging_mod Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.633 retrieving revision 1.634 diff -C2 -d -r1.633 -r1.634 *** CHANGES 17 Dec 2002 16:40:24 -0000 1.633 --- CHANGES 19 Dec 2002 16:12:15 -0000 1.634 *************** *** 13,16 **** --- 13,20 ---- 9 - Removal of something (kill -9 :) + 2002-December-19 10:00AM CST Joe Stewart <joe...@us...> + [WS] - removed old logging_mod and associated db table - affected files: + slash-all.sql and all files in logging_mod/ directory. + 2002-December-16 23:00 GMT Matthew Leingang <sym...@us...> [W] - Took out a "foreach" block in the class registration of PHPLIB in |
From: Joe S. <joe...@us...> - 2002-12-19 16:12:21
|
Update of /cvsroot/phpslash/phpslash-ft/tables/0.7 In directory sc8-pr-cvs1:/tmp/cvs-serv28048/phpslash-ft/tables/0.7 Modified Files: slash-all.sql Log Message: remove old logging_mod Index: slash-all.sql =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/tables/0.7/slash-all.sql,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** slash-all.sql 22 Nov 2002 17:42:55 -0000 1.21 --- slash-all.sql 19 Dec 2002 16:12:16 -0000 1.22 *************** *** 51,78 **** # - # Table structure for table `activity_log` - # - - CREATE TABLE activity_log ( - time datetime NOT NULL default '0000-00-00 00:00:00', - user_agent text, - remote_addr text, - remote_host text, - uri text, - os text, - browser text, - page text, - referer text, - sid text, - KEY time (time) - ) TYPE=MyISAM; - - # - # Dumping data for table `activity_log` - # - - # -------------------------------------------------------- - - # # Table structure for table `auth_user` # --- 51,54 ---- |
From: Matthew L. <sym...@us...> - 2002-12-19 12:27:59
|
Update of /cvsroot/phpslash/phpslash-ft/class In directory sc8-pr-cvs1:/tmp/cvs-serv30532/class Modified Files: lib.resources.php Log Message: Fixed a bug in pslGetClass that caused it to do nothing except return the input. Should work as advertised now. Index: lib.resources.php =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/lib.resources.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** lib.resources.php 12 Dec 2002 13:53:50 -0000 1.2 --- lib.resources.php 19 Dec 2002 12:27:56 -0000 1.3 *************** *** 144,153 **** // debug($fc,"begin"); $urn = classUrn($class); ! $rep = resource_replacement($urn); ! list($nid,$nss) = parse_urn($urn); ! if ('class' == $nid) { ! $answer = $nss; } else { $answer = $class; } --- 144,155 ---- // debug($fc,"begin"); $urn = classUrn($class); ! $repUrn = resource_replacement($urn); ! $urnPieces = parse_urn($repUrn); ! // debug("$fn:pieces",$urnPieces); ! if ('class' == $urnPieces['NID']) { ! $answer = $urnPieces['NSS']; } else { + // strange NID, or $repUrn was empty $answer = $class; } |
From: Matthew L. <sym...@us...> - 2002-12-17 16:40:30
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv5568 Modified Files: CHANGES Log Message: Fixed registering of PHPLIB classes. Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.632 retrieving revision 1.633 diff -C2 -d -r1.632 -r1.633 *** CHANGES 13 Dec 2002 21:59:58 -0000 1.632 --- CHANGES 17 Dec 2002 16:40:24 -0000 1.633 *************** *** 13,16 **** --- 13,24 ---- 9 - Removal of something (kill -9 :) + 2002-December-16 23:00 GMT Matthew Leingang <sym...@us...> + [W] - Took out a "foreach" block in the class registration of PHPLIB in + config.php3 and config-dist.php3. This allows for more flexibility + vis-a-vis class names and file names. + + [B] - Also replaced the URN urn:class:db_mysql with urn:class:db_sql, + as the latter is a valid class. + 2002-December-13 4:00PM CST Joe Stewart <joe...@us...> [B] - config-dist.php3 - attempt to sync config-dist.php3 with config.php3. |
From: Matthew L. <sym...@us...> - 2002-12-16 22:49:55
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv22009 Modified Files: config.php3 config-dist.php3 Log Message: Took out a "foreach" block in the class registration of PHPLIB. This allows for more flexibility vis-a-vis class names and file names. Also replaced the URN urn:class:db_mysql with urn:class:db_sql, as the latter is a valid class. Index: config.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config.php3,v retrieving revision 1.172 retrieving revision 1.173 diff -C2 -d -r1.172 -r1.173 *** config.php3 13 Dec 2002 17:34:25 -0000 1.172 --- config.php3 16 Dec 2002 22:49:51 -0000 1.173 *************** *** 93,97 **** // $basedir -> Complete filesystem path to the pages ! $_PSL['basedir'] = '/home/leingang/src/phpslash-ft-test/public_html'; // $templatedir -> Path to the templates directory --- 93,97 ---- // $basedir -> Complete filesystem path to the pages ! $_PSL['basedir'] = '/home/leingang/src/phpslash-ft/public_html'; // $templatedir -> Path to the templates directory *************** *** 99,106 **** // $classdir -> Path to the class directory ! $_PSL['classdir'] = '/home/leingang/src/phpslash-ft-test/class'; // $rooturl -> The base URL for the phpslash site ! $_PSL['rooturl'] = 'http://marlowe.rutgers.edu/phpslash-test'; // $adminurl -> The base URL for the admin pages --- 99,106 ---- // $classdir -> Path to the class directory ! $_PSL['classdir'] = '/home/leingang/src/phpslash-ft/class'; // $rooturl -> The base URL for the phpslash site ! $_PSL['rooturl'] = 'http://marlowe.rutgers.edu/phpslash'; // $adminurl -> The base URL for the admin pages *************** *** 156,166 **** * file's not processed automatically. **/ ! foreach(array("db_mysql","ct_sql","session","auth","perm","template") ! as $class) { ! addClassRequirement($class,$_PHPLIB['libdir'] ."$class.inc"); ! addLibraryRequirement("phplib",classURN($class)); ! } ! addLibraryRequirement("phplib",$_PHPLIB['libdir'] . "page.inc"); ! loadLibrary("phplib"); /** --- 156,175 ---- * file's not processed automatically. **/ ! addClassRequirement('db_sql',$_PHPLIB['libdir'] .'db_mysql.inc'); ! addLibraryRequirement('phplib',classURN('db_sql')); ! addClassRequirement('ct_sql',$_PHPLIB['libdir'] .'ct_sql.inc'); ! addLibraryRequirement('phplib',classURN('ct_sql')); ! addClassRequirement('session',$_PHPLIB['libdir'] .'session.inc'); ! addLibraryRequirement('phplib',classURN('session')); ! addClassRequirement('auth',$_PHPLIB['libdir'] .'auth.inc'); ! addLibraryRequirement('phplib',classURN('auth')); ! addClassRequirement('perm',$_PHPLIB['libdir'] .'perm.inc'); ! addLibraryRequirement('phplib',classURN('perm')); ! addClassRequirement('template',$_PHPLIB['libdir'] .'template.inc'); ! addLibraryRequirement('phplib',classURN('template')); ! addLibraryRequirement('phplib',$_PHPLIB['libdir'] . 'page.inc'); ! loadLibrary('phplib'); ! ! /** *************** *** 173,177 **** addClassRequirement("slash_sql","ct_sql"); addClassRequirement("slash_sql",$_PSL['classdir'] . "/slash_sql.class"); ! addClassRequirement("slashDB","db_mysql"); addClassRequirement("slashDB",$_PSL['classdir'] . "/slashDB.class"); addClassRequirement("slashSess","session"); --- 182,186 ---- addClassRequirement("slash_sql","ct_sql"); addClassRequirement("slash_sql",$_PSL['classdir'] . "/slash_sql.class"); ! addClassRequirement("slashDB","db_sql"); addClassRequirement("slashDB",$_PSL['classdir'] . "/slashDB.class"); addClassRequirement("slashSess","session"); *************** *** 258,262 **** // Type specific jpcache implementations if ('phplib' == $JPCACHE_TYPE) { ! addClassRequirement("jpcacheDB","db_mysql"); addClassRequirement("jpcacheDB",$_PSL['jpcachedir'] ."/type/phplib.php"); } --- 267,271 ---- // Type specific jpcache implementations if ('phplib' == $JPCACHE_TYPE) { ! addClassRequirement("jpcacheDB","db_sql"); addClassRequirement("jpcacheDB",$_PSL['jpcachedir'] ."/type/phplib.php"); } Index: config-dist.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config-dist.php3,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** config-dist.php3 13 Dec 2002 21:59:59 -0000 1.21 --- config-dist.php3 16 Dec 2002 22:49:52 -0000 1.22 *************** *** 172,182 **** * file's not processed automatically. **/ ! foreach(array("db_mysql","ct_sql","session","auth","perm","template") ! as $class) { ! addClassRequirement($class,$_PHPLIB['libdir'] ."$class.inc"); ! addLibraryRequirement("phplib",classURN($class)); ! } ! addLibraryRequirement("phplib",$_PHPLIB['libdir'] . "page.inc"); ! loadLibrary("phplib"); /** --- 172,191 ---- * file's not processed automatically. **/ ! addClassRequirement('db_sql',$_PHPLIB['libdir'] .'db_mysql.inc'); ! addLibraryRequirement('phplib',classURN('db_sql')); ! addClassRequirement('ct_sql',$_PHPLIB['libdir'] .'ct_sql.inc'); ! addLibraryRequirement('phplib',classURN('ct_sql')); ! addClassRequirement('session',$_PHPLIB['libdir'] .'session.inc'); ! addLibraryRequirement('phplib',classURN('session')); ! addClassRequirement('auth',$_PHPLIB['libdir'] .'auth.inc'); ! addLibraryRequirement('phplib',classURN('auth')); ! addClassRequirement('perm',$_PHPLIB['libdir'] .'perm.inc'); ! addLibraryRequirement('perm',classURN('perm')); ! addClassRequirement('template',$_PHPLIB['libdir'] .'template.inc'); ! addLibraryRequirement('phplib',classURN('template')); ! addLibraryRequirement('phplib',$_PHPLIB['libdir'] . 'page.inc'); ! loadLibrary('phplib'); ! ! /** *************** *** 189,193 **** addClassRequirement("slash_sql","ct_sql"); addClassRequirement("slash_sql",$_PSL['classdir'] . "/slash_sql.class"); ! addClassRequirement("slashDB","db_mysql"); addClassRequirement("slashDB",$_PSL['classdir'] . "/slashDB.class"); addClassRequirement("slashSess","session"); --- 198,202 ---- addClassRequirement("slash_sql","ct_sql"); addClassRequirement("slash_sql",$_PSL['classdir'] . "/slash_sql.class"); ! addClassRequirement("slashDB","db_sql"); addClassRequirement("slashDB",$_PSL['classdir'] . "/slashDB.class"); addClassRequirement("slashSess","session"); *************** *** 274,278 **** // Type specific jpcache implementations if ('phplib' == $JPCACHE_TYPE) { ! addClassRequirement("jpcacheDB","db_mysql"); addClassRequirement("jpcacheDB",$_PSL['jpcachedir'] ."/type/phplib.php"); } --- 283,287 ---- // Type specific jpcache implementations if ('phplib' == $JPCACHE_TYPE) { ! addClassRequirement("jpcacheDB","db_sql"); addClassRequirement("jpcacheDB",$_PSL['jpcachedir'] ."/type/phplib.php"); } |
From: Matthew L. <sym...@us...> - 2002-12-16 22:28:23
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv14505 Modified Files: index.php3 Log Message: Deleted extraneous debugging code Index: index.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/index.php3,v retrieving revision 1.63 retrieving revision 1.64 diff -C2 -d -r1.63 -r1.64 *** index.php3 11 Dec 2002 21:25:54 -0000 1.63 --- index.php3 16 Dec 2002 22:28:17 -0000 1.64 *************** *** 26,31 **** slashhead($pagetitle,$_PSL['metatags']); - debug("ary",$ary); - $allstories = $story->getStories($ary); $leftblocks = $block->getBlocks($ary, "left"); --- 26,29 ---- |
From: Joe S. <joe...@us...> - 2002-12-13 22:00:02
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv5169/phpslash-ft/public_html Modified Files: config-dist.php3 Log Message: attempt to sync config-dist.php3 with config.php3 Index: config-dist.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config-dist.php3,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** config-dist.php3 3 Dec 2002 20:27:35 -0000 1.20 --- config-dist.php3 13 Dec 2002 21:59:59 -0000 1.21 *************** *** 9,13 **** // Specify full path to ini file ! $psl_inifile = "/var/www/sandbox/config.ini.php3"; // end of required configuration. config.ini.php3 contains the phpSlash --- 9,13 ---- // Specify full path to ini file ! $psl_inifile = "config.ini.php3"; // end of required configuration. config.ini.php3 contains the phpSlash *************** *** 87,92 **** // 1.1 Uncomment this only if you can't use a local php.ini or .htaccess ! if( !empty($_PSL['prependfile'])) { ! require($_PSL['prependfile']); } // 1.11) Global Variables. (Don't add trailing slashes) --- 87,94 ---- // 1.1 Uncomment this only if you can't use a local php.ini or .htaccess ! if( !empty($_PSL['phplibdir'])) { ! $_PHPLIB['libdir'] = $_PSL['phplibdir']; ! } else { ! $_PHPLIB['libdir'] = '/var/www/phplib/phplib-0.74.20021016/php/'; } // 1.11) Global Variables. (Don't add trailing slashes) *************** *** 129,132 **** --- 131,223 ---- } + // 1.3) PHPSlash functions library + require_once($_PSL['classdir'] . '/functions.inc'); + require_once($_PSL['classdir'] . '/lib.resources.php'); + + /* now that the functions are in, we can define the arg_separator */ + + $_PSL['amp'] = arg_separator("1"); + + // 1.99) Add any other require()'s or include()'s you need here and they + // should be prepended to all phpSlash pages + + // comment to enable setting lang in url + $lang = false; + + $_PSL['languagefile'] = $_PSL['localedir'] . "/" . $_PSL['language'] . ".php3"; + + // comment to disable auto lang detection + $_PSL['languagefile'] = setLang($lang); + + // comment to disable auto tpl lang detection + $_PSL['templatedir'] = setLangTpl($lang); + + // comment out this block to disable setting theme in url + if (!empty($HTTP_GET_VARS['skin'])) { + $_PSL['templatedir'] = setSkinTpl($HTTP_GET_VARS['skin'], "cookie"); + } else { + $_PSL['templatedir'] = setSkinTpl("", "cookie"); + } + + + /** + * Class information. Add any class replacements like this: + * + * AddClassReplacement("template","myTemplate"); + * + * This will make PHPSlash use your class instead of its defaults. + * + * First we load the PHPLIB basic classes. This next block of code does + * the work of $_PHPLIB['libdir'] . 'prepend.php3', so make sure that + * file's not processed automatically. + **/ + foreach(array("db_mysql","ct_sql","session","auth","perm","template") + as $class) { + addClassRequirement($class,$_PHPLIB['libdir'] ."$class.inc"); + addLibraryRequirement("phplib",classURN($class)); + } + addLibraryRequirement("phplib",$_PHPLIB['libdir'] . "page.inc"); + loadLibrary("phplib"); + + /** + * These classes are PHPSlash's extensions to the PHPLIB base classes. + * We only configure the ones which are required to get the page open + * and restore session data. + * + * Note: author IS needed now because slashAuth uses it to fill in perms + **/ + addClassRequirement("slash_sql","ct_sql"); + addClassRequirement("slash_sql",$_PSL['classdir'] . "/slash_sql.class"); + addClassRequirement("slashDB","db_mysql"); + addClassRequirement("slashDB",$_PSL['classdir'] . "/slashDB.class"); + addClassRequirement("slashSess","session"); + addClassRequirement("slashSess",$_PSL['classdir'] . "/slashSess.class"); + addClassRequirement("slashAuth",$_PSL['classdir'] . "/slashAuthCR.class"); + addClassRequirement("slashPerm","perm"); + addClassRequirement("slashPerm",$_PSL['classdir'] . "/slashPerm.class"); + addClassRequirement("author",$_PSL['classdir'] . "/Author.class"); + addLibraryRequirement("phpslash",$_PSL['classdir'] . "/functions.inc"); + + /** + * Register like above any classes instantiations of which you intend to + * use for session variables. + * + * For example, say you want to sessionize the time zone: + **/ + //AddClassRequirement("tz",$_PSL['classdir'] . "/tz.class"); + //AddLibraryRequirement("tz",$_PSL['classdir'] . "/tz_functions.inc"); + //AddClassRequirement("tz_env","tz"); + //AddClassRequirement("tz_env",$_PSL['classdir'] . "/tz_env.class"); + //AddClassRequirement("tz_nonnative","tz"); + //AddClassRequirement("tz_nonnative",$_PSL['classdir'] . "/tz_nonnative.class"); + //AddClassRequirement("tz_posix","tz_nonnative"); + //AddClassRequirement("tz_posix",$_PSL['classdir'] . "/tz_posix.class"); + //AddClassRequirement("tz_file","tz_nonnative"); + //AddClassRequirement("tz_file",$_PSL['classdir'] . "/tz_file.class"); + /** + * this necessity will change when the entire resource hash becomes + * sessionized. + */ + // begin built-in jpcache if(empty($GLOBALS['JPCACHE_TYPE'])) { *************** *** 148,152 **** $JPCACHE_DEBUG = 0; // Turn debugging on/off $JPCACHE_IGNORE_DOMAIN= 1; // Ignore domain name in request(single site) ! $JPCACHE_ON = 1; // Turn caching on/off $JPCACHE_USE_GZIP = 0; // Whether or not to use GZIP $JPCACHE_POST = 1; // Should POST's be cached --- 239,243 ---- $JPCACHE_DEBUG = 0; // Turn debugging on/off $JPCACHE_IGNORE_DOMAIN= 1; // Ignore domain name in request(single site) ! $JPCACHE_ON = 0; // Turn caching on/off $JPCACHE_USE_GZIP = 0; // Whether or not to use GZIP $JPCACHE_POST = 1; // Should POST's be cached *************** *** 179,186 **** // Standard jpcache functions ! require $_PSL['jpcachedir']. "/jpcache-main.php"; ! // Type specific jpcache implementations ! require $_PSL['jpcachedir'] ."/type/$JPCACHE_TYPE.php"; // end of jpcache configuration --- 270,283 ---- // Standard jpcache functions ! // require $_PSL['jpcachedir']. "/jpcache-main.php"; ! addLibraryRequirement("jpcache",$_PSL['jpcachedir'] . "/jpcache-main.php"); // Type specific jpcache implementations ! if ('phplib' == $JPCACHE_TYPE) { ! addClassRequirement("jpcacheDB","db_mysql"); ! addClassRequirement("jpcacheDB",$_PSL['jpcachedir'] ."/type/phplib.php"); ! } ! addLibraryRequirement("jpcache",$_PSL['jpcachedir'] ."/type/$JPCACHE_TYPE.php"); ! loadLibrary("jpcache"); ! // require $_PSL['jpcachedir'] ."/type/$JPCACHE_TYPE.php"; // end of jpcache configuration *************** *** 244,252 **** // is something you've already dealt with in prepend.php3 - require($_PHPLIB['libdir'] . 'template.inc'); - - // 1.3) PHPSlash functions library - require($_PSL['classdir'] . '/functions.inc'); $ary = array(); if(!empty($HTTP_GET_VARS)) { --- 341,349 ---- // is something you've already dealt with in prepend.php3 + /** + * $ary is used by story::getStory and block_i::getBlocks + * this block just merges in the default section + */ $ary = array(); if(!empty($HTTP_GET_VARS)) { *************** *** 262,316 **** } - /* now that the functions are in, we can define the arg_separator */ - $_PSL['amp'] = arg_separator("1"); - - // 1.99) Add any other require()'s or include()'s you need here and they - // should be prepended to all phpSlash pages - - // comment to enable setting lang in url - $lang = false; - - $_PSL['languagefile'] = $_PSL['localedir'] . "/" . $_PSL['language'] . ".php3"; - - // comment to disable auto lang detection - $_PSL['languagefile'] = setLang($lang); ! // comment to disable auto tpl lang detection ! $_PSL['templatedir'] = setLangTpl($lang); ! ! // comment out this block to disable setting theme in url ! if (!empty($HTTP_GET_VARS['skin'])) { ! $_PSL['templatedir'] = setSkinTpl($HTTP_GET_VARS['skin'], "cookie"); ! } else { ! $_PSL['templatedir'] = setSkinTpl("", "cookie"); } ! if ($_PSL['timezone']['engine']) { ! include($_PSL['classdir'] . '/tz.class'); ! include($_PSL['classdir'] . '/tz_env.class'); ! include($_PSL['classdir'] . '/tz_nonnative.class'); ! include($_PSL['classdir'] . '/tz_posix.class'); ! include($_PSL['classdir'] . '/tz_file.class'); ! include($_PSL['classdir'] . '/tz_functions.inc'); ! // set up the time zone environment array ! $_TZ = $_PSL['timezone']; ! $_TZ['templatedir'] = $_PSL['templatedir']; ! $_TZ['show_format'] = psl_getLocalInfo('LC_TIME','%a %b %e %H:%M:%S %Z %Y'); ! /* $_TZ['available'] = array("America/New_York", ! "America/Chicago", ! "America/Denver", ! "America/Los_Angeles", ! "Pacific/Honolulu"); ! */ ! // to enable setting of time zone in URL ! if(!empty($HTTP_GET_VARS['TZ'])) { ! set_TZ($HTTP_GET_VARS['TZ'],'cookie'); ! } else { ! set_TZ('','cookie'); ! } ! // to disable setting in URL and to set $_PSL['timezone']['name'] as the time zone ! // set_TZ(); ! } --- 359,444 ---- } $_PSL['amp'] = arg_separator("1"); ! /** ! * page features, all derived from PHPLIB classes and user-customizable ! **/ ! if (empty($_PSL['page_features'])) { ! foreach(array("sess"=>"slashSess", ! "auth"=>"slashAuth", ! "perm"=>"slashPerm") ! as $name => $class) { ! $class = pslGetClass($class); ! loadClass($class); ! $_PSL['page_features'][$name] = $class; ! } } ! page_open($_PSL['page_features']); ! /** ! * Now the session has started. What is below here will be moving into ! * its own file to be called once per session. ! **/ ! ! /** ! * Rest of the class information ! **/ ! AddClassRequirement("block",$_PSL['classdir'] . "/Block.class"); ! AddClassRequirement("block_i","block"); ! AddClassRequirement("block_i",$_PSL['classdir'] . "/Block_i.class"); ! AddClassRequirement("block_render_i",$_PSL['classdir'] . "/Block_render_i.class"); ! AddClassRequirement("block_render_cal","block_render_i"); ! AddClassRequirement("block_render_cal",$_PSL['classdir'] . "/Block_render_cal.class"); ! AddClassRequirement("block_render_html","block_render_i"); ! AddClassRequirement("block_render_html",$_PSL['classdir'] . "/Block_render_html.class"); ! AddClassRequirement("block_render_login","block_render_i"); ! AddClassRequirement("block_render_login",$_PSL['classdir'] . "/Block_render_login.class"); ! AddClassRequirement("block_render_navbar","block_render_i"); ! AddClassRequirement("block_render_navbar",$_PSL['classdir'] . "/Block_render_navbar.class"); ! AddClassRequirement("block_render_poll","block_render_i"); ! AddClassRequirement("block_render_poll",$_PSL['classdir'] . "/Block_render_poll.class"); ! AddClassRequirement("block_render_query","block_render_i"); ! AddClassRequirement("block_render_query",$_PSL['classdir'] . "/Block_render_query.class"); ! AddClassRequirement("block_render_query","block_render_i"); ! AddClassRequirement("block_render_quote",$_PSL['classdir'] . "/Block_render_quote.class"); ! AddClassRequirement("block_render_section","block_render_i"); ! AddClassRequirement("block_render_section",$_PSL['classdir'] . "/Block_render_section.class"); ! AddClassRequirement("block_render_skin","block_render_i"); ! AddClassRequirement("block_render_skin",$_PSL['classdir'] . "/Block_render_skin.class"); ! AddClassRequirement("block_render_submission","block_render_i"); ! AddClassRequirement("block_render_submission",$_PSL['classdir'] . "/Block_render_submission.class"); ! AddClassRequirement("block_render_topic","block_render_i"); ! AddClassRequirement("block_render_topic",$_PSL['classdir'] . "/Block_render_topic.class"); ! AddClassRequirement("block_render_url","block_render_i"); ! AddClassRequirement("block_render_url",$_PSL['classdir'] . "/Block_render_url.class"); ! AddClassRequirement("block_admin","block_i"); ! AddClassRequirement("block_admin",$_PSL['classdir'] . "/Block_admin.class"); ! AddClassRequirement("comment",$_PSL['classdir'] . "/Comment.class"); ! AddClassRequirement("glossary",$_PSL['classdir'] . "/Glossary.class"); ! AddClassRequirement("group",$_PSL['classdir'] . "/Group.class"); ! AddClassRequirement("infolog",$_PSL['classdir'] . "/Infolog.class"); ! AddClassRequirement("mailinglist",$_PSL['classdir'] . "/MailingList.class"); ! AddClassRequirement("navbar",$_PSL['classdir'] . "/NavBar.class"); ! AddClassRequirement("poll",$_PSL['classdir'] . "/Poll.class"); ! AddClassRequirement("section",$_PSL['classdir'] . "/Section.class"); ! AddClassRequirement("submission",$_PSL['classdir'] . "/Submission.class"); ! AddClassRequirement("story_base",$_PSL['classdir'] . "/Story_base.class"); ! AddClassRequirement("story","story_base"); ! AddClassRequirement("story",$_PSL['classdir'] . "/Story.class"); ! AddClassRequirement("story_admin","story_base"); ! AddClassRequirement("story_admin",$_PSL['classdir'] . "/Story_admin.class"); ! AddClassRequirement("topic",$_PSL['classdir'] . "/Topic.class"); ! AddClassRequirement("topicbar",$_PSL['classdir'] . "/TopicBar.class"); ! AddClassRequirement("tz",$_PSL['classdir'] . "/tz.class"); ! AddLibraryRequirement("tz",$_PSL['classdir'] . "/tz_functions.inc"); ! AddClassRequirement("tz_env","tz"); ! AddClassRequirement("tz_env",$_PSL['classdir'] . "/tz_env.class"); ! AddClassRequirement("tz_nonnative","tz"); ! AddClassRequirement("tz_nonnative",$_PSL['classdir'] . "/tz_nonnative.class"); ! AddClassRequirement("tz_posix","tz_nonnative"); ! AddClassRequirement("tz_posix",$_PSL['classdir'] . "/tz_posix.class"); ! AddClassRequirement("tz_file","tz_nonnative"); ! AddClassRequirement("tz_file",$_PSL['classdir'] . "/tz_file.class"); ! AddClassRequirement("variable",$_PSL['classdir'] . "/variable.class"); *************** *** 354,358 **** 'name' => "Add Story", 'link' => $_PSL['rooturl'] . "/submission.php3", ! 'perm' => "submissionNew", 'module' => "Submission" ); --- 482,486 ---- 'name' => "Add Story", 'link' => $_PSL['rooturl'] . "/submission.php3", ! 'perm' => "nobody", 'module' => "Submission" ); *************** *** 490,502 **** ////////////////////////////////////////////////////////////////////////// - // 2.1) PHPLIB Auth Class extension - // 2.2) PHPLIB Perm Class extension - // 2.3) PHPSlash<->phplib interface classes - require($_PSL['classdir'] . "/slashDB.class"); - require($_PSL['classdir'] . "/slash_sql.class"); - require($_PSL['classdir'] . "/slashSess.class"); - // require($_PSL['classdir'] . "/slashAuth.class"); - require($_PSL['classdir'] . "/slashAuthCR.class"); - require($_PSL['classdir'] . "/slashPerm.class"); // 2.2) PHPLIB Session Support --- 618,621 ---- *************** *** 506,585 **** ////////////////////////////////////////////////////////////////////////// - require($_PSL['classdir'] . "/Topic.class"); - require($_PSL['classdir'] . "/Section.class"); - - foreach($_PSL['module'] as $key => $value) { - - switch ($key) { - - case 'Author': - - require($_PSL['classdir'] . "/Author.class"); - break; - - case 'Block': - - require($_PSL['classdir'] . "/Block.class"); - require($_PSL['classdir'] . "/Block_i.class"); - // require($_PSL['classdir'] . "/Block_admin.class"); - require($_PSL['classdir'] . "/Block_render_i.class"); - break; - - case 'Comment': - - require($_PSL['classdir'] . "/Comment.class"); - break; - - case 'Glossary': - - require($_PSL['classdir'] . "/Glossary.class"); - break; - - case 'Group': - - require($_PSL['classdir'] . "/Group.class"); - break; - - case 'MailingList': - - require($_PSL['classdir'] . "/MailingList.class"); - break; - - - case 'NavBar': - - require($_PSL['classdir'] . "/NavBar.class"); - break; - - case 'Poll': - - require($_PSL['classdir'] . "/Poll.class"); - break; - - case 'Story': - - require($_PSL['classdir'] . "/Story_base.class"); - require($_PSL['classdir'] . "/Story.class"); - // require($_PSL['classdir'] . "/Story_admin.class"); - break; - - case 'Submission': - - require($_PSL['classdir'] . "/Submission.class"); - break; - - case 'TopicBar': - - require($_PSL['classdir'] . "/TopicBar.class"); - break; - - case 'Variable': - - require($_PSL['classdir'] . "/Variable.class"); - break; - - } - - } ////////////////////////////////////////////////////////////////////////// --- 625,628 ---- *************** *** 589,595 **** define("ALLSECTIONS", "section_id0"); ! page_open(array('sess' => 'slashSess', ! 'auth' => 'slashAuth', ! 'perm' => 'slashPerm')); /* ============= Things to deprecate ============= */ --- 632,653 ---- define("ALLSECTIONS", "section_id0"); ! if ($_PSL['timezone']['engine']) { ! loadLibrary("tz"); ! // set up the time zone environment array ! $_TZ =& $_PSL['timezone']; ! $_TZ['templatedir'] = $_PSL['templatedir']; ! $_TZ['show_format'] = psl_getLocalInfo('LC_TIME','%a %b %e %H:%M:%S %Z %Y'); ! /* $_TZ['available'] = array("America/New_York", ! "America/Chicago", ! "America/Denver", ! "America/Los_Angeles", ! "Pacific/Honolulu"); ! */ ! // to enable setting of time zone in URL ! set_TZ($HTTP_GET_VARS['TZ'],'cookie'); ! // to disable setting in URL and to set $_PSL['timezone']['name'] as the time zone ! // set_TZ(); ! } ! /* ============= Things to deprecate ============= */ |
From: Joe S. <joe...@us...> - 2002-12-13 22:00:02
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv5169/phpslash-ft Modified Files: CHANGES Log Message: attempt to sync config-dist.php3 with config.php3 Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.631 retrieving revision 1.632 diff -C2 -d -r1.631 -r1.632 *** CHANGES 13 Dec 2002 17:42:05 -0000 1.631 --- CHANGES 13 Dec 2002 21:59:58 -0000 1.632 *************** *** 13,16 **** --- 13,19 ---- 9 - Removal of something (kill -9 :) + 2002-December-13 4:00PM CST Joe Stewart <joe...@us...> + [B] - config-dist.php3 - attempt to sync config-dist.php3 with config.php3. + 2002-December-13 11:00AM CST Joe Stewart <joe...@us...> [B] - comment.php3 - we don't use the old session name, etc. |
From: Joe S. <joe...@us...> - 2002-12-13 17:42:38
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv5975/phpslash-ft Modified Files: CHANGES Log Message: session variable name is not needed Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.630 retrieving revision 1.631 diff -C2 -d -r1.630 -r1.631 *** CHANGES 11 Dec 2002 19:42:23 -0000 1.630 --- CHANGES 13 Dec 2002 17:42:05 -0000 1.631 *************** *** 13,16 **** --- 13,20 ---- 9 - Removal of something (kill -9 :) + 2002-December-13 11:00AM CST Joe Stewart <joe...@us...> + [B] - comment.php3 - we don't use the old session name, etc. + config.php3 - removed duplicate call to timezone engine. + 2002-December-11 2:00PM EST Matthew Leingang <sym...@us...> [F] - Added class/lib.resources.php |
From: Joe S. <joe...@us...> - 2002-12-13 17:34:48
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv3900/phpslash-ft/public_html Modified Files: config.php3 comment.php3 Log Message: session variable name is not needed Index: config.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config.php3,v retrieving revision 1.171 retrieving revision 1.172 diff -C2 -d -r1.171 -r1.172 *** config.php3 11 Dec 2002 23:03:17 -0000 1.171 --- config.php3 13 Dec 2002 17:34:25 -0000 1.172 *************** *** 348,396 **** /** - * Time zone - **/ - if ($_PSL['timezone']['engine']) { - loadLibrary("tz"); - // set up the time zone environment array - $_TZ =& $_PSL['timezone']; - $_TZ['templatedir'] = $_PSL['templatedir']; - $_TZ['show_format'] = psl_getLocalInfo('LC_TIME','%a %b %e %H:%M:%S %Z %Y'); - /* $_TZ['available'] = array("America/New_York", - "America/Chicago", - "America/Denver", - "America/Los_Angeles", - "Pacific/Honolulu"); - */ - // to enable setting of time zone in URL - set_TZ($HTTP_GET_VARS['TZ'],'cookie'); - // to disable setting in URL and to set $_PSL['timezone']['name'] as the time zone - // set_TZ(); - } - - /* ============= Things to deprecate ============= */ - - // ---------------------------------------------------------- - // Ref'ed in Block_i - // $templatedir = $_PSL['templatedir']; - - // ---------------------------------------------------------- - // The following can be deleted - // ---------------------------------------------------------- - // if ($sitename=="") $sitename = $_PSL['site_name']; - // if ($siteowner=="") $siteowner = $_PSL['site_owner']; - // $rootdir = $_PSL['rooturl']; - // $debug = $_PSL['debug']; - // $debug_type = $_PSL['debug_type']; - // $infolog_enable = $_PSL['use_infolog']; - // $default_pending = $_PSL['default_pending']; - // $show_admin_on_navbar = $_PSL['show_admin_on_navbar']; - // $max_poll_answers = $_PSL['poll_max_answers']; - // $admindir = $_PSL['adminurl']; - // $imagedir = $_PSL['imageurl']; - // $classdir = $_PSL['classdir']; - // $basedir = $_PSL['basedir']; - // ---------------------------------------------------------- - - /** * $ary is used by story::getStory and block_i::getBlocks * this block just merges in the default section --- 348,351 ---- *************** *** 701,705 **** 'name' => "Add Story", 'link' => $_PSL['rooturl'] . "/submission.php3", ! 'perm' => "submissionNew", 'module' => "Submission" ); --- 656,660 ---- 'name' => "Add Story", 'link' => $_PSL['rooturl'] . "/submission.php3", ! 'perm' => "nobody", 'module' => "Submission" ); *************** *** 883,886 **** --- 838,844 ---- $_PSL['expirerelated'] = 14400; + /** + * Time zone + **/ if ($_PSL['timezone']['engine']) { loadLibrary("tz"); *************** *** 900,903 **** --- 858,870 ---- // set_TZ(); } + + /* ============= Things to deprecate ============= */ + + // ---------------------------------------------------------- + + // ---------------------------------------------------------- + // The following can be deleted + // ---------------------------------------------------------- + // ---------------------------------------------------------- ?> Index: comment.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/comment.php3,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** comment.php3 11 Dec 2002 21:25:54 -0000 1.24 --- comment.php3 13 Dec 2002 17:34:33 -0000 1.25 *************** *** 118,130 **** // session variables ! if(isset($name)) { ! $ary['name'] = $name; ! } ! if(isset($email)) { ! $ary['email'] = $email; ! } ! if(isset($url)) { ! $ary['url'] = $url; ! } // either start a new object or getForm not reuse template vars. --- 118,130 ---- // session variables ! // if(isset($name)) { ! // $ary['name'] = $name; ! // } ! // if(isset($email)) { ! // $ary['email'] = $email; ! // } ! // if(isset($url)) { ! // $ary['url'] = $url; ! // } // either start a new object or getForm not reuse template vars. |
From: Matthew L. <sym...@us...> - 2002-12-12 14:43:49
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv7256 Modified Files: config-dist.ini.php3 Log Message: new debug directives: debug.mailto, debug.max_recursion_level, debug.escape_html Index: config-dist.ini.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config-dist.ini.php3,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** config-dist.ini.php3 28 Oct 2002 16:13:54 -0000 1.8 --- config-dist.ini.php3 12 Dec 2002 14:43:46 -0000 1.9 *************** *** 156,167 **** ;;; ! ;; Debug Options ! ! ; true for on, false for off debug = false ! ! ; 'now' for output to browser, 'log' for output to the admin log debug_type = now ;;; end of Debug Options ;; Informational Logging --- 156,178 ---- ;;; ! ;; Debug options ! ; true for on, false for off debug = false ! ; Debug type: ! ; 'now' for output to the browser ! ; 'log' for output to the admin log ! ; 'mail' to e-mail output debug_type = now + ; Mail debug output to (e.g., "web...@ph..."); + ; CAUTION: Generates one message per debug call, not per page. + debug.mailto = '' + ; Recurse through data structures down this far. + ; Use -1 if you are not afraid of circular references, or + ; 1 for previous behavior + debug.max_recursion_level = 10 + ; Escape html in debug output + debug.escape_html = true ;;; end of Debug Options + ;; Informational Logging |
From: Matthew L. <sym...@us...> - 2002-12-12 13:53:53
|
Update of /cvsroot/phpslash/phpslash-ft/class In directory sc8-pr-cvs1:/tmp/cvs-serv13964 Modified Files: lib.resources.php Log Message: phpDocumentor DocBlock tweaks Index: lib.resources.php =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/lib.resources.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** lib.resources.php 11 Dec 2002 19:39:15 -0000 1.1 --- lib.resources.php 12 Dec 2002 13:53:50 -0000 1.2 *************** *** 14,18 **** * classes with their own via the AddClassReplacement function. * ! * @author sympleko (lei...@ma...) * * $Id$ --- 14,20 ---- * classes with their own via the AddClassReplacement function. * ! * @author Matthew Leingang <sym...@us...> ! * @package phpslash ! * @subpackage resources * * $Id$ *************** *** 20,29 **** /** ! * Instantiate a new object. * ! * Internally calls loadClass to make sure the object is ready to be * constructed (I.e., that the class file has been loaded). * ! * By calling addClassReplacement($class,$whatever) you can replace this * class with a derived or compatible one. * --- 22,31 ---- /** ! * Instantiate a new object * ! * Internally calls {@link loadClass} to make sure the object is ready to be * constructed (I.e., that the class file has been loaded). * ! * By calling {@link addClassReplacement} you can replace this * class with a derived or compatible one. * *************** *** 31,41 **** * on as authors. * @link http://savannah.gnu.org/cgi-bin/viewcvs/phpgroupware/phpgwapi/inc/common_functions.inc.php?rev=1.13&content-type=text/vnd.viewcvs-markup - * * @author mdean * @author milosch * @author (thanks to jengo and ralf) ! * @syntax CreateObject('class', 'constructor_params'); * @param string name of class ! * @param string class parameters (all optional) **/ function pslNew($class, --- 33,45 ---- * on as authors. * @link http://savannah.gnu.org/cgi-bin/viewcvs/phpgroupware/phpgwapi/inc/common_functions.inc.php?rev=1.13&content-type=text/vnd.viewcvs-markup * @author mdean * @author milosch * @author (thanks to jengo and ralf) ! * @syntax CreateObject('class', 'constructor_params'); <-- unsupported by phpDoc * @param string name of class ! * @param string class constructor parameters (all optional) ! * @access public ! * @see loadClass ! * @see addClassReplacement **/ function pslNew($class, *************** *** 93,102 **** /** ! * loads the files necessary to make a successful instantiation of a class * * @access public * @param string class * @return bool success ! */ function loadClass($class) { $fn = "loadClass"; --- 97,110 ---- /** ! * Load the files necessary to guarantee successful instantiation of $class ! * ! * The class $class must have been previously registered by one or more ! * {@link addClassRequirement} calls. * * @access public * @param string class * @return bool success ! * @see addClassRequirement ! **/ function loadClass($class) { $fn = "loadClass"; *************** *** 108,117 **** /** ! * loads a library that has been registered in the resources area * * @access public * @param string library name ! * @return bool success ! */ function loadLibrary($lib) { return load_resource(libUrn($lib)); --- 116,129 ---- /** ! * Load the library $lib ! * ! * The library $lib must have been previously registered by one or more ! * {@link addLibraryRequirement} calls. * * @access public * @param string library name ! * @return bool success ! * @see addLibraryRequirement ! **/ function loadLibrary($lib) { return load_resource(libUrn($lib)); *************** *** 119,128 **** /** ! * returns the class specified, which may have been overridden by ! * configuration * * @access public * @param string class name ! * @return string overidden class name, or original */ function pslGetClass($class) { --- 131,141 ---- /** ! * Return the class specified, which may have been overridden by ! * user configuration * * @access public * @param string class name ! * @return string overidden class name, or original if no override exists ! * @see addClassReplacement */ function pslGetClass($class) { *************** *** 144,157 **** /** ! * add a class requirement * ! * loadClass will make sure the required class or library is loaded before this ! * Resources will be loaded in the order they are specified, so take care. * * @access public * @param string class, URN, or URI * @param string required class ! * @return true ! */ function addClassRequirement($class,$reqClass) { // debug("addClassRequirement($class, $reqClass)","begin"); --- 157,176 ---- /** ! * Add a class requirement * ! * {@link loadClass} will make sure the required class or library is ! * loaded before this. CAUTION: Resources will be loaded in the order ! * they are specified. GIGO. * + * $reqClass can be a URN (such as urn:class:foo) , or a file + * (/path/to/class/foo.php). If neither, $reqClass is assumed to be the + * name of another class. + * * @access public * @param string class, URN, or URI * @param string required class ! * @return bool true ! * @see addLibraryRequirment ! **/ function addClassRequirement($class,$reqClass) { // debug("addClassRequirement($class, $reqClass)","begin"); *************** *** 177,187 **** * add a library requirement * ! * "Library" is just a collection of one or more php files which are expected ! * to have function definitions and other non-output-producing code in them. * * @access public * @param string library name ! * @param requirement libarary, URI, or URN ! */ function addLibraryRequirement($lib,$reqLib) { // debug("addClassRequirement($lib, $reqLib)","begin"); --- 196,208 ---- * add a library requirement * ! * $reqLib can be a URN (such as urn:class:foo) , or a file ! * (/path/to/class/foo.php). If neither, $reqLib is assumed to be the ! * name of another library. * * @access public * @param string library name ! * @param requirement library, file, URI, or URN ! * @see addClassRequirement ! **/ function addLibraryRequirement($lib,$reqLib) { // debug("addClassRequirement($lib, $reqLib)","begin"); *************** *** 205,216 **** /** ! * add a class replacement * ! * pslGetClass will return this class instead of the standard one * * @access public * @param string class * @param string replacement class ! * @return true */ function addClassReplacement($class,$repClass) { --- 226,237 ---- /** ! * Add a class replacement * ! * {@link pslGetClass} will return $repClass any time $class is asked for * * @access public * @param string class * @param string replacement class ! * @see pslGetClass */ function addClassReplacement($class,$repClass) { *************** *** 234,243 **** /** ! * return the resources required for successful loading of this one * ! * @access private * @param string URN * @return array required resources, or false if URN is not valid. ! */ function resource_requirements($urn) { return resource_data($urn,"requires"); --- 255,265 ---- /** ! * Get the resources required for successful loading of $urn * ! * @access public * @param string URN * @return array required resources, or false if URN is not valid. ! * @see add_resource_requirement ! **/ function resource_requirements($urn) { return resource_data($urn,"requires"); *************** *** 245,254 **** /** ! * returns the resource specified to replace this one through customization * * @access private * @param string URN * @return string replacement URN ! */ function resource_replacement($urn) { return resource_data($urn,"isReplacedBy"); --- 267,277 ---- /** ! * Returns the resource specified to replace $urn, if any * * @access private * @param string URN * @return string replacement URN ! * @see add_resource_replacement ! **/ function resource_replacement($urn) { return resource_data($urn,"isReplacedBy"); *************** *** 256,266 **** /** ! * add a requirement to the specified resources * ! * @access private * @param string URN * @param string required URN ! * @return true ! */ function add_resource_requirement($urn,$reqUrn) { // debug("add_resource_requirement($urn,$reqUrn)","begin"); --- 279,290 ---- /** ! * Add a requirement to the specified URN. * ! * @access public * @param string URN * @param string required URN ! * @see resource_requirement ! * @see load_resource ! **/ function add_resource_requirement($urn,$reqUrn) { // debug("add_resource_requirement($urn,$reqUrn)","begin"); *************** *** 269,278 **** /** ! * add a replacement to the specified resources * * @param string URN * @param string replacement URN ! * @return true ! */ function add_resource_replacement($urn,$repUrn) { return add_resource_data_single($urn,"isReplacedBy",$repUrn); --- 293,303 ---- /** ! * Add a user replacement to $urn. * + * @access public * @param string URN * @param string replacement URN ! * @see resource_replacement ! **/ function add_resource_replacement($urn,$repUrn) { return add_resource_data_single($urn,"isReplacedBy",$repUrn); *************** *** 280,288 **** /** ! * loads a resource (URN) and all resources it requires * ! * @access private * @param string urn * @return success **/ function load_resource($urn) { --- 305,314 ---- /** ! * Load the resource named by $urn and all resources it requires * ! * @access public * @param string urn * @return success + * @see add_resource_requirement **/ function load_resource($urn) { *************** *** 327,335 **** /** ! * parse a URN into NID and NSS * ! * URNs look like "urn:<NID>:<NSS>". <NID> (Namespace Identifier) can * have letters, numbers, or hyphens, but can't start with a hyphen. ! * <NSS> (Namespace Specific String) can have letters, numbers, any of * the punctuation marks "()+,-.:=@;$_!*'", or any other character * encoded by a hex byte "%xx". --- 353,361 ---- /** ! * Parse $urn into NID and NSS * ! * URNs look like "urn:<NID>:<NSS>". <NID> (Namespace Identifier) can * have letters, numbers, or hyphens, but can't start with a hyphen. ! * <NSS> (Namespace Specific String) can have letters, numbers, any of * the punctuation marks "()+,-.:=@;$_!*'", or any other character * encoded by a hex byte "%xx". *************** *** 354,361 **** /** ! * check if string is a well-formed URN * * @param string prospective URN * @return bool success */ function is_urn($string) { --- 380,389 ---- /** ! * Check if $string is a well-formed URN * + * @access public * @param string prospective URN * @return bool success + * @see parse_urn */ function is_urn($string) { *************** *** 365,376 **** /** * URN/RDF low-level functions ! */ /** ! * check if information is known about a URN * ! * @access private * @param string URN ! * @return bool if valid */ function is_valid_urn($urn) { --- 393,407 ---- /** * URN/RDF low-level functions ! * ! * No mention of where or how the resource data is stored until this ! * point. ! **/ /** ! * check if information is known about $urn * ! * @access public * @param string URN ! * @return bool validity */ function is_valid_urn($urn) { *************** *** 379,384 **** /** ! * return specific RDF tag about a resource * * @param string URN * @param string key (tagname) --- 410,418 ---- /** ! * Return specific RDF tag about a resource * + * Currently used tags are "requires" and "isReplacedBy." + * + * @access private * @param string URN * @param string key (tagname) *************** *** 394,397 **** --- 428,440 ---- } + /** + * Add information to the resource record + * + * @access private + * @param string URN + * @param string tagname + * @param string value + * @see add_resource_data_multiple + */ function add_resource_data_single($urn,$key,$value) { $GLOBALS['_PSL']['resources'][$urn][$key] = $value; *************** *** 399,402 **** --- 442,455 ---- } + /** + * Add information to the resource record, for tags which can have more + * than one value. + * + * @access private + * @param string URN + * @param string tagname + * @param string value + * @see add_resource_data_single + **/ function add_resource_data_multiple($urn,$key,$value) { // debug("add_resource_data_multiple($urn, $key, $value)","begin"); |
From: Matthew L. <sym...@us...> - 2002-12-11 23:03:51
|
Update of /cvsroot/phpslash/phpslash-ft/class In directory sc8-pr-cvs1:/tmp/cvs-serv6548/class Modified Files: functions.inc Log Message: Debug now recurses to any desired depth, including infinity. Debug can e-mail output rather than output to browser. New configuration directives: debug.max_recursion_level, debug.escape_html, debug.mailto Index: functions.inc =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/functions.inc,v retrieving revision 1.117 retrieving revision 1.118 diff -C2 -d -r1.117 -r1.118 *** functions.inc 11 Dec 2002 19:39:55 -0000 1.117 --- functions.inc 11 Dec 2002 23:03:15 -0000 1.118 *************** *** 305,346 **** } ! /*************************************************************************** ! function : debug ! Parameters : $name => The name of the variable or function you're debugging ! $msg => The debug message ! $type => Type of message ! "now" for immediate output ! "log" for sending it to the logging function ! ****************************************************************************/ ! function debug($name, $msg, $type='default') { ! global $_PSL; ! ! if ($_PSL['debug']) { ! // the $debug_type is set in config.php3 ! if ($type == 'default') { ! $type = $_PSL['debug_type']; } ! // First handle arrays that need to get output now ! if (is_array($msg) && $type == 'now') { ! debug_array($name, $msg); ! ! // Now, output anything that should by output now ! } elseif ($type == 'now' ) { ! echo "<small> Debug: $name: $msg </small><br>\n"; ! ! // Send to log if needed be. ! } elseif ($type == 'log') { ! $desc = "Debug: $name"; ! logwrite($desc, $msg); } } } ! /****************************************************************************** ! function : debug_array ! Parameters : title of array, and the actual array ! *******************************************************************************/ function debug_array($name, $ary) { --- 305,449 ---- } ! /** ! * return a string detailing structure of $var ! * ! * @author Matthew Leingang (sym...@us...) ! * @require output buffering (built into PHP4) ! * @see print_r ! * @param mixed ! * @return string ! */ ! function get_r($var) { ! ob_start(); ! print_r($var); ! $ans = ob_get_contents(); ! ob_end_clean(); ! return $ans; ! } ! /** ! * Generate diagnostic information or messages ! * ! * @access public ! * @author Matthew Leingang (sym...@us...) ! * @param string name of the variable or function you're debugging ! * @param mixed message or variable to be debugged ! * @param destination of message: ! * 'now' - output immediately ! * 'log' - log in db ! * 'mail' - mail to whomever ! * other - return as string ! * (optional; default - specified in config file) ! * @param int maximum recursion level ! * (applies only to 'now' debugs') ! * (-1 for no limit to recursion depth) ! * (optional; default - specified in config file) ! * @global bool $_PSL['debug'] debug if true ! * @global bool $_PSL['debug_type'] default destination of output ! * @global bool $_PSL['debug.mailto'] recipient of debug e-mail if sent ! * @global bool $_PSL['debug.max_recursion_level'] maximum level of recurstion ! * @global bool $_PSL['debug.escape_html'] if true, escape HTML in output ! * @return string debug output string, or '' if debug is shut off ! **/ ! function debug($name, $msg, $type='default',$max_level=NULL) { ! GLOBAL $_PSL; ! if (!$_PSL['debug']) { ! return ''; ! } ! if (is_int($type)) { ! // max level specified but no type ! return debug($name,$msg,'default',$type); ! } ! if (is_null($max_level)) { ! $max_level = $_PSL['debug.max_recursion_level']; ! } ! if ('default' == $type) { ! $type = $_PSL['debug_type']; ! } ! $escapeHtmlFlag = $_PSL['debug.escape_html']; ! $ans = debug_iterator($name,$msg,$type,$max_level,$escapeHtmlFlag); ! switch($type) { ! case 'log': ! logwrite($name,get_r($msg)); ! $ans = true; ! break; ! case 'now': ! echo $ans; ! break; ! case 'mail': ! if ($_PSL['debug.mailto']) { ! mail($_PSL['debug.mailto'], ! "PHPSlash Debug Output", ! $ans, ! "X-Generator: " . $_PSL['phpself']); } + break; + } + return $ans; + } ! /** ! * Traverse a data structure, dumping into nice HTML ! * ! * @author Matthew Leingang (sym...@us...) ! * @access private ! * @see debug ! * @param string message or variable name ! * @param mixed variable to diagnose ! * @param string destination of message: ! * @param int maximum recursion level ! * @param int current level of recursion ! * @param bool escape HTML output ! * @return string debug output string ! * '' if _PSL['debug'] is off, or recursion level is exceeded ! **/ ! function debug_iterator($msg,$var,$type,$max_level=NULL,$level=0,$escapeHtmlFlag=true) { ! GLOBAL $_PSL; ! $str = ''; ! $brnl = "<br>\n"; ! if (!($level <= $max_level) || !$_PSL['debug']) { ! return ''; ! } ! if (is_null($max_level)) { ! $max_level = $_PSL['debug.max_recursion_level']; ! } ! if ($escapeHtmlFlag) { ! $msg = htmlentities($msg); ! } ! switch(true) { ! case is_array($var): ! $str .= sprintf("<small><b>Debug: %s</b>: Array</small>" . $brnl, ! $msg); ! foreach($var as $key => $val) { ! $str .= debug_iterator($msg . '[' . $key . ']', ! $val, $type, $max_level,$level+1); ! } ! break; ! case is_object($var): ! $str .= sprintf("<small><b>Debug: %s</b>: Object of class <i>%s</i></small>" . $brnl, ! $msg,get_class($var)); ! foreach(get_object_vars($var) as $key => $val) { ! $str .= debug_iterator($msg . '->' . $key, ! $val, $type, $max_level,$level+1); } + break; + default: + if ($escapeHtmlFlag) { + $var = htmlentities($var); + } + $str .= sprintf("<small>Debug: %s: %s</small>" . $brnl,$msg,$var); } + return $str; } ! /** ! * dump contents of array into HTML ! * ! * @access private ! * @deprec debug now calls debug_iterator instead ! * @param string title of array ! * @param array array to debug ! * @return void ! **/ function debug_array($name, $ary) { |
From: Matthew L. <sym...@us...> - 2002-12-11 23:03:23
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv6548/public_html Modified Files: config.php3 Log Message: Debug now recurses to any desired depth, including infinity. Debug can e-mail output rather than output to browser. New configuration directives: debug.max_recursion_level, debug.escape_html, debug.mailto Index: config.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config.php3,v retrieving revision 1.170 retrieving revision 1.171 diff -C2 -d -r1.170 -r1.171 *** config.php3 11 Dec 2002 21:25:54 -0000 1.170 --- config.php3 11 Dec 2002 23:03:17 -0000 1.171 *************** *** 62,69 **** $_PSL['version'] = '0.6.5'; ! /**** START DEBUGING - Comment or delete this for production! ****/ //ini_set('error_reporting', 'E_ALL'); //ini_set('error_reporting', 'E_ALL~E_NOTICE'); ! /**** END DEBUGING ****/ ////////////////////////////////////////////////////////////////////////// --- 62,69 ---- $_PSL['version'] = '0.6.5'; ! /**** START DEBUGGING - Comment or delete this for production! ****/ //ini_set('error_reporting', 'E_ALL'); //ini_set('error_reporting', 'E_ALL~E_NOTICE'); ! /**** END DEBUGGING ****/ ////////////////////////////////////////////////////////////////////////// *************** *** 128,135 **** ! // 1.11.2) Debug options ! $_PSL['debug'] = false; // true for on, false for off ! $_PSL['debug_type'] = 'now'; // 'now' for output to browser ! // 'log' for output to the admin log /** --- 128,147 ---- ! // ;; 1.11.2) Debug options ! // ;; true for on, false for off ! $_PSL['debug'] = false; ! // ;; Debug type: ! // ;; 'now' for output to the browser ! // ;; 'log' for output to the admin log ! // ;; 'mail' to e-mail output ! $_PSL['debug_type'] = 'now'; ! // ;; Mail debug output to (e.g., "web...@ph..."); ! // ;; CAUTION: Generates one message per debug call, not per page. ! $_PSL['debug.mailto'] = ''; ! // ;; Recurse through data structures down this far ! // ;; (use -1 if you are not afraid of circular references) ! $_PSL['debug.max_recursion_level'] = 10; ! // ;; Escape html in debug output ! $_PSL['debug.escape_html'] = true; /** |
From: Matthew L. <sym...@us...> - 2002-12-11 21:25:57
|
Update of /cvsroot/phpslash/phpslash-ft/public_html In directory sc8-pr-cvs1:/tmp/cvs-serv32314 Modified Files: about.php3 article.php3 backend.php3 comment.php3 config.php3 errordocument.php3 glossary.php3 index.php3 login.php3 mailinglist.php3 poll.php3 profile.php3 search.php3 submission.php3 test.php3 Log Message: All new's changed to pslNew's. config.php3 is undergoing some reorganization to separate out those commands which will eventually only need to be run once per session. Index: about.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/about.php3,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** about.php3 22 Nov 2002 18:43:47 -0000 1.19 --- about.php3 11 Dec 2002 21:25:54 -0000 1.20 *************** *** 13,17 **** // Objects ! $block = new Block_i; // Start of Page --- 13,17 ---- // Objects ! $block = pslNew("Block_i"); // Start of Page *************** *** 21,25 **** slashhead($pagetitle,$_PSL['metatags']); ! $about_templ = new Template($_PSL['templatedir']); $about_templ->set_file(array( 'main' => "about.tpl" --- 21,25 ---- slashhead($pagetitle,$_PSL['metatags']); ! $about_templ = pslNew("Template",$_PSL['templatedir']); $about_templ->set_file(array( 'main' => "about.tpl" *************** *** 47,51 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 47,51 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: article.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/article.php3,v retrieving revision 1.71 retrieving revision 1.72 diff -C2 -d -r1.71 -r1.72 *** article.php3 22 Nov 2002 18:43:47 -0000 1.71 --- article.php3 11 Dec 2002 21:25:54 -0000 1.72 *************** *** 12,17 **** *************************************/ ! $db = new slashDB; ! $story = new Story; $return_link = $HTTP_SERVER_VARS["REQUEST_URI"]; --- 12,17 ---- *************************************/ ! $db = pslNew("slashDB"); ! $story = pslNew("Story"); $return_link = $HTTP_SERVER_VARS["REQUEST_URI"]; *************** *** 24,28 **** $story_html = $story->getStory($story_id, "full", $ary); ! $t = new Template($_PSL['templatedir'], "remove"); if ($story_html) { --- 24,28 ---- $story_html = $story->getStory($story_id, "full", $ary); ! $t = pslNew("Template",$_PSL['templatedir'], "remove"); if ($story_html) { *************** *** 113,117 **** $arrows = $story->getNextPrev($story_id); ! $block = new Block_i; $leftblocks = $block->getBlocks($ary, "left" ); $centerblocks = $block->getBlocks($ary, "center" ); --- 113,117 ---- $arrows = $story->getNextPrev($story_id); ! $block = pslNew("Block_i"); $leftblocks = $block->getBlocks($ary, "left" ); $centerblocks = $block->getBlocks($ary, "center" ); *************** *** 149,153 **** $cmtary['story_id'] = $ary['story_id']; $cmtary['parent_id'] = $ary['parent_id']; ! $cmt = new Comment($cmtary); $comments = $cmt->getAllComments($cmtary); } else { --- 149,153 ---- $cmtary['story_id'] = $ary['story_id']; $cmtary['parent_id'] = $ary['parent_id']; ! $cmt = pslNew("Comment",$cmtary); $comments = $cmt->getAllComments($cmtary); } else { *************** *** 188,191 **** --- 188,194 ---- slashhead($ttitle,$_PSL['metatags']); + + debug('HTTP_COOKIE_VARS',$HTTP_COOKIE_VARS); + $t->parse('PAGE', 'article'); $t->p('PAGE'); Index: backend.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/backend.php3,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** backend.php3 11 Nov 2002 21:22:58 -0000 1.33 --- backend.php3 11 Dec 2002 21:25:54 -0000 1.34 *************** *** 54,58 **** // Object Creation ! $story = new Story; // Parse cmd line variables into array --- 54,58 ---- // Object Creation ! $story = pslNew("Story"); // Parse cmd line variables into array *************** *** 125,129 **** // Create the template object, and set some options for silent running ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_unknowns('remove'); --- 125,129 ---- // Create the template object, and set some options for silent running ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_unknowns('remove'); Index: comment.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/comment.php3,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** comment.php3 4 Dec 2002 20:27:41 -0000 1.23 --- comment.php3 11 Dec 2002 21:25:54 -0000 1.24 *************** *** 34,38 **** } ! $cmt = new Comment($ary); switch( $submit) { --- 34,38 ---- } ! $cmt = pslNew("Comment",$ary); switch( $submit) { *************** *** 88,92 **** } ! $cmt = new Comment($ary); switch( $submit) { --- 88,92 ---- } ! $cmt = pslNew("Comment",$ary); switch( $submit) { *************** *** 102,106 **** $ary['replying_to'] = $cmt->formatComment($parent_ary); } else { ! $story = new Story; $ary['replying_to'] = $story->getStory($ary[story_id],"full"); } --- 102,106 ---- $ary['replying_to'] = $cmt->formatComment($parent_ary); } else { ! $story = pslNew("Story"); $ary['replying_to'] = $story->getStory($ary[story_id],"full"); } *************** *** 129,133 **** // either start a new object or getForm not reuse template vars. ! $cmt = new Comment($ary); $content .= $cmt->getForm($ary); --- 129,133 ---- // either start a new object or getForm not reuse template vars. ! $cmt = pslNew("Comment",$ary); $content .= $cmt->getForm($ary); *************** *** 163,167 **** } ! $block = new Block_i; $breadcrumb = breadcrumb($ary); --- 163,167 ---- } ! $block = pslNew("Block_i"); $breadcrumb = breadcrumb($ary); *************** *** 188,192 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 188,192 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: config.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/config.php3,v retrieving revision 1.169 retrieving revision 1.170 diff -C2 -d -r1.169 -r1.170 *** config.php3 3 Dec 2002 20:27:35 -0000 1.169 --- config.php3 11 Dec 2002 21:25:54 -0000 1.170 *************** *** 60,65 **** } - - $_PSL['version'] = '0.6.5'; --- 60,63 ---- *************** *** 73,79 **** ////////////////////////////////////////////////////////////////////////// ! // 1.1 Uncomment this only if you can't use a local php.ini or .htaccess ! require('/home/nathan/webDevel/php-lib-stable/php/prepend.php3'); // 1.11) Global Variables. (Don't add trailing slashes) --- 71,77 ---- ////////////////////////////////////////////////////////////////////////// ! // 1.1 Set this because PHPLIB's prepend is not going to be used. ! $_PHPLIB['libdir'] = '/home/leingang/src/phplib-7.4-pre1/php/'; // 1.11) Global Variables. (Don't add trailing slashes) *************** *** 95,99 **** // $basedir -> Complete filesystem path to the pages ! $_PSL['basedir'] = '/home/nathan/webDevel/phpslash-ft/public_html'; // $templatedir -> Path to the templates directory --- 93,97 ---- // $basedir -> Complete filesystem path to the pages ! $_PSL['basedir'] = '/home/leingang/src/phpslash-ft-test/public_html'; // $templatedir -> Path to the templates directory *************** *** 101,108 **** // $classdir -> Path to the class directory ! $_PSL['classdir'] = '/home/nathan/webDevel/phpslash-ft/class'; // $rooturl -> The base URL for the phpslash site ! $_PSL['rooturl'] = 'http://fatboy.mystic/nate/phpslash-ft/public_html'; // $adminurl -> The base URL for the admin pages --- 99,106 ---- // $classdir -> Path to the class directory ! $_PSL['classdir'] = '/home/leingang/src/phpslash-ft-test/class'; // $rooturl -> The base URL for the phpslash site ! $_PSL['rooturl'] = 'http://marlowe.rutgers.edu/phpslash-test'; // $adminurl -> The base URL for the admin pages *************** *** 118,126 **** $_PSL['topicimagedir'] = $_PSL['basedir'] . "/images" . "/topics"; $_PSL['DB_Host'] = "localhost"; ! $_PSL['DB_Database'] = "psl"; ! $_PSL['DB_User'] = "psl"; ! $_PSL['DB_Password'] = "foo"; // begin built-in jpcache --- 116,194 ---- $_PSL['topicimagedir'] = $_PSL['basedir'] . "/images" . "/topics"; + // 1.3) PHPSlash functions library + require_once($_PSL['classdir'] . '/functions.inc'); + require_once($_PSL['classdir'] . '/lib.resources.php'); + + // 1.11.4) Other Variables... $_PSL['DB_Host'] = "localhost"; ! $_PSL['DB_Database'] = "phpslash"; ! $_PSL['DB_User'] = "phpslash"; ! $_PSL['DB_Password'] = "phpslash"; ! ! ! // 1.11.2) Debug options ! $_PSL['debug'] = false; // true for on, false for off ! $_PSL['debug_type'] = 'now'; // 'now' for output to browser ! // 'log' for output to the admin log ! ! /** ! * Class information. Add any class replacements like this: ! * ! * AddClassReplacement("template","myTemplate"); ! * ! * This will make PHPSlash use your class instead of its defaults. ! * ! * First we load the PHPLIB basic classes. This next block of code does ! * the work of $_PHPLIB['libdir'] . 'prepend.php3', so make sure that ! * file's not processed automatically. ! **/ ! foreach(array("db_mysql","ct_sql","session","auth","perm","template") ! as $class) { ! addClassRequirement($class,$_PHPLIB['libdir'] ."$class.inc"); ! addLibraryRequirement("phplib",classURN($class)); ! } ! addLibraryRequirement("phplib",$_PHPLIB['libdir'] . "page.inc"); ! loadLibrary("phplib"); ! ! /** ! * These classes are PHPSlash's extensions to the PHPLIB base classes. ! * We only configure the ones which are required to get the page open ! * and restore session data. ! * ! * Note: author IS needed now because slashAuth uses it to fill in perms ! **/ ! addClassRequirement("slash_sql","ct_sql"); ! addClassRequirement("slash_sql",$_PSL['classdir'] . "/slash_sql.class"); ! addClassRequirement("slashDB","db_mysql"); ! addClassRequirement("slashDB",$_PSL['classdir'] . "/slashDB.class"); ! addClassRequirement("slashSess","session"); ! addClassRequirement("slashSess",$_PSL['classdir'] . "/slashSess.class"); ! addClassRequirement("slashAuth",$_PSL['classdir'] . "/slashAuthCR.class"); ! addClassRequirement("slashPerm","perm"); ! addClassRequirement("slashPerm",$_PSL['classdir'] . "/slashPerm.class"); ! addClassRequirement("author",$_PSL['classdir'] . "/Author.class"); ! addLibraryRequirement("phpslash",$_PSL['classdir'] . "/functions.inc"); ! ! /** ! * Register like above any classes instantiations of which you intend to ! * use for session variables. ! * ! * For example, say you want to sessionize the time zone: ! **/ ! //AddClassRequirement("tz",$_PSL['classdir'] . "/tz.class"); ! //AddLibraryRequirement("tz",$_PSL['classdir'] . "/tz_functions.inc"); ! //AddClassRequirement("tz_env","tz"); ! //AddClassRequirement("tz_env",$_PSL['classdir'] . "/tz_env.class"); ! //AddClassRequirement("tz_nonnative","tz"); ! //AddClassRequirement("tz_nonnative",$_PSL['classdir'] . "/tz_nonnative.class"); ! //AddClassRequirement("tz_posix","tz_nonnative"); ! //AddClassRequirement("tz_posix",$_PSL['classdir'] . "/tz_posix.class"); ! //AddClassRequirement("tz_file","tz_nonnative"); ! //AddClassRequirement("tz_file",$_PSL['classdir'] . "/tz_file.class"); ! /** ! * this necessity will change when the entire resource hash becomes ! * sessionized. ! */ // begin built-in jpcache *************** *** 143,147 **** $JPCACHE_DEBUG = 0; // Turn debugging on/off $JPCACHE_IGNORE_DOMAIN= 1; // Ignore domain name in request(single site) ! $JPCACHE_ON = 1; // Turn caching on/off $JPCACHE_USE_GZIP = 0; // Whether or not to use GZIP $JPCACHE_POST = 1; // Should POST's be cached --- 211,215 ---- $JPCACHE_DEBUG = 0; // Turn debugging on/off $JPCACHE_IGNORE_DOMAIN= 1; // Ignore domain name in request(single site) ! $JPCACHE_ON = 0; // Turn caching on/off $JPCACHE_USE_GZIP = 0; // Whether or not to use GZIP $JPCACHE_POST = 1; // Should POST's be cached *************** *** 174,181 **** // Standard jpcache functions ! require $_PSL['jpcachedir']. "/jpcache-main.php"; ! // Type specific jpcache implementations ! require $_PSL['jpcachedir'] ."/type/$JPCACHE_TYPE.php"; // end of jpcache configuration --- 242,255 ---- // Standard jpcache functions ! // require $_PSL['jpcachedir']. "/jpcache-main.php"; ! addLibraryRequirement("jpcache",$_PSL['jpcachedir'] . "/jpcache-main.php"); // Type specific jpcache implementations ! if ('phplib' == $JPCACHE_TYPE) { ! addClassRequirement("jpcacheDB","db_mysql"); ! addClassRequirement("jpcacheDB",$_PSL['jpcachedir'] ."/type/phplib.php"); ! } ! addLibraryRequirement("jpcache",$_PSL['jpcachedir'] ."/type/$JPCACHE_TYPE.php"); ! loadLibrary("jpcache"); ! // require $_PSL['jpcachedir'] ."/type/$JPCACHE_TYPE.php"; // end of jpcache configuration *************** *** 225,239 **** - // 1.11.2) Debug options - $_PSL['debug'] = false; // true for on, false for off - $_PSL['debug_type'] = 'now'; // 'now' for output to browser - // 'log' for output to the admin log - // 1.11.3) Informational Logging -> true for on, false for off $_PSL['use_infolog'] = true; // Use to turn on / off logging ! // 1.11.4) Other Variables... $_PSL['module']['Glossary'] = true; $_PSL['module']['MailingList'] = true; --- 299,490 ---- // 1.11.3) Informational Logging -> true for on, false for off $_PSL['use_infolog'] = true; // Use to turn on / off logging ! /** ! * Here we set various configuration variables based on the URL ! * ! * Language ! **/ ! // comment to enable setting lang in url ! $lang = false; ! ! $_PSL['localedir'] = $_PSL['classdir'] . "/locale"; // directory holding language files ! $_PSL['language'] = "en"; // default language ( ISO format) ! ! $_PSL['languagefile'] = $_PSL['localedir'] . "/" . $_PSL['language'] . ".php3"; ! ! // comment to disable auto lang detection ! $_PSL['languagefile'] = setLang($lang); ! ! // comment to disable auto tpl lang detection ! $_PSL['templatedir'] = setLangTpl($lang); ! ! ! /** ! * Skin (style of site) ! **/ ! // Sets the default skin for a site ! $_PSL['defaultskin'] = "basic"; // no css skin - "default" ! ! // comment out this block to disable setting theme in url ! if (!empty($HTTP_GET_VARS['skin'])) { ! $_PSL['templatedir'] = setSkinTpl($HTTP_GET_VARS['skin'], "cookie"); ! } else { ! $_PSL['templatedir'] = setSkinTpl("", "cookie"); ! } ! ! /** ! * Time zone ! **/ ! if ($_PSL['timezone']['engine']) { ! loadLibrary("tz"); ! // set up the time zone environment array ! $_TZ =& $_PSL['timezone']; ! $_TZ['templatedir'] = $_PSL['templatedir']; ! $_TZ['show_format'] = psl_getLocalInfo('LC_TIME','%a %b %e %H:%M:%S %Z %Y'); ! /* $_TZ['available'] = array("America/New_York", ! "America/Chicago", ! "America/Denver", ! "America/Los_Angeles", ! "Pacific/Honolulu"); ! */ ! // to enable setting of time zone in URL ! set_TZ($HTTP_GET_VARS['TZ'],'cookie'); ! // to disable setting in URL and to set $_PSL['timezone']['name'] as the time zone ! // set_TZ(); ! } + /* ============= Things to deprecate ============= */ + // ---------------------------------------------------------- + // Ref'ed in Block_i + // $templatedir = $_PSL['templatedir']; + + // ---------------------------------------------------------- + // The following can be deleted + // ---------------------------------------------------------- + // if ($sitename=="") $sitename = $_PSL['site_name']; + // if ($siteowner=="") $siteowner = $_PSL['site_owner']; + // $rootdir = $_PSL['rooturl']; + // $debug = $_PSL['debug']; + // $debug_type = $_PSL['debug_type']; + // $infolog_enable = $_PSL['use_infolog']; + // $default_pending = $_PSL['default_pending']; + // $show_admin_on_navbar = $_PSL['show_admin_on_navbar']; + // $max_poll_answers = $_PSL['poll_max_answers']; + // $admindir = $_PSL['adminurl']; + // $imagedir = $_PSL['imageurl']; + // $classdir = $_PSL['classdir']; + // $basedir = $_PSL['basedir']; + // ---------------------------------------------------------- + + /** + * $ary is used by story::getStory and block_i::getBlocks + * this block just merges in the default section + */ + $ary = array(); + if(!empty($HTTP_GET_VARS)) { + $ary = clean($HTTP_GET_VARS); + } + + if ((empty($ary['section'])) AND (empty($ary['section_id']))){ + $section_id = $_PSL['home_section_id']; + if(!$section_id) { + $section_id = "3"; + } + $ary['section_id'] = $section_id; + } + + $_PSL['amp'] = arg_separator("1"); + + /** + * page features, all derived from PHPLIB classes and user-customizable + **/ + if (empty($_PSL['page_features'])) { + foreach(array("sess"=>"slashSess", + "auth"=>"slashAuth", + "perm"=>"slashPerm") + as $name => $class) { + $class = pslGetClass($class); + loadClass($class); + $_PSL['page_features'][$name] = $class; + } + } + + page_open($_PSL['page_features']); + /** + * Now the session has started. What is below here will be moving into + * its own file to be called once per session. + **/ + + /** + * Rest of the class information + **/ + AddClassRequirement("block",$_PSL['classdir'] . "/Block.class"); + AddClassRequirement("block_i","block"); + AddClassRequirement("block_i",$_PSL['classdir'] . "/Block_i.class"); + AddClassRequirement("block_render_i",$_PSL['classdir'] . "/Block_render_i.class"); + AddClassRequirement("block_render_cal","block_render_i"); + AddClassRequirement("block_render_cal",$_PSL['classdir'] . "/Block_render_cal.class"); + AddClassRequirement("block_render_html","block_render_i"); + AddClassRequirement("block_render_html",$_PSL['classdir'] . "/Block_render_html.class"); + AddClassRequirement("block_render_login","block_render_i"); + AddClassRequirement("block_render_login",$_PSL['classdir'] . "/Block_render_login.class"); + AddClassRequirement("block_render_navbar","block_render_i"); + AddClassRequirement("block_render_navbar",$_PSL['classdir'] . "/Block_render_navbar.class"); + AddClassRequirement("block_render_poll","block_render_i"); + AddClassRequirement("block_render_poll",$_PSL['classdir'] . "/Block_render_poll.class"); + AddClassRequirement("block_render_query","block_render_i"); + AddClassRequirement("block_render_query",$_PSL['classdir'] . "/Block_render_query.class"); + AddClassRequirement("block_render_query","block_render_i"); + AddClassRequirement("block_render_quote",$_PSL['classdir'] . "/Block_render_quote.class"); + AddClassRequirement("block_render_section","block_render_i"); + AddClassRequirement("block_render_section",$_PSL['classdir'] . "/Block_render_section.class"); + AddClassRequirement("block_render_skin","block_render_i"); + AddClassRequirement("block_render_skin",$_PSL['classdir'] . "/Block_render_skin.class"); + AddClassRequirement("block_render_submission","block_render_i"); + AddClassRequirement("block_render_submission",$_PSL['classdir'] . "/Block_render_submission.class"); + AddClassRequirement("block_render_topic","block_render_i"); + AddClassRequirement("block_render_topic",$_PSL['classdir'] . "/Block_render_topic.class"); + AddClassRequirement("block_render_url","block_render_i"); + AddClassRequirement("block_render_url",$_PSL['classdir'] . "/Block_render_url.class"); + AddClassRequirement("block_admin","block_i"); + AddClassRequirement("block_admin",$_PSL['classdir'] . "/Block_admin.class"); + AddClassRequirement("comment",$_PSL['classdir'] . "/Comment.class"); + AddClassRequirement("glossary",$_PSL['classdir'] . "/Glossary.class"); + AddClassRequirement("group",$_PSL['classdir'] . "/Group.class"); + AddClassRequirement("infolog",$_PSL['classdir'] . "/Infolog.class"); + AddClassRequirement("mailinglist",$_PSL['classdir'] . "/MailingList.class"); + AddClassRequirement("navbar",$_PSL['classdir'] . "/NavBar.class"); + AddClassRequirement("poll",$_PSL['classdir'] . "/Poll.class"); + AddClassRequirement("section",$_PSL['classdir'] . "/Section.class"); + AddClassRequirement("submission",$_PSL['classdir'] . "/Submission.class"); + AddClassRequirement("story_base",$_PSL['classdir'] . "/Story_base.class"); + AddClassRequirement("story","story_base"); + AddClassRequirement("story",$_PSL['classdir'] . "/Story.class"); + AddClassRequirement("story_admin","story_base"); + AddClassRequirement("story_admin",$_PSL['classdir'] . "/Story_admin.class"); + AddClassRequirement("topic",$_PSL['classdir'] . "/Topic.class"); + AddClassRequirement("topicbar",$_PSL['classdir'] . "/TopicBar.class"); + AddClassRequirement("tz",$_PSL['classdir'] . "/tz.class"); + AddLibraryRequirement("tz",$_PSL['classdir'] . "/tz_functions.inc"); + AddClassRequirement("tz_env","tz"); + AddClassRequirement("tz_env",$_PSL['classdir'] . "/tz_env.class"); + AddClassRequirement("tz_nonnative","tz"); + AddClassRequirement("tz_nonnative",$_PSL['classdir'] . "/tz_nonnative.class"); + AddClassRequirement("tz_posix","tz_nonnative"); + AddClassRequirement("tz_posix",$_PSL['classdir'] . "/tz_posix.class"); + AddClassRequirement("tz_file","tz_nonnative"); + AddClassRequirement("tz_file",$_PSL['classdir'] . "/tz_file.class"); + AddClassRequirement("variable",$_PSL['classdir'] . "/variable.class"); + + /** + * Modules + * + * Setting one of these variables to true enables the module. If you + * don't use or don't want one of them to show up, turn it off and you + * save the price of compiling extra code or visiting the database. + **/ $_PSL['module']['Glossary'] = true; $_PSL['module']['MailingList'] = true; *************** *** 251,254 **** --- 502,508 ---- $_PSL['module']['Group'] = true; + /** + * Other flags + **/ $_PSL['show_admin_on_navbar'] = false; // turns the Admin link on in the navbar *************** *** 266,274 **** // $_PSL['censorfile'] = "/var/www/phorum-3.2.1/include/censor.php"; //use phorum's censor file - $_PSL['localedir'] = $_PSL['classdir'] . "/locale"; // directory holding language files - $_PSL['language'] = "en"; // default language ( ISO format) - $_PSL['article_updatehits'] = true; // Keeps track of hits on a story, // the drawback is an extra DB query. /******************** These values are used in your RSS Feeds generated by backend.php3 as --- 520,526 ---- // $_PSL['censorfile'] = "/var/www/phorum-3.2.1/include/censor.php"; //use phorum's censor file $_PSL['article_updatehits'] = true; // Keeps track of hits on a story, // the drawback is an extra DB query. + /******************** These values are used in your RSS Feeds generated by backend.php3 as *************** *** 357,361 **** // ;; LC_MESSAGES could be used for translation of messages. ! // ;; Currently, that's derived from $_PSL['language'] $_PSL['locale']['LC_MESSAGES'] = 'en'; --- 609,613 ---- // ;; LC_MESSAGES could be used for translation of messages. ! // ;; (not used) Currently, that's derived from $_PSL['language'] $_PSL['locale']['LC_MESSAGES'] = 'en'; *************** *** 385,389 **** //;; way (find the right path): ! ;;$_PSL['timezone']['default'] = ':/etc/localtime'; //;; If you are not using native timezones, but are using the time zone --- 637,641 ---- //;; way (find the right path): ! $_PSL['timezone']['default'] = ':/etc/localtime'; //;; If you are not using native timezones, but are using the time zone *************** *** 397,489 **** //;; $_PSL['timezone']['name'] = 'GMT+0BST,M4.1.0/1,M10.5.0/2'; - // 1.2) Other PHPLIB things not already included. Comment out if this - // is something you've already delt with in prepend.php3 - - require($_PHPLIB['libdir'] . 'template.inc'); - - - // 1.3) PHPSlash functions library - require($_PSL['classdir'] . '/functions.inc'); - - $ary = array(); - if(!empty($HTTP_GET_VARS)) { - $ary = clean($HTTP_GET_VARS); - } - - if ((empty($ary['section'])) AND (empty($ary['section_id']))){ - $section_id = $_PSL['home_section_id']; - if(!$section_id) { - $section_id = "3"; - } - $ary['section_id'] = $section_id; - } - - /* now that the functions are in, we can define the arg_separator */ - - $_PSL['amp'] = arg_separator("1"); - - // 1.99) Add any other require()'s or include()'s you need here and they - // should be prepended to all phpSlash pages - - // comment to enable setting lang in url - $lang = false; - - $_PSL['languagefile'] = $_PSL['localedir'] . "/" . $_PSL['language'] . ".php3"; - - // comment to disable auto lang detection - $_PSL['languagefile'] = setLang($lang); - - // comment to disable auto tpl lang detection - $_PSL['templatedir'] = setLangTpl($lang); - - // Sets the default skin for a site - $_PSL['defaultskin'] = "basic"; // no css skin - "default" - - // comment out this block to disable setting theme in url - if (!empty($HTTP_GET_VARS['skin'])) { - $_PSL['templatedir'] = setSkinTpl($HTTP_GET_VARS['skin'], "cookie"); - } else { - $_PSL['templatedir'] = setSkinTpl("", "cookie"); - } - - if ($_PSL['timezone']['engine']) { - include($_PSL['classdir'] . '/tz.class'); - include($_PSL['classdir'] . '/tz_env.class'); - include($_PSL['classdir'] . '/tz_nonnative.class'); - include($_PSL['classdir'] . '/tz_posix.class'); - include($_PSL['classdir'] . '/tz_file.class'); - include($_PSL['classdir'] . '/tz_functions.inc'); - // set up the time zone environment array - $_TZ = $_PSL['timezone']; - $_TZ['templatedir'] = $_PSL['templatedir']; - $_TZ['show_format'] = psl_getLocalInfo('LC_TIME','%a %b %e %H:%M:%S %Z %Y'); - /* $_TZ['available'] = array("America/New_York", - "America/Chicago", - "America/Denver", - "America/Los_Angeles", - "Pacific/Honolulu"); - */ - // to enable setting of time zone in URL - set_TZ($HTTP_GET_VARS['TZ'],'cookie'); - // to disable setting in URL and to set $_PSL['timezone']['name'] as the time zone - // set_TZ(); - } - - // NavBar Menu Definitions $menuitem = array(); ! /* ! * menuitem array legend: ! * ! * name - The text displayed in the NavBar menu. This text is checked in the ! * languagefile. To customize, change the text in the appropriate * languagefile to avoid translation problems. ! * link - url for menu item link. ! * perm - permission require to view this menu item. "nobody" for all clients. ! * module - module require for viewing this menu item. "" (blank) for all. ! * ! * To add navbar menu items, add a complete entry below. Translation will be ! * attempted automatically. ! */ $menuitem[] = array( 'name' => "Login", --- 649,668 ---- //;; $_PSL['timezone']['name'] = 'GMT+0BST,M4.1.0/1,M10.5.0/2'; // NavBar Menu Definitions $menuitem = array(); ! /** ! * menuitem array legend: ! * ! * name - The text displayed in the NavBar menu. This text is checked in the ! * languagefile. To customize, change the text in the appropriate ! * languagefile to avoid translation problems. ! * link - url for menu item link. ! * perm - permission require to view this menu item. "nobody" for all clients. ! * module - module require for viewing this menu item. "" (blank) for all. ! * ! * To add navbar menu items, add a complete entry below. Translation will be ! * attempted automatically. ! **/ $menuitem[] = array( 'name' => "Login", *************** *** 657,774 **** // 2.2) PHPLIB Perm Class extension - /* - $_PSL['perm_array'] = array( - "nobody" => 2, - "user" => 4, - "topic" => 64, - "story" => 256, - "storyeditor" => 512, - "comment" => 1024, - "section" => 16384, - "submission" => 65536, - "block" => 262144, - "poll" => 1048576, - "author" => 4194304, - "variable" => 16777216, - "glossary" => 67108864, - "mailinglist" => 268435456, - "logging" => 1073741824, - "root" => 2147483648 - ); - */ - // 2.3) PHPSlash<->phplib interface classes - require($_PSL['classdir'] . "/slashDB.class"); - require($_PSL['classdir'] . "/slash_sql.class"); - require($_PSL['classdir'] . "/slashSess.class"); - // require($_PSL['classdir'] . "/slashAuth.class"); - require($_PSL['classdir'] . "/slashAuthCR.class"); - require($_PSL['classdir'] . "/slashPerm.class"); - - // 2.2) PHPLIB Session Support - - ////////////////////////////////////////////////////////////////////////// - // SECTION 3 - PHPSLASH CLASS CONFIGURATION ------------------------------ - ////////////////////////////////////////////////////////////////////////// - - require($_PSL['classdir'] . "/Topic.class"); - require($_PSL['classdir'] . "/Section.class"); - - foreach($_PSL['module'] as $key => $value) { - - switch ($key) { - - case 'Author': - - require($_PSL['classdir'] . "/Author.class"); - break; - - case 'Block': - - require($_PSL['classdir'] . "/Block.class"); - require($_PSL['classdir'] . "/Block_i.class"); - // require($_PSL['classdir'] . "/Block_admin.class"); - require($_PSL['classdir'] . "/Block_render_i.class"); - break; - - case 'Comment': - - require($_PSL['classdir'] . "/Comment.class"); - break; - - case 'Glossary': - - require($_PSL['classdir'] . "/Glossary.class"); - break; - - case 'Group': - - require($_PSL['classdir'] . "/Group.class"); - break; - - case 'MailingList': - - require($_PSL['classdir'] . "/MailingList.class"); - break; - - - case 'NavBar': - - require($_PSL['classdir'] . "/NavBar.class"); - break; - - case 'Poll': - - require($_PSL['classdir'] . "/Poll.class"); - break; - - case 'Story': - - require($_PSL['classdir'] . "/Story_base.class"); - require($_PSL['classdir'] . "/Story.class"); - // require($_PSL['classdir'] . "/Story_admin.class"); - break; - - case 'Submission': - - require($_PSL['classdir'] . "/Submission.class"); - break; - - case 'TopicBar': - - require($_PSL['classdir'] . "/TopicBar.class"); - break; - - case 'Variable': - - require($_PSL['classdir'] . "/Variable.class"); - break; - - } - - } - - - ////////////////////////////////////////////////////////////////////////// --- 836,841 ---- // 2.2) PHPLIB Perm Class extension + // Changed in M7 ////////////////////////////////////////////////////////////////////////// *************** *** 780,785 **** /** * 2 means accept all qualifiers: <foo bar> ! * 1 means accept the tag only: <foo> ! */ $_PSL['approvedtags'] = array( "p"=>1, --- 847,851 ---- /** * 2 means accept all qualifiers: <foo bar> ! * 1 means accept the tag only: <foo> */ $_PSL['approvedtags'] = array( "p"=>1, *************** *** 805,836 **** $_PSL['expirerelated'] = 14400; ! ! page_open(array('sess' => 'slashSess', ! 'auth' => 'slashAuth', ! 'perm' => 'slashPerm')); ! ! /* ============= Things to deprecate ============= */ ! ! // ---------------------------------------------------------- ! // Ref'ed in Block_i ! // $templatedir = $_PSL['templatedir']; ! ! // ---------------------------------------------------------- ! // The following can be deleted ! // ---------------------------------------------------------- ! // if ($sitename=="") $sitename = $_PSL['site_name']; ! // if ($siteowner=="") $siteowner = $_PSL['site_owner']; ! // $rootdir = $_PSL['rooturl']; ! // $debug = $_PSL['debug']; ! // $debug_type = $_PSL['debug_type']; ! // $infolog_enable = $_PSL['use_infolog']; ! // $default_pending = $_PSL['default_pending']; ! // $show_admin_on_navbar = $_PSL['show_admin_on_navbar']; ! // $max_poll_answers = $_PSL['poll_max_answers']; ! // $admindir = $_PSL['adminurl']; ! // $imagedir = $_PSL['imageurl']; ! // $classdir = $_PSL['classdir']; ! // $basedir = $_PSL['basedir']; ! // ---------------------------------------------------------- ?> --- 871,891 ---- $_PSL['expirerelated'] = 14400; ! if ($_PSL['timezone']['engine']) { ! loadLibrary("tz"); ! // set up the time zone environment array ! $_TZ =& $_PSL['timezone']; ! $_TZ['templatedir'] = $_PSL['templatedir']; ! $_TZ['show_format'] = psl_getLocalInfo('LC_TIME','%a %b %e %H:%M:%S %Z %Y'); ! /* $_TZ['available'] = array("America/New_York", ! "America/Chicago", ! "America/Denver", ! "America/Los_Angeles", ! "Pacific/Honolulu"); ! */ ! // to enable setting of time zone in URL ! set_TZ($HTTP_GET_VARS['TZ'],'cookie'); ! // to disable setting in URL and to set $_PSL['timezone']['name'] as the time zone ! // set_TZ(); ! } ?> Index: errordocument.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/errordocument.php3,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** errordocument.php3 11 Nov 2002 21:22:58 -0000 1.4 --- errordocument.php3 11 Dec 2002 21:25:54 -0000 1.5 *************** *** 7,11 **** $xsiteobject = pslgetText("Error Document"); // This Defines The META Tag Object Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); if(!empty($HTTP_GET_VARS['login'])) { --- 7,11 ---- $xsiteobject = pslgetText("Error Document"); // This Defines The META Tag Object Type ! // page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); if(!empty($HTTP_GET_VARS['login'])) { *************** *** 15,20 **** // Objects ! $block = new Block_i; ! $db = new slashDB; // Start of Page --- 15,20 ---- // Objects ! $block = pslNew("Block_i"); ! $db = pslNew("slashDB"); // Start of Page *************** *** 43,47 **** // logwrite("404", "File Not Found " . $REDIRECT_URL); ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 43,47 ---- // logwrite("404", "File Not Found " . $REDIRECT_URL); ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( *************** *** 76,80 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 76,80 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: glossary.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/glossary.php3,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** glossary.php3 4 Dec 2002 20:27:43 -0000 1.16 --- glossary.php3 11 Dec 2002 21:25:54 -0000 1.17 *************** *** 39,43 **** /* DEBUG */ ! $glossary = new Glossary; if(empty($ary['search'])) { --- 39,43 ---- /* DEBUG */ ! $glossary = pslNew("Glossary"); if(empty($ary['search'])) { *************** *** 45,49 **** } $content = $glossary->searchGlossary($ary['search']); ! $block = new Block_i; $breadcrumb = breadcrumb($ary); --- 45,49 ---- } $content = $glossary->searchGlossary($ary['search']); ! $block = pslNew("Block_i"); $breadcrumb = breadcrumb($ary); *************** *** 70,74 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 70,74 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: index.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/index.php3,v retrieving revision 1.62 retrieving revision 1.63 diff -C2 -d -r1.62 -r1.63 *** index.php3 22 Nov 2002 18:43:47 -0000 1.62 --- index.php3 11 Dec 2002 21:25:54 -0000 1.63 *************** *** 13,20 **** // Objects ! // $poll = new Poll; ! $story = new Story; ! $block = new Block_i; ! // $db = new slashDB; // Start of Page --- 13,20 ---- // Objects ! // $poll = pslNew("Poll"); ! $story = pslNew("Story"); ! $block = pslNew("Block_i"); ! // $db = pslNew("slashDB"); // Start of Page *************** *** 26,29 **** --- 26,31 ---- slashhead($pagetitle,$_PSL['metatags']); + debug("ary",$ary); + $allstories = $story->getStories($ary); $leftblocks = $block->getBlocks($ary, "left"); *************** *** 47,51 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 49,53 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: login.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/login.php3,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** login.php3 4 Dec 2002 20:27:44 -0000 1.32 --- login.php3 11 Dec 2002 21:25:54 -0000 1.33 *************** *** 42,53 **** $auth->start(); } - $auth->login_if(!$perm->have_perm('user')); // Objects ! // $story = new Story; ! $block = new Block_i; ! // $db = new slashDB; // Start of Page --- 42,52 ---- $auth->start(); } $auth->login_if(!$perm->have_perm('user')); // Objects ! // $story = pslNew("Story"); ! $block = pslNew("Block_i"); ! // $db = pslNew("slashDB"); // Start of Page *************** *** 97,101 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 96,100 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: mailinglist.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/mailinglist.php3,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** mailinglist.php3 4 Dec 2002 20:27:44 -0000 1.10 --- mailinglist.php3 11 Dec 2002 21:25:54 -0000 1.11 *************** *** 33,37 **** /* DEBUG */ ! $list = new MailingList; $content = ''; --- 33,37 ---- /* DEBUG */ ! $list = pslNew("MailingList"); $content = ''; *************** *** 60,64 **** } ! $block = new Block_i; // $breadcrumb = breadcrumb($ary); --- 60,64 ---- } ! $block = pslNew("Block_i"); // $breadcrumb = breadcrumb($ary); *************** *** 85,89 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 85,89 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: poll.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/poll.php3,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** poll.php3 4 Dec 2002 20:27:45 -0000 1.19 --- poll.php3 11 Dec 2002 21:25:54 -0000 1.20 *************** *** 34,38 **** $as = arg_separator("1"); # Default: = & ! $poll = new Poll; // debug("HTTP_POST_VARS", $HTTP_POST_VARS); --- 34,38 ---- $as = arg_separator("1"); # Default: = & ! $poll = pslNew("Poll"); // debug("HTTP_POST_VARS", $HTTP_POST_VARS); *************** *** 100,104 **** } ! $block = new Block_i; // $breadcrumb = breadcrumb($ary); --- 100,104 ---- } ! $block = pslNew("Block_i"); // $breadcrumb = breadcrumb($ary); *************** *** 125,129 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 125,129 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: profile.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/profile.php3,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** profile.php3 5 Dec 2002 13:14:59 -0000 1.7 --- profile.php3 11 Dec 2002 21:25:54 -0000 1.8 *************** *** 46,50 **** /* DEBUG */ ! $author = new Author; $content = ''; --- 46,50 ---- /* DEBUG */ ! $author = pslNew("Author"); $content = ''; *************** *** 79,83 **** } ! $block = new Block_i; $ary = array(); --- 79,83 ---- } ! $block = pslNew("Block_i"); $ary = array(); *************** *** 118,122 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 118,122 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: search.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/search.php3,v retrieving revision 1.52 retrieving revision 1.53 diff -C2 -d -r1.52 -r1.53 *** search.php3 24 Nov 2002 23:12:55 -0000 1.52 --- search.php3 11 Dec 2002 21:25:54 -0000 1.53 *************** *** 38,42 **** global $topic_image_height; ! $db = new slashDB; if ($id == "") { --- 38,42 ---- global $topic_image_height; ! $db = pslNew("slashDB"); if ($id == "") { *************** *** 99,103 **** } else { $name = clean($name); ! $db = new slashDB; $q = "SELECT section_id from psl_section WHERE section_name = '$name'"; $db->query($q); --- 99,103 ---- } else { $name = clean($name); ! $db = pslNew("slashDB"); $q = "SELECT section_id from psl_section WHERE section_name = '$name'"; $db->query($q); *************** *** 116,120 **** } else { $name = clean($name); ! $db = new slashDB; $q = "SELECT author_id from psl_author WHERE author_name = '$name'"; $db->query($q); --- 116,120 ---- } else { $name = clean($name); ! $db = pslNew("slashDB"); $q = "SELECT author_id from psl_author WHERE author_name = '$name'"; $db->query($q); *************** *** 143,150 **** /*************/ ! $db = new slashDB; $db->debug = false; ! $block = new Block_i; /*************PAGE START*******************/ --- 143,150 ---- /*************/ ! $db = pslNew("slashDB"); $db->debug = false; ! $block = pslNew("Block_i"); /*************PAGE START*******************/ *************** *** 168,172 **** /* Templates */ ! $templ = new Template ($_PSL[templatedir]); $templ->debug = false; $templ->set_file (searchpage, "searchPage.tpl"); --- 168,172 ---- /* Templates */ ! $templ = pslNew(Template ,$_PSL[templatedir]); $templ->debug = false; $templ->set_file (searchpage, "searchPage.tpl"); *************** *** 477,481 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 477,481 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: submission.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/submission.php3,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** submission.php3 4 Dec 2002 20:27:46 -0000 1.15 --- submission.php3 11 Dec 2002 21:25:54 -0000 1.16 *************** *** 40,44 **** // debug("submission_id_ary" , $submission_id_ary); ! $submission = new Submission; if(empty($ary_post['submit'])) { --- 40,44 ---- // debug("submission_id_ary" , $submission_id_ary); ! $submission = pslNew("Submission"); if(empty($ary_post['submit'])) { *************** *** 76,80 **** } /* end of switch */ ! $block = new Block_i; if ((empty($ary['section'])) AND (empty($ary['section_id']))){ --- 76,80 ---- } /* end of switch */ ! $block = pslNew("Block_i"); if ((empty($ary['section'])) AND (empty($ary['section_id']))){ *************** *** 111,115 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 111,115 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: test.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/test.php3,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** test.php3 4 Dec 2002 20:27:47 -0000 1.7 --- test.php3 11 Dec 2002 21:25:54 -0000 1.8 *************** *** 168,172 **** <?php if ($phplib) { ?> <li>I am now going to try to create a slashSess class. If this line is the last thing that you see, then you do not have class slashSess defined in the config.php3 file. Fix that before proceeding.</li> ! <?php $sess = new slashSess; if ($sess): ?> <li><font color="green">Created a slashSess instance successfully.</font></li> --- 168,172 ---- <?php if ($phplib) { ?> <li>I am now going to try to create a slashSess class. If this line is the last thing that you see, then you do not have class slashSess defined in the config.php3 file. Fix that before proceeding.</li> ! <?php $sess = pslNew("slashSess"); if ($sess): ?> <li><font color="green">Created a slashSess instance successfully.</font></li> |
From: Matthew L. <sym...@us...> - 2002-12-11 19:42:26
|
Update of /cvsroot/phpslash/phpslash-ft In directory sc8-pr-cvs1:/tmp/cvs-serv25573 Modified Files: CHANGES Log Message: New library lib.resources.php detailed. Index: CHANGES =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/CHANGES,v retrieving revision 1.629 retrieving revision 1.630 diff -C2 -d -r1.629 -r1.630 *** CHANGES 5 Dec 2002 13:14:58 -0000 1.629 --- CHANGES 11 Dec 2002 19:42:23 -0000 1.630 *************** *** 13,16 **** --- 13,47 ---- 9 - Removal of something (kill -9 :) + 2002-December-11 2:00PM EST Matthew Leingang <sym...@us...> + [F] - Added class/lib.resources.php + Changed: Author.class, Block.class, + Block_admin.class, Block_i.class, Block_render_cal.class, + Block_render_comments.class, Block_render_html.class, + Block_render_login.class, Block_render_navbar.class, + Block_render_poll.class, Block_render_query.class, + Block_render_quote.class, Block_render_rss.class, + Block_render_section.class, Block_render_skin.class, + Block_render_submission.class, Block_render_topic.class, + Comment.class, Glossary.class, Group.class, Infolog.class, + MailingList.class, NavBar.class, Poll.class, Section.class, + Story.class, Story_admin.class, Story_base.class, + Submission.class, Topic.class, TopicBar.class, Variable.class, + functions.inc, libtz.inc, slashAuth.class, slashAuthCR.class, + slashSess.class, slash_sql.class, tz.class, tz_functions.inc, + tz_posix.class, about.php3, article.php3, backend.php3, + comment.php3, config.php3, errordocument.php3, glossary.php3, + index.php3, login.php3, mailinglist.php3, poll.php3, profile.php3, + search.php3, submission.php3, test.php3, authorAdmin.php3, + blockAdmin.php3, commentAdmin.php3, admin/config.php3, + glossaryAdmin.php3, groupAdmin.php3, infologAdmin.php3, + mailinglistAdmin.php3, pollAdmin.php3, sectionAdmin.php3, + storyAdmin.php3, submissionAdmin.php3, topicAdmin.php3, + variableAdmin.php3 - + Library lib.resources.php provides a pslNew function, which allows + for one-stop customizing of classes. All new's are replaced by + pslNew's. slashSess::serialize is touched up to allow on-the-fly + class loading. config.php3 is undergoing reorg in the aim of + separating out things that need only be called once per session. + 2002-December-5 7:00AM CST Joe Stewart <joe...@us...> [B] - profile.php3, groupAdmin.php3, pollAdmin.php3, storyAdmin.php3, |
From: Matthew L. <sym...@us...> - 2002-12-11 19:41:44
|
Update of /cvsroot/phpslash/phpslash-ft/public_html/admin In directory sc8-pr-cvs1:/tmp/cvs-serv25292/admin Modified Files: authorAdmin.php3 blockAdmin.php3 commentAdmin.php3 config.php3 glossaryAdmin.php3 groupAdmin.php3 infologAdmin.php3 mailinglistAdmin.php3 pollAdmin.php3 sectionAdmin.php3 storyAdmin.php3 submissionAdmin.php3 topicAdmin.php3 variableAdmin.php3 Log Message: All new's changed to pslNew's Index: authorAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/authorAdmin.php3,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** authorAdmin.php3 11 Nov 2002 22:22:36 -0000 1.12 --- authorAdmin.php3 11 Dec 2002 19:41:37 -0000 1.13 *************** *** 8,12 **** $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 8,14 ---- $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 18,22 **** $content = ''; ! $author = new Author; if(!empty($HTTP_POST_VARS['submit'])) { --- 20,24 ---- $content = ''; ! $author = pslNew("Author"); if(!empty($HTTP_POST_VARS['submit'])) { *************** *** 95,99 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 97,101 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 121,125 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 123,127 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: blockAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/blockAdmin.php3,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** blockAdmin.php3 5 Dec 2002 13:14:59 -0000 1.12 --- blockAdmin.php3 11 Dec 2002 19:41:37 -0000 1.13 *************** *** 13,20 **** /* Open the page with session variables enabled */ ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /* Start Block Object */ ! $block = new Block_admin; /***************************** --- 13,22 ---- /* Open the page with session variables enabled */ ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /* Start Block Object */ ! $block = pslNew("Block_admin"); /***************************** *************** *** 100,104 **** } ! // $block = new Block_i; $ary['section'] = "Admin"; --- 102,106 ---- } ! // $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 126,130 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 128,132 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: commentAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/commentAdmin.php3,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** commentAdmin.php3 22 Nov 2002 19:01:32 -0000 1.14 --- commentAdmin.php3 11 Dec 2002 19:41:38 -0000 1.15 *************** *** 10,15 **** $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); ! /***************************** START OF PAGE --- 10,16 ---- $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** START OF PAGE *************** *** 25,29 **** /* END DEBUG */ ! $cmt = new Comment; $content = ''; --- 26,30 ---- /* END DEBUG */ ! $cmt = pslNew("Comment"); $content = ''; *************** *** 156,160 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 157,161 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 182,186 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 183,187 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: config.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/config.php3,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** config.php3 24 Nov 2002 23:32:18 -0000 1.4 --- config.php3 11 Dec 2002 19:41:38 -0000 1.5 *************** *** 18,23 **** case 'Block': ! ! require($_PSL['classdir'] . "/Block_admin.class"); break; --- 18,23 ---- case 'Block': ! // pslNew takes care of this ! // require($_PSL['classdir'] . "/Block_admin.class"); break; *************** *** 49,53 **** case 'Story': ! require($_PSL['classdir'] . "/Story_admin.class"); break; --- 49,54 ---- case 'Story': ! // require($_PSL['classdir'] . "/Story_admin.class"); ! // pslNew takes care of this break; Index: glossaryAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/glossaryAdmin.php3,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** glossaryAdmin.php3 11 Nov 2002 22:22:37 -0000 1.5 --- glossaryAdmin.php3 11 Dec 2002 19:41:38 -0000 1.6 *************** *** 8,12 **** $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 8,14 ---- $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 27,31 **** /* DEBUG */ ! $glossary = new Glossary; $content = ''; --- 29,33 ---- /* DEBUG */ ! $glossary = pslNew("Glossary"); $content = ''; *************** *** 92,96 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 94,98 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 118,122 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 120,124 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: groupAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/groupAdmin.php3,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** groupAdmin.php3 5 Dec 2002 13:14:59 -0000 1.7 --- groupAdmin.php3 11 Dec 2002 19:41:38 -0000 1.8 *************** *** 8,12 **** $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 8,14 ---- $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 26,30 **** /* DEBUG */ ! $group = new Group; $content = ''; --- 28,32 ---- /* DEBUG */ ! $group = pslNew("Group"); $content = ''; *************** *** 176,180 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 178,182 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 202,206 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 204,208 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: infologAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/infologAdmin.php3,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** infologAdmin.php3 11 Nov 2002 22:22:39 -0000 1.8 --- infologAdmin.php3 11 Dec 2002 19:41:38 -0000 1.9 *************** *** 10,17 **** $xsiteobject = pslgetText("Administration"); ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); ! require($_PSL['classdir'] . '/Infolog.class'); ! $log = new Infolog; /***************************** --- 10,18 ---- $xsiteobject = pslgetText("Administration"); ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } ! $log = pslNew("Infolog"); /***************************** *************** *** 58,62 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 59,63 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 84,88 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 85,89 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: mailinglistAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/mailinglistAdmin.php3,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** mailinglistAdmin.php3 11 Nov 2002 22:22:39 -0000 1.7 --- mailinglistAdmin.php3 11 Dec 2002 19:41:38 -0000 1.8 *************** *** 8,12 **** $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 8,14 ---- $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 23,27 **** /* DEBUG */ ! $list = new MailingList; $content = ''; --- 25,29 ---- /* DEBUG */ ! $list = pslNew("MailingList"); $content = ''; *************** *** 82,86 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 84,88 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 108,112 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 110,114 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: pollAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/pollAdmin.php3,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** pollAdmin.php3 5 Dec 2002 13:14:59 -0000 1.13 --- pollAdmin.php3 11 Dec 2002 19:41:38 -0000 1.14 *************** *** 8,12 **** $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 8,14 ---- $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 21,25 **** /* END DEBUG STUFF */ ! $poll = new Poll; $content = ''; --- 23,27 ---- /* END DEBUG STUFF */ ! $poll = pslNew("Poll"); $content = ''; *************** *** 90,94 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 92,96 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 116,120 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 118,122 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: sectionAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/sectionAdmin.php3,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** sectionAdmin.php3 11 Nov 2002 22:37:32 -0000 1.8 --- sectionAdmin.php3 11 Dec 2002 19:41:38 -0000 1.9 *************** *** 10,14 **** $xsiteobject = pslgetText("Administration"); ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 10,16 ---- $xsiteobject = pslgetText("Administration"); ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 28,32 **** // debug( "description", $description ); ! $section = new Section; if(!empty($HTTP_POST_VARS['submit'])) { --- 30,34 ---- // debug( "description", $description ); ! $section = pslNew("Section"); if(!empty($HTTP_POST_VARS['submit'])) { *************** *** 85,89 **** $ary = ''; ! $block = new Block_i; $ary['section'] = "Admin"; --- 87,91 ---- $ary = ''; ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 111,115 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 113,117 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: storyAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/storyAdmin.php3,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** storyAdmin.php3 5 Dec 2002 13:14:59 -0000 1.17 --- storyAdmin.php3 11 Dec 2002 19:41:38 -0000 1.18 *************** *** 5,12 **** require("config.php3"); $pagetitle = pslgetText("Story Administration"); // The name to be displayed in the header $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 5,15 ---- require("config.php3"); + $pagetitle = pslgetText("Story Administration"); // The name to be displayed in the header $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 31,35 **** $content = ''; ! $story = new Story_admin; if ($perm->have_perm("storyList")) { --- 34,38 ---- $content = ''; ! $story = pslNew("Story_admin"); if ($perm->have_perm("storyList")) { *************** *** 113,117 **** } ! $block = new Block_i; $ary['section'] = "Admin"; --- 116,120 ---- } ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 139,143 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 142,146 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: submissionAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/submissionAdmin.php3,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** submissionAdmin.php3 11 Nov 2002 22:39:47 -0000 1.10 --- submissionAdmin.php3 11 Dec 2002 19:41:39 -0000 1.11 *************** *** 7,11 **** $xsiteobject = pslgetText("Administration");#Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); if (isset($cookie)) { --- 7,13 ---- $xsiteobject = pslgetText("Administration");#Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } if (isset($cookie)) { *************** *** 29,33 **** // debug("submission_id_ary" , $submission_id_ary); ! $submission = new Submission; if(!empty($HTTP_POST_VARS['submit'])) { --- 31,35 ---- // debug("submission_id_ary" , $submission_id_ary); ! $submission = pslNew("Submission"); if(!empty($HTTP_POST_VARS['submit'])) { *************** *** 137,141 **** $ary = ''; ! $block = new Block_i; $ary['section'] = "Admin"; --- 139,143 ---- $ary = ''; ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 163,167 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 165,169 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: topicAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/topicAdmin.php3,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** topicAdmin.php3 11 Nov 2002 22:22:39 -0000 1.6 --- topicAdmin.php3 11 Dec 2002 19:41:39 -0000 1.7 *************** *** 8,12 **** $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); /***************************** --- 8,14 ---- $xsiteobject = pslgetText("Administration"); // Defines The META TAG Page Type ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** *************** *** 29,33 **** $auth->login_if(!$perm->have_perm('topicList')); ! $topic = new Topic; $content = ''; --- 31,35 ---- $auth->login_if(!$perm->have_perm('topicList')); ! $topic = pslNew("Topic"); $content = ''; *************** *** 96,100 **** $ary = ''; ! $block = new Block_i; $ary['section'] = "Admin"; --- 98,102 ---- $ary = ''; ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 122,126 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 124,128 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( Index: variableAdmin.php3 =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/public_html/admin/variableAdmin.php3,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** variableAdmin.php3 11 Nov 2002 22:22:39 -0000 1.7 --- variableAdmin.php3 11 Dec 2002 19:41:39 -0000 1.8 *************** *** 11,16 **** $xsiteobject = pslgetText("Administration"); ! page_open(array("sess"=>"slashSess","auth"=>"slashAuth","perm"=>"slashPerm")); ! /***************************** START OF PAGE --- 11,17 ---- $xsiteobject = pslgetText("Administration"); ! if (!is_object($sess)) { ! page_open($_PSL['page_features']); ! } /***************************** START OF PAGE *************** *** 27,31 **** /* DEBUG */ ! $variable = new Variable; $content = ''; --- 28,32 ---- /* DEBUG */ ! $variable = pslNew("Variable"); $content = ''; *************** *** 96,100 **** $ary = ''; ! $block = new Block_i; $ary['section'] = "Admin"; --- 97,101 ---- $ary = ''; ! $block = pslNew("Block_i"); $ary['section'] = "Admin"; *************** *** 122,126 **** } ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 123,127 ---- } ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( |
Update of /cvsroot/phpslash/phpslash-ft/class In directory sc8-pr-cvs1:/tmp/cvs-serv24600 Modified Files: Author.class Block.class Block_admin.class Block_i.class Block_render_cal.class Block_render_comments.class Block_render_html.class Block_render_login.class Block_render_navbar.class Block_render_poll.class Block_render_query.class Block_render_quote.class Block_render_rss.class Block_render_section.class Block_render_skin.class Block_render_submission.class Block_render_topic.class Comment.class Glossary.class Group.class Infolog.class MailingList.class NavBar.class Poll.class Section.class Story.class Story_admin.class Story_base.class Submission.class Topic.class TopicBar.class Variable.class functions.inc libtz.inc slashAuth.class slashAuthCR.class slashSess.class slash_sql.class tz.class tz_functions.inc tz_posix.class Log Message: All new's are changed to pslNew's. Index: Author.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Author.class,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** Author.class 11 Nov 2002 15:35:38 -0000 1.33 --- Author.class 11 Dec 2002 19:39:52 -0000 1.34 *************** *** 35,39 **** global $perm, $_PSL, $auth; ! $this->db = new slashDB; $this->perm = &$perm; $this->psl = &$_PSL; --- 35,39 ---- global $perm, $_PSL, $auth; ! $this->db = pslNew("slashDB"); $this->perm = &$perm; $this->psl = &$_PSL; *************** *** 41,45 **** /* Templates */ ! $this->author_templ = new Template($this->psl['templatedir'], "remove"); $this->author_templ->debug = 0; $this->author_templ->set_file(array( --- 41,45 ---- /* Templates */ ! $this->author_templ = pslNew("Template",$this->psl['templatedir'], "remove"); $this->author_templ->debug = 0; $this->author_templ->set_file(array( Index: Block.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block.class,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** Block.class 4 Dec 2002 19:51:25 -0000 1.22 --- Block.class 11 Dec 2002 19:39:53 -0000 1.23 *************** *** 27,31 **** global $_PSL, $perm; ! $this->db = new slashDB; $this->db->Auto_Free = 1; --- 27,31 ---- global $_PSL, $perm; ! $this->db = pslNew("slashDB"); $this->db->Auto_Free = 1; *************** *** 423,426 **** --- 423,427 ---- $parserName = "Block_render_" . $mytype; $parserFile = $parserName . ".class"; + debug("Block::getParser::parserName",$parserName); static $parser_arr; *************** *** 428,437 **** if( empty($parser_arr[$mytype])) { ! if( @file_exists($this->psl['classdir'] .'/'. $parserFile)) { ! include($this->psl['classdir'] .'/'. $parserFile); ! $parser_arr[$mytype] = new $parserName; } else { $parser_arr[$mytype] = false; } } $this->parser = $parser_arr[$mytype]; --- 429,441 ---- if( empty($parser_arr[$mytype])) { ! /* ! if( @file_exists($this->psl['classdir'] .'/'. $parserFile)) { ! include($this->psl['classdir'] .'/'. $parserFile); ! $parser_arr[$mytype] = new $parserName; } else { $parser_arr[$mytype] = false; } + */ + $parser_arr[$mytype] = pslNew($parserName); } $this->parser = $parser_arr[$mytype]; *************** *** 554,558 **** // debug("Block.class::extractBlocks::ary", $ary); // a new db object because the parser uses this->db ! $db = new slashDB; $q = "SELECT psl_block.id, psl_block.type as type_id, --- 558,562 ---- // debug("Block.class::extractBlocks::ary", $ary); // a new db object because the parser uses this->db ! $db = pslNew("slashDB"); $q = "SELECT psl_block.id, psl_block.type as type_id, Index: Block_admin.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_admin.class,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** Block_admin.class 4 Dec 2002 19:51:25 -0000 1.4 --- Block_admin.class 11 Dec 2002 19:39:53 -0000 1.5 *************** *** 42,46 **** /* Start Template Object */ ! $this->templ = new Template($this->psl['templatedir'], "remove"); $this->templ->debug = 0; --- 42,46 ---- /* Start Template Object */ ! $this->templ = pslNew("Template",$this->psl['templatedir'], "remove"); $this->templ->debug = 0; *************** *** 270,274 **** function listBlockTypes($option="", $name="") { ! $this->templ = new Template($this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( --- 270,274 ---- function listBlockTypes($option="", $name="") { ! $this->templ = pslNew("Template",$this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( Index: Block_i.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_i.class,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** Block_i.class 4 Dec 2002 19:51:25 -0000 1.22 --- Block_i.class 11 Dec 2002 19:39:53 -0000 1.23 *************** *** 43,47 **** /* Start Template Object */ ! $this->templ = new Template($this->psl['templatedir']); $this->templ->debug = 0; --- 43,47 ---- /* Start Template Object */ ! $this->templ = pslNew("Template",$this->psl['templatedir']); $this->templ->debug = 0; *************** *** 93,97 **** function getBlocks($ary, $column="") { ! // debug("Block_i.class::getBlocks::ary", $ary); if ( $this->argv_ary != $ary) { --- 93,97 ---- function getBlocks($ary, $column="") { ! debug("Block_i.class::getBlocks::ary", $ary); if ( $this->argv_ary != $ary) { *************** *** 199,203 **** } ! // debug("Block_i.class::parseBlock::ary", $ary); return getFancyBox($width, $temptitle, $ary["cache_data"],$link, $box_type, $var_ary); --- 199,203 ---- } ! debug("Block_i.class::parseBlock::ary", $ary); return getFancyBox($width, $temptitle, $ary["cache_data"],$link, $box_type, $var_ary); Index: Block_render_cal.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_cal.class,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** Block_render_cal.class 21 Nov 2002 18:59:05 -0000 1.11 --- Block_render_cal.class 11 Dec 2002 19:39:53 -0000 1.12 *************** *** 18,22 **** // TODO: Make this class use $_PSL ! $templ = new Template($this->psl['templatedir']); $templ->set_file(array( 'calendar' => 'calendar.tpl' --- 18,22 ---- // TODO: Make this class use $_PSL ! $templ = pslNew("Template",$this->psl['templatedir']); $templ->set_file(array( 'calendar' => 'calendar.tpl' *************** *** 44,48 **** /* get all dates where there was a story in the current month */ ! $cal_q = new slashDB; $q = "SELECT date_available FROM psl_story --- 44,48 ---- /* get all dates where there was a story in the current month */ ! $cal_q = pslNew("slashDB"); $q = "SELECT date_available FROM psl_story Index: Block_render_comments.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_comments.class,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Block_render_comments.class 21 Nov 2002 18:59:05 -0000 1.5 --- Block_render_comments.class 11 Dec 2002 19:39:53 -0000 1.6 *************** *** 39,43 **** function comments($block_info) { ! $db = new slashDB; $default_tpl = "commentblock.tpl"; --- 39,43 ---- function comments($block_info) { ! $db = pslNew("slashDB"); $default_tpl = "commentblock.tpl"; *************** *** 72,76 **** } ! $template = new Template($templatedir . "/" . $skin); $template->debug = 0; $template->set_file(array( --- 72,76 ---- } ! $template = pslNew("Template",$templatedir . "/" . $skin); $template->debug = 0; $template->set_file(array( Index: Block_render_html.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_html.class,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Block_render_html.class 3 Sep 2002 19:52:57 -0000 1.3 --- Block_render_html.class 11 Dec 2002 19:39:54 -0000 1.4 *************** *** 21,25 **** /* ! $sl_q = new slashDB; $query = "SELECT cache_data FROM psl_block --- 21,25 ---- /* ! $sl_q = pslNew("slashDB"); $query = "SELECT cache_data FROM psl_block Index: Block_render_login.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_login.class,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Block_render_login.class 24 Oct 2002 18:12:10 -0000 1.5 --- Block_render_login.class 11 Dec 2002 19:39:54 -0000 1.6 *************** *** 54,58 **** } ! $template = new Template($this->psl['templatedir']); $template->debug = 0; $template->set_file(array( --- 54,58 ---- } ! $template = pslNew("Template",$this->psl['templatedir']); $template->debug = 0; $template->set_file(array( Index: Block_render_navbar.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_navbar.class,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Block_render_navbar.class 3 Sep 2002 19:52:57 -0000 1.2 --- Block_render_navbar.class 11 Dec 2002 19:39:54 -0000 1.3 *************** *** 26,30 **** } ! $navbar = new NavBar; //$navbar->getNavBar("navbarBlock"); $this->output = $navbar->getNavBar( $tpl, $this->psl[$menu_ary]); --- 26,30 ---- } ! $navbar = pslNew("NavBar"); //$navbar->getNavBar("navbarBlock"); $this->output = $navbar->getNavBar( $tpl, $this->psl[$menu_ary]); Index: Block_render_poll.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_poll.class,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Block_render_poll.class 24 Oct 2002 19:36:03 -0000 1.5 --- Block_render_poll.class 11 Dec 2002 19:39:54 -0000 1.6 *************** *** 19,23 **** function parse($block_info) { ! $this->poll = new Poll; $question_id = ""; --- 19,23 ---- function parse($block_info) { ! $this->poll = pslNew("Poll"); $question_id = ""; Index: Block_render_query.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_query.class,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** Block_render_query.class 22 Nov 2002 15:38:08 -0000 1.10 --- Block_render_query.class 11 Dec 2002 19:39:54 -0000 1.11 *************** *** 41,45 **** function query( $block_info) { ! $stories = new Story_base; $amp = $this->psl['amp']; --- 41,45 ---- function query( $block_info) { ! $stories = pslNew("Story_base"); $amp = $this->psl['amp']; *************** *** 65,69 **** } ! $template = new Template($this->psl['templatedir']); $template->debug = 0; $template->set_file(array( --- 65,69 ---- } ! $template = pslNew("Template",$this->psl['templatedir']); $template->debug = 0; $template->set_file(array( *************** *** 83,87 **** } } elseif ( (!empty($ary['section'])) AND ( $ary['section'] != $site_homesection)) { ! $section = new Section; $section_name = $section->getId($ary['section']); $story_id .= $amp . 'section=' . $section_name; --- 83,87 ---- } } elseif ( (!empty($ary['section'])) AND ( $ary['section'] != $site_homesection)) { ! $section = pslNew("Section"); $section_name = $section->getId($ary['section']); $story_id .= $amp . 'section=' . $section_name; *************** *** 90,94 **** $story_id .= $amp . 'topic_id=' . $ary['topic_id']; } elseif (!empty($ary['topic'])) { ! $topic = new Topic; $topic_name = $topic->getId($ary['topic']); $story_id .= $amp . 'topic=' . $topic_name; --- 90,94 ---- $story_id .= $amp . 'topic_id=' . $ary['topic_id']; } elseif (!empty($ary['topic'])) { ! $topic = pslNew("Topic"); $topic_name = $topic->getId($ary['topic']); $story_id .= $amp . 'topic=' . $topic_name; Index: Block_render_quote.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_quote.class,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** Block_render_quote.class 3 Sep 2002 19:54:40 -0000 1.6 --- Block_render_quote.class 11 Dec 2002 19:39:54 -0000 1.7 *************** *** 42,46 **** } ! $template = new Template($this->psl['templatedir']); $template->debug = 0; $template->set_file(array( --- 42,46 ---- } ! $template = pslNew("Template",$this->psl['templatedir']); $template->debug = 0; $template->set_file(array( *************** *** 48,52 **** )); ! $db = new slashDB; mt_srand((double)microtime()*1000000); --- 48,52 ---- )); ! $db = pslNew("slashDB"); mt_srand((double)microtime()*1000000); Index: Block_render_rss.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_rss.class,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** Block_render_rss.class 3 Sep 2002 19:54:40 -0000 1.11 --- Block_render_rss.class 11 Dec 2002 19:39:54 -0000 1.12 *************** *** 308,312 **** function Block_render_rss() { $this->Block_render_i(); ! $this->rdf = new rdfparser; $this->type = "rss"; /* set the 'type' */ --- 308,312 ---- function Block_render_rss() { $this->Block_render_i(); ! $this->rdf = pslNew("rdfparser"); $this->type = "rss"; /* set the 'type' */ *************** *** 364,368 **** // debug("rss::parse::items", $this->rdf->items); ! $template = new Template($this->psl["templatedir"]); $template->set_file ("block", $tpl); --- 364,368 ---- // debug("rss::parse::items", $this->rdf->items); ! $template = pslNew("Template",$this->psl["templatedir"]); $template->set_file ("block", $tpl); Index: Block_render_section.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_section.class,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** Block_render_section.class 24 Oct 2002 18:12:10 -0000 1.12 --- Block_render_section.class 11 Dec 2002 19:39:54 -0000 1.13 *************** *** 59,63 **** function sections( $block_info) { ! $db = new slashDB; $mode = ''; --- 59,63 ---- function sections( $block_info) { ! $db = pslNew("slashDB"); $mode = ''; *************** *** 85,89 **** } ! $template = new Template($this->psl['templatedir']); $template->debug = 0; $template->set_file(array( --- 85,89 ---- } ! $template = pslNew("Template",$this->psl['templatedir']); $template->debug = 0; $template->set_file(array( Index: Block_render_skin.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_skin.class,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** Block_render_skin.class 24 Oct 2002 18:12:10 -0000 1.8 --- Block_render_skin.class 11 Dec 2002 19:39:54 -0000 1.9 *************** *** 35,39 **** function skin( $block_info) { ! $db = new SlashDB; $default_tpl = "skinsblock.tpl"; --- 35,39 ---- function skin( $block_info) { ! $db = pslNew("SlashDB"); $default_tpl = "skinsblock.tpl"; *************** *** 69,73 **** } ! $template = new Template($templatedir . "/" . $skin); $template->debug = 0; $template->set_file(array( --- 69,73 ---- } ! $template = pslNew("Template",$templatedir . "/" . $skin); $template->debug = 0; $template->set_file(array( Index: Block_render_submission.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_submission.class,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Block_render_submission.class 23 Nov 2002 13:22:20 -0000 1.5 --- Block_render_submission.class 11 Dec 2002 19:39:54 -0000 1.6 *************** *** 31,38 **** function submisssions( $block_info) { ! $this->db = new SlashDB; // Templates ! $this->templ = new Template($this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file ( array( --- 31,38 ---- function submisssions( $block_info) { ! $this->db = pslNew("SlashDB"); // Templates ! $this->templ = pslNew("Template",$this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file ( array( Index: Block_render_topic.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Block_render_topic.class,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** Block_render_topic.class 22 Nov 2002 15:38:08 -0000 1.12 --- Block_render_topic.class 11 Dec 2002 19:39:54 -0000 1.13 *************** *** 34,38 **** function topics( $block_info) { ! $db = new slashDB; $mode = ''; --- 34,38 ---- function topics( $block_info) { ! $db = pslNew("slashDB"); $mode = ''; *************** *** 58,62 **** } ! $template = new Template($this->psl['templatedir']); $template->debug = 0; $template->set_file(array( --- 58,62 ---- } ! $template = pslNew("Template",$this->psl['templatedir']); $template->debug = 0; $template->set_file(array( Index: Comment.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Comment.class,v retrieving revision 1.37 retrieving revision 1.38 diff -C2 -d -r1.37 -r1.38 *** Comment.class 21 Nov 2002 18:59:05 -0000 1.37 --- Comment.class 11 Dec 2002 19:39:54 -0000 1.38 *************** *** 40,44 **** $this->psl = $_PSL; $this->perm = $perm; ! $this->db = new slashDB; $this->order = $ary['order']; $this->auth = $auth; --- 40,44 ---- $this->psl = $_PSL; $this->perm = $perm; ! $this->db = pslNew("slashDB"); $this->order = $ary['order']; $this->auth = $auth; *************** *** 56,60 **** /* Templates */ ! $this->ctempl = new Template($this->psl['templatedir'], 'remove'); $this->ctempl->debug = 0; $this->ctempl->set_file(array( --- 56,60 ---- /* Templates */ ! $this->ctempl = pslNew("Template",$this->psl['templatedir'], 'remove'); $this->ctempl->debug = 0; $this->ctempl->set_file(array( *************** *** 385,389 **** $all_comments = ''; ! $templ = new Template($this->psl['templatedir'], 'remove'); $templ->debug = 0; $templ->set_file(array( --- 385,389 ---- $all_comments = ''; ! $templ = pslNew("Template",$this->psl['templatedir'], 'remove'); $templ->debug = 0; $templ->set_file(array( *************** *** 427,431 **** $all_comments = ''; ! $templ = new Template($this->psl['templatedir'], remove); $templ->debug = 0; $templ->set_file(array( --- 427,431 ---- $all_comments = ''; ! $templ = pslNew("Template",$this->psl['templatedir'], remove); $templ->debug = 0; $templ->set_file(array( *************** *** 471,475 **** $all_comments = ''; ! $templ = new Template($this->psl['templatedir'], remove); $templ->debug = 0; $templ->set_file(array( --- 471,475 ---- $all_comments = ''; ! $templ = pslNew("Template",$this->psl['templatedir'], remove); $templ->debug = 0; $templ->set_file(array( Index: Glossary.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Glossary.class,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** Glossary.class 24 Oct 2002 18:12:10 -0000 1.9 --- Glossary.class 11 Dec 2002 19:39:54 -0000 1.10 *************** *** 20,29 **** global $_PSL; ! $this->db = new slashDB; $this->psl = $_PSL; $this->message = ''; /* Templates */ ! $this->templ = new Template($this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( --- 20,29 ---- global $_PSL; ! $this->db = pslNew("slashDB"); $this->psl = $_PSL; $this->message = ''; /* Templates */ ! $this->templ = pslNew("Template",$this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( Index: Group.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Group.class,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Group.class 24 Oct 2002 19:36:04 -0000 1.3 --- Group.class 11 Dec 2002 19:39:54 -0000 1.4 *************** *** 28,32 **** global $perm, $_PSL, $amp; ! $this->db = new slashDB; $this->perm = $perm; $this->psl = $_PSL; --- 28,32 ---- global $perm, $_PSL, $amp; ! $this->db = pslNew("slashDB"); $this->perm = $perm; $this->psl = $_PSL; *************** *** 34,38 **** /* Templates */ ! $this->group_templ = new Template($this->psl['templatedir']); $this->group_templ->debug = 0; $this->group_templ->set_file(array( --- 34,38 ---- /* Templates */ ! $this->group_templ = pslNew("Template",$this->psl['templatedir']); $this->group_templ->debug = 0; $this->group_templ->set_file(array( *************** *** 40,44 **** 'newgroup' => "groupNew.tpl" )); ! $this->permission_templ = new Template($this->psl['templatedir']); $this->permission_templ->debug = 0; $this->permission_templ->set_file(array( --- 40,44 ---- 'newgroup' => "groupNew.tpl" )); ! $this->permission_templ = pslNew("Template",$this->psl['templatedir']); $this->permission_templ->debug = 0; $this->permission_templ->set_file(array( *************** *** 331,335 **** $this->group_templ->set_block("newgroup","section_row","section_rows"); ! $section = new Section; $section_ary = $section->getSections(); --- 331,335 ---- $this->group_templ->set_block("newgroup","section_row","section_rows"); ! $section = pslNew("Section"); $section_ary = $section->getSections(); *************** *** 439,443 **** $this->group_templ->set_block("newgroup","section_row","section_rows"); ! $section = new Section; $section_ary = $section->getSections(); --- 439,443 ---- $this->group_templ->set_block("newgroup","section_row","section_rows"); ! $section = pslNew("Section"); $section_ary = $section->getSections(); Index: Infolog.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Infolog.class,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** Infolog.class 21 Nov 2002 18:59:05 -0000 1.6 --- Infolog.class 11 Dec 2002 19:39:54 -0000 1.7 *************** *** 23,30 **** /* Start a db */ ! $this->db = new slashDB; /* Templates */ ! $this->templ = new Template($this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( --- 23,30 ---- /* Start a db */ ! $this->db = pslNew("slashDB"); /* Templates */ ! $this->templ = pslNew("Template",$this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( Index: MailingList.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/MailingList.class,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** MailingList.class 21 Nov 2002 18:59:05 -0000 1.12 --- MailingList.class 11 Dec 2002 19:39:54 -0000 1.13 *************** *** 22,29 **** $this->message = ""; /* this is where you can find the latest status */ $this->psl = $_PSL; ! $this->db = new slashDB; /* Templates */ ! $this->templ = new Template($this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( --- 22,29 ---- $this->message = ""; /* this is where you can find the latest status */ $this->psl = $_PSL; ! $this->db = pslNew("slashDB"); /* Templates */ ! $this->templ = pslNew("Template",$this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( Index: NavBar.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/NavBar.class,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** NavBar.class 23 Oct 2002 19:00:36 -0000 1.15 --- NavBar.class 11 Dec 2002 19:39:54 -0000 1.16 *************** *** 27,31 **** /* Templates */ ! $this->templ = new Template($this->psl['templatedir'], "remove"); $this->templ->debug = false; $this->templ->halt_on_error = "report"; --- 27,31 ---- /* Templates */ ! $this->templ = pslNew("Template",$this->psl['templatedir'], "remove"); $this->templ->debug = false; $this->templ->halt_on_error = "report"; Index: Poll.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Poll.class,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** Poll.class 21 Nov 2002 18:59:05 -0000 1.23 --- Poll.class 11 Dec 2002 19:39:54 -0000 1.24 *************** *** 27,31 **** */ ! $this->db = new slashDB; $this->perm = $perm; $this->psl = $_PSL; --- 27,31 ---- */ ! $this->db = pslNew("slashDB"); $this->perm = $perm; $this->psl = $_PSL; *************** *** 35,39 **** * Templates */ ! $this->templ = new Template($_PSL['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( --- 35,39 ---- * Templates */ ! $this->templ = pslNew("Template",$_PSL['templatedir']); $this->templ->debug = 0; $this->templ->set_file(array( *************** *** 395,399 **** } if ($this->psl['module']['Comment']) { ! $cmt = new Comment; $del = $cmt->delete('0',$question_id); } --- 395,399 ---- } if ($this->psl['module']['Comment']) { ! $cmt = pslNew("Comment"); $del = $cmt->delete('0',$question_id); } *************** *** 651,655 **** if ($this->psl['module']['Comment']) { ! $cmt = new Comment($ary); $comments = $cmt->getAllComments($ary); } else { --- 651,655 ---- if ($this->psl['module']['Comment']) { ! $cmt = pslNew("Comment",$ary); $comments = $cmt->getAllComments($ary); } else { Index: Section.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Section.class,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** Section.class 14 Jun 2002 20:25:32 -0000 1.11 --- Section.class 11 Dec 2002 19:39:55 -0000 1.12 *************** *** 19,28 **** global $_PSL; ! $this->db = new slashDB; $this->psl = $_PSL; $this->message = ''; /* Templates */ ! $this->sec_templ = new Template($this->psl['templatedir']); $this->sec_templ->debug = 0; $this->sec_templ->set_file(array( --- 19,28 ---- global $_PSL; ! $this->db = pslNew("slashDB"); $this->psl = $_PSL; $this->message = ''; /* Templates */ ! $this->sec_templ = pslNew("Template",$this->psl['templatedir']); $this->sec_templ->debug = 0; $this->sec_templ->set_file(array( Index: Story.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Story.class,v retrieving revision 1.46 retrieving revision 1.47 diff -C2 -d -r1.46 -r1.47 *** Story.class 24 Nov 2002 23:12:55 -0000 1.46 --- Story.class 11 Dec 2002 19:39:55 -0000 1.47 *************** *** 39,43 **** $this->Story_base(); ! // $this->db = new slashDB; $this->perm = $perm; $this->auth = $auth; --- 39,43 ---- $this->Story_base(); ! // $this->db = pslNew("slashDB"); $this->perm = $perm; $this->auth = $auth; *************** *** 57,61 **** ); ! $this->template = new Template($this->psl['templatedir'], "remove"); $this->template->debug = 0; $this->template->set_file($template_ary); --- 57,61 ---- ); ! $this->template = pslNew("Template",$this->psl['templatedir'], "remove"); $this->template->debug = 0; $this->template->set_file($template_ary); Index: Story_admin.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Story_admin.class,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** Story_admin.class 21 Nov 2002 18:59:06 -0000 1.8 --- Story_admin.class 11 Dec 2002 19:39:55 -0000 1.9 *************** *** 40,44 **** $this->Story_base(); ! // $this->db = new slashDB; $this->perm = $perm; $this->auth = $auth; --- 40,44 ---- $this->Story_base(); ! // $this->db = pslNew("slashDB"); $this->perm = $perm; $this->auth = $auth; *************** *** 58,62 **** ); ! $this->template = new Template($this->psl['templatedir'], "remove"); $this->template->debug = 0; $this->template->set_file($template_ary); --- 58,62 ---- ); ! $this->template = pslNew("Template",$this->psl['templatedir'], "remove"); $this->template->debug = 0; $this->template->set_file($template_ary); *************** *** 89,93 **** echo "The storyid is: $story_id<BR>\n"; if ($_PSL['module']['Comment']) { ! $comment = new Comment; $deleted_comments = $comment->delete("0",$story_id); echo "You deleted $deleted_comments comments<BR>\n"; --- 89,93 ---- echo "The storyid is: $story_id<BR>\n"; if ($_PSL['module']['Comment']) { ! $comment = pslNew("Comment"); $deleted_comments = $comment->delete("0",$story_id); echo "You deleted $deleted_comments comments<BR>\n"; *************** *** 125,129 **** function showStory($ary) { ! $story = new Story; $titlebar = getTitlebar("100%",$ary[title]); --- 125,129 ---- function showStory($ary) { ! $story = pslNew("Story"); $titlebar = getTitlebar("100%",$ary[title]); *************** *** 317,323 **** ! $author = new Author; ! $topic = new Topic; ! $section = new Section; $author_array = $author->getAuthors(); $topic_array = $topic->getTopics(); --- 317,323 ---- ! $author = pslNew("Author"); ! $topic = pslNew("Topic"); ! $section = pslNew("Section"); $author_array = $author->getAuthors(); $topic_array = $topic->getTopics(); Index: Story_base.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Story_base.class,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** Story_base.class 21 Nov 2002 18:59:06 -0000 1.20 --- Story_base.class 11 Dec 2002 19:39:55 -0000 1.21 *************** *** 42,46 **** */ function Story_base () { ! $this->db = new slashDB; $this->auth = $GLOBALS['auth']; $this->perm = $GLOBALS['perm']; --- 42,46 ---- */ function Story_base () { ! $this->db = pslNew("slashDB"); $this->auth = $GLOBALS['auth']; $this->perm = $GLOBALS['perm']; *************** *** 648,652 **** if ($this->psl["auto_renorm"]) { // create topic object ! $topic = new Topic; // use only the first topic in this array --- 648,652 ---- if ($this->psl["auto_renorm"]) { // create topic object ! $topic = pslNew("Topic"); // use only the first topic in this array Index: Submission.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Submission.class,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** Submission.class 21 Nov 2002 18:59:06 -0000 1.13 --- Submission.class 11 Dec 2002 19:39:55 -0000 1.14 *************** *** 9,18 **** global $_PSL; ! $this->db = new slashDB; $this->psl = $_PSL; $this->message = ''; /* Templates */ ! $this->templ = new Template($this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file ( array( --- 9,18 ---- global $_PSL; ! $this->db = pslNew("slashDB"); $this->psl = $_PSL; $this->message = ''; /* Templates */ ! $this->templ = pslNew("Template",$this->psl['templatedir']); $this->templ->debug = 0; $this->templ->set_file ( array( *************** *** 465,469 **** } else { ! $story = new Story_admin; $ary = $this->db->Record; --- 465,469 ---- } else { ! $story = pslNew("Story_admin"); $ary = $this->db->Record; Index: Topic.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Topic.class,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** Topic.class 12 Jun 2002 18:07:57 -0000 1.13 --- Topic.class 11 Dec 2002 19:39:55 -0000 1.14 *************** *** 28,32 **** global $perm, $_PSL, $amp; ! $this->db = new slashDB; $this->perm = $perm; $this->psl = $_PSL; --- 28,32 ---- global $perm, $_PSL, $amp; ! $this->db = pslNew("slashDB"); $this->perm = $perm; $this->psl = $_PSL; *************** *** 34,38 **** /* Templates */ ! $this->topic_templ = new Template($this->psl['templatedir']); $this->topic_templ->debug = 0; $this->topic_templ->set_file(array( --- 34,38 ---- /* Templates */ ! $this->topic_templ = pslNew("Template",$this->psl['templatedir']); $this->topic_templ->debug = 0; $this->topic_templ->set_file(array( *************** *** 345,349 **** function displayTopics($option="") { ! $this->topic_templ = new Template($this->psl[templatedir]); $this->topic_templ->debug = 0; $this->topic_templ->set_file(array( --- 345,349 ---- function displayTopics($option="") { ! $this->topic_templ = pslNew("Template",$this->psl[templatedir]); $this->topic_templ->debug = 0; $this->topic_templ->set_file(array( Index: TopicBar.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/TopicBar.class,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** TopicBar.class 3 Feb 2002 02:49:40 -0000 1.3 --- TopicBar.class 11 Dec 2002 19:39:55 -0000 1.4 *************** *** 19,23 **** /* Templates */ ! $this->templ = new Template($this->psl['templatedir'], "remove"); $this->templ->debug = 0; $this->templ->halt_on_error = "report"; --- 19,23 ---- /* Templates */ ! $this->templ = pslNew("Template",$this->psl['templatedir'], "remove"); $this->templ->debug = 0; $this->templ->halt_on_error = "report"; *************** *** 30,34 **** global $pagetitle; ! $db = new slashDB; $this->templ->set_var( array( --- 30,34 ---- global $pagetitle; ! $db = pslNew("slashDB"); $this->templ->set_var( array( Index: Variable.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/Variable.class,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Variable.class 18 Jun 2002 18:03:25 -0000 1.5 --- Variable.class 11 Dec 2002 19:39:55 -0000 1.6 *************** *** 25,33 **** $this->var_array['basedir'] = $_PSL['basedir']; $this->psl = $_PSL; ! $this->db = new slashDB; $this->message = ''; /* Templates */ ! $this->variable_templ = new Template($this->psl['templatedir']); $this->variable_templ->debug = 0; $this->variable_templ->set_file(array( --- 25,33 ---- $this->var_array['basedir'] = $_PSL['basedir']; $this->psl = $_PSL; ! $this->db = pslNew("slashDB"); $this->message = ''; /* Templates */ ! $this->variable_templ = pslNew("Template",$this->psl['templatedir']); $this->variable_templ->debug = 0; $this->variable_templ->set_file(array( Index: functions.inc =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/functions.inc,v retrieving revision 1.116 retrieving revision 1.117 diff -C2 -d -r1.116 -r1.117 *** functions.inc 23 Nov 2002 14:02:05 -0000 1.116 --- functions.inc 11 Dec 2002 19:39:55 -0000 1.117 *************** *** 26,30 **** /* Templates */ ! $templ = new Template($_PSL['templatedir']); if ( ($tpl != "") AND ( file_exists($_PSL['templatedir'] . "/" . basename($tpl) . ".tpl")) ) { $template = basename($tpl) . ".tpl"; --- 26,30 ---- /* Templates */ ! $templ = pslNew('Template',$_PSL['templatedir']); if ( ($tpl != "") AND ( file_exists($_PSL['templatedir'] . "/" . basename($tpl) . ".tpl")) ) { $template = basename($tpl) . ".tpl"; *************** *** 160,164 **** /* Templates */ ! $stempl = new Template($_PSL['templatedir']); $stempl->debug = 0; --- 160,164 ---- /* Templates */ ! $stempl = pslNew("Template",$_PSL['templatedir']); $stempl->debug = 0; *************** *** 196,200 **** /* Templates */ ! $templ = new Template($_PSL['templatedir']); $templ->debug = 0; --- 196,200 ---- /* Templates */ ! $templ = pslNew("Template",$_PSL['templatedir']); $templ->debug = 0; *************** *** 254,258 **** if ($sequence) { ! $sl_q = new slashDB; return $sl_q->nextid($sequence); // Destroy the object, the gc should free resources --- 254,258 ---- if ($sequence) { ! $sl_q = pslNew("slashDB"); return $sl_q->nextid($sequence); // Destroy the object, the gc should free resources *************** *** 282,286 **** $timestamp = time(); $id = generateID('psl_infolog'); ! $sl_q = new slashDB; // Deal with arrays --- 282,286 ---- $timestamp = time(); $id = generateID('psl_infolog'); ! $sl_q = pslNew("slashDB"); // Deal with arrays *************** *** 403,407 **** if (!isset($section)) { ! $block = new Block_i; // should be passing array now days if( is_array($section)) { --- 403,407 ---- if (!isset($section)) { ! $block = pslNew("Block_i"); // should be passing array now days if( is_array($section)) { *************** *** 426,430 **** } ! $templ = new Template($_PSL['templatedir']); $templ->debug = 0; --- 426,430 ---- } ! $templ = pslNew("Template",$_PSL['templatedir']); $templ->debug = 0; *************** *** 458,462 **** if ($_PSL['module']['TopicBar']) { ! $topicbar = new TopicBar; $topicbarcontent = $topicbar->getTopicBar(); } else { --- 458,462 ---- if ($_PSL['module']['TopicBar']) { ! $topicbar = pslNew("TopicBar"); $topicbarcontent = $topicbar->getTopicBar(); } else { *************** *** 465,469 **** if ($_PSL['module']['NavBar']) { ! $navbar = new NavBar; $navbarcontent = $navbar->getNavBar($navbar_ary['tpl'],$navbar_ary['menu_ary']); } else { --- 465,469 ---- if ($_PSL['module']['NavBar']) { ! $navbar = pslNew("NavBar"); $navbarcontent = $navbar->getNavBar($navbar_ary['tpl'],$navbar_ary['menu_ary']); } else { *************** *** 524,528 **** if ($_PSL['module']['NavBar']) { ! $navbar = new NavBar; $navbarcontent = $navbar->getNavBar("navbarFooter"); } else { --- 524,528 ---- if ($_PSL['module']['NavBar']) { ! $navbar = pslNew("NavBar"); $navbarcontent = $navbar->getNavBar("navbarFooter"); } else { *************** *** 544,548 **** ! $templ = new Template($_PSL['templatedir']); $templ->debug = 0; --- 544,548 ---- ! $templ = pslNew("Template",$_PSL['templatedir']); $templ->debug = 0; *************** *** 668,672 **** $as = $_PSL['amp']; if (!empty($ary['section_id'])) { ! $sec = new Section; $ary['section'] = $sec->getName($ary['section_id']); $_PSL['section'] = $ary['section']; --- 668,672 ---- $as = $_PSL['amp']; if (!empty($ary['section_id'])) { ! $sec = pslNew("Section"); $ary['section'] = $sec->getName($ary['section_id']); $_PSL['section'] = $ary['section']; *************** *** 676,685 **** if (!empty($ary['topic_id'])) { ! $top = new Topic; $ary['topic'] = $top->getName($ary['topic_id']); $_PSL['topic'] = $ary['topic']; } if (!empty($ary['author_id'])) { ! $author = new Author; $ary['author'] = $author->getName($ary['author_id']); $_PSL['author'] = $ary['author']; --- 676,685 ---- if (!empty($ary['topic_id'])) { ! $top = pslNew("Topic"); $ary['topic'] = $top->getName($ary['topic_id']); $_PSL['topic'] = $ary['topic']; } if (!empty($ary['author_id'])) { ! $author = pslNew("Author"); $ary['author'] = $author->getName($ary['author_id']); $_PSL['author'] = $ary['author']; *************** *** 694,698 **** $topic_link = ""; ! $template = new Template($_PSL['templatedir']); $template->debug = 0; $template->set_file(array( --- 694,698 ---- $topic_link = ""; ! $template = pslNew("Template",$_PSL['templatedir']); $template->debug = 0; $template->set_file(array( *************** *** 947,950 **** --- 947,951 ---- function psl_strftime($fmt,$t) { GLOBAL $_PSL; + // loadLibrary("tz"); $oldlocale = setlocale(LC_TIME,0); $locale = $_PSL['locale']['LC_TIME']; *************** *** 1197,1203 **** $default_TZ = ''; $host = ''; ! ! // debug("$fn: start",$new_tzname); ! // default: value in _PSL array. if (!empty($_PSL['timezone']['name'])) { --- 1198,1204 ---- $default_TZ = ''; $host = ''; ! ! // debug("$fn(\"$new_tzname\",\"$method\")","begin"); ! // default: value in _PSL array. if (!empty($_PSL['timezone']['name'])) { *************** *** 1273,1277 **** global $_PSL; ! $db = new slashDB; if (empty($_PSL['perm_array'])) { --- 1274,1278 ---- global $_PSL; ! $db = pslNew("slashDB"); if (empty($_PSL['perm_array'])) { *************** *** 1353,1357 **** } ! $template = new Template($_PSL['templatedir'], "remove");; $template->set_file("emailnotify",$tpl); --- 1354,1358 ---- } ! $template = pslNew("Template",$_PSL['templatedir'], "remove");; $template->set_file("emailnotify",$tpl); Index: libtz.inc =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/libtz.inc,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** libtz.inc 3 Sep 2002 15:07:36 -0000 1.1 --- libtz.inc 11 Dec 2002 19:39:56 -0000 1.2 *************** *** 24,28 **** } elseif ($_TZ['native']) { ! $tz = new tz_env($tz_name); return $tz->valid; } --- 24,28 ---- } elseif ($_TZ['native']) { ! $tz = pslNew("tz_env",$tz_name); return $tz->valid; } *************** *** 35,39 **** /* First try a file. */ ! $tz = new tz_file($tz_name); if ($tz->valid) { return true; --- 35,39 ---- /* First try a file. */ ! $tz = pslNew("tz_file",$tz_name); if ($tz->valid) { return true; *************** *** 41,50 **** else { /* OK, maybe a string */ ! $tz = new tz_posix($tz_name); if ($tz->valid) return true; else { /* We're stumped! We use the dumbest object*/ ! $tz = new tz($tz_name); $tz->error = "Can't understand time zone name: $tz_name"; return false; --- 41,50 ---- else { /* OK, maybe a string */ ! $tz = pslNew("tz_posix",$tz_name); if ($tz->valid) return true; else { /* We're stumped! We use the dumbest object*/ ! $tz = pslNew("tz",$tz_name); $tz->error = "Can't understand time zone name: $tz_name"; return false; Index: slashAuth.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/slashAuth.class,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** slashAuth.class 21 Nov 2002 18:59:06 -0000 1.8 --- slashAuth.class 11 Dec 2002 19:39:56 -0000 1.9 *************** *** 21,26 **** var $cancel_login = "cancel"; var $mode = "log"; ! /** * --- 21,32 ---- var $cancel_login = "cancel"; var $mode = "log"; + var $debug = true; ! function debug($msg,$val) { ! if ($this->debug) { ! debug($msg,$val); ! } ! } ! /** * *************** *** 31,35 **** global $_PSL; ! $templ = new Template($_PSL['templatedir']); $templ->set_file(array( 'form' => "loginform.tpl" --- 37,41 ---- global $_PSL; ! $templ = pslNew("Template",$_PSL['templatedir']); $templ->set_file(array( 'form' => "loginform.tpl" *************** *** 67,70 **** --- 73,78 ---- **/ function auth_validatelogin() { + $fn = "slashAuth::auth_validatelogin()"; + $this->debug($fn,"begin"); global $HTTP_POST_VARS; *************** *** 96,102 **** AND password = '$md5_pw_net'"; ! echo "Query: $q\n"; ! $this->db->query($q); while ($this->db->next_record()) { $uid = $this->db->f("author_id"); --- 104,111 ---- AND password = '$md5_pw_net'"; ! $this->debug("$fn:query",$q); $this->db->query($q); + $this->debug("$fn:numrows",$this->db->num_rows()); + while ($this->db->next_record()) { $uid = $this->db->f("author_id"); Index: slashAuthCR.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/slashAuthCR.class,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** slashAuthCR.class 4 Dec 2002 19:51:25 -0000 1.33 --- slashAuthCR.class 11 Dec 2002 19:39:56 -0000 1.34 *************** *** 24,29 **** var $psl; function slashAuth() { ! global $_PSL; --- 24,30 ---- var $psl; + function slashAuth() { ! global $_PSL; *************** *** 31,34 **** --- 32,50 ---- $this->magic = $_PSL['magic']; } + $this->loadClasses("database_class"); + } + + /** + * customizes class names and loads the class definitions + * + * @param string classnames (as many as you want) + * @return void + */ + function loadClasses() { + $arr = func_get_args(); + foreach($arr as $class) { + $this->$class = pslGetClass($this->$class); + loadClass($this->$class); + } } *************** *** 83,87 **** } ! $templ = new Template($_PSL['templatedir']); $templ->set_file(array( 'form' => "loginformCR.tpl" --- 99,103 ---- } ! $templ = pslNew("Template",$_PSL['templatedir']); $templ->set_file(array( 'form' => "loginformCR.tpl" *************** *** 184,190 **** } else if ($this->nobody) { $uid = $this->auth["uid"] = "nobody"; ! $aid = Author::getId($uid); ! $this->auth["perm"] = $this->get_userperms($aid); ! $this->auth["dname"] = Author::getRealName($aid); $this->auth["email"] = ''; return $aid; --- 200,207 ---- } else if ($this->nobody) { $uid = $this->auth["uid"] = "nobody"; ! loadClass('Author'); ! $aid = Author::getId($uid); ! $this->auth["perm"] = $this->get_userperms($aid); ! $this->auth["dname"] = Author::getRealName($aid); $this->auth["email"] = ''; return $aid; *************** *** 245,249 **** if( $lostpw) { ! $author = new Author; $ary['username'] = $username; $success = $author->lostpw($ary); --- 262,266 ---- if( $lostpw) { ! $author = pslNew("Author"); $ary['username'] = $username; $success = $author->lostpw($ary); *************** *** 343,347 **** global $sess; ! $templ = new Template($this->psl['templatedir']); $templ->set_file(array( form => "registerform.tpl" --- 360,364 ---- global $sess; ! $templ = pslNew("Template",$this->psl['templatedir']); $templ->set_file(array( form => "registerform.tpl" *************** *** 463,467 **** // add new user ! $author = new Author; $ary["author_name"] = $username; $ary["password"] = $pass1; --- 480,484 ---- // add new user ! $author = pslNew("Author"); $ary["author_name"] = $username; $ary["password"] = $pass1; *************** *** 524,528 **** FROM psl_group_section_lut WHERE group_id = '$group_id' "; ! $db2 = new slashDB; $db2->query($q); while ($db2->next_record()) { --- 541,545 ---- FROM psl_group_section_lut WHERE group_id = '$group_id' "; ! $db2 = pslNew("slashDB"); $db2->query($q); while ($db2->next_record()) { *************** *** 574,578 **** AND psl_group_permission_lut.group_id = '$childgroup_id' "; // debug("q", $q); ! $db2 = new slashDB; $db2->query($q); --- 591,595 ---- AND psl_group_permission_lut.group_id = '$childgroup_id' "; // debug("q", $q); ! $db2 = pslNew("slashDB"); $db2->query($q); *************** *** 583,587 **** FROM psl_group_section_lut WHERE group_id = '$group_id' "; ! $db3 = new slashDB; $db3->query($q); while ($db3->next_record()) { --- 600,604 ---- FROM psl_group_section_lut WHERE group_id = '$group_id' "; ! $db3 = pslNew("slashDB"); $db3->query($q); while ($db3->next_record()) { Index: slashSess.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/slashSess.class,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** slashSess.class 8 Feb 2002 18:54:04 -0000 1.2 --- slashSess.class 11 Dec 2002 19:39:56 -0000 1.3 *************** *** 18,21 **** --- 18,121 ---- var $that_class = "slash_sql"; // The db object to use var $allowcache = "no"; // We dont cache data here + + /** + * @var string serialized session data + */ + var $serSessData = ''; + + /** + * customizes class names and loads the class definitions + * + * @param string classnames (as many as you want) + * @return void + */ + function loadClasses() { + $arr = func_get_args(); + foreach($arr as $class) { + $this->$class = pslGetClass($this->$class); + loadClass($this->$class); + } + } + + function slashSess() { + $this->loadClasses("that_class"); + } + + + /** + * appends a serialized representation of $$var at the end of $str. + * + * In the PHP3 version of PHPLIB, it was necessary to set methods + * $classname and $persistent_slots to serialize an object. Not + * necessary for PHP4. + * + * uses the pslNew function instead of the new language construct, so + * that class files can be loaded on-the-fly. Otherwise the same as + * the PHPLIB session::serialize function. + * + * However, with the new freeze and thaw functions, this is called + * only certain members of this session object. + * + * @param @string name of the variable to be serialized + * @param @string string onto which serialized code gets appended. + **/ + + function serialize($var, &$str) { + static $t,$l,$k; + + /** + * Determine the type of $$var + * + * eval'd code is necessary because the $var gets complicated...not + * just names of simple global variables. + **/ + eval("\$t = gettype(\$$var);"); + switch ( $t ) { + + case "array": + ## $$var is an array. Enumerate the elements and serialize them. + eval("reset(\$$var); \$l = gettype(list(\$k)=each(\$$var));"); + $str .= "\$$var = array();\n "; + while ( "array" == $l ) { + ## Structural recursion + $this->serialize($var."['".ereg_replace("([\\'])", "\\\\1", $k)."']", $str); + eval("\$l = gettype(list(\$k)=each(\$$var));"); + } + + break; + case "object": + // $$var is an object. Enumerate the slots and serialize them. + eval(" + if (empty(\${$var}->classname)) { + \$k = get_class(\${$var}); + } else { + \$k = \${$var}->classname; + }"); + eval(" + if (empty(\${$var}->persistent_slots)) { + \$members = array_keys(get_object_vars(\${$var})); + } else { + \$members = \${$var}->persistent_slots; + }"); + $str.="\$$var = pslNew('$k');\n "; + foreach($members as $mName) { + // Structural recursion. + $this->serialize($var."->".$mName, $str); + } + + break; + default: + ## $$var is an atom. Extract it to $l, then generate code. + eval("\$l = \$$var;\n"); + $str.="\$$var = '".ereg_replace("([\\'])", "\\\\1", $l)."';\n "; + break; + } + } + + } + + + + ?> Index: slash_sql.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/slash_sql.class,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** slash_sql.class 12 Dec 2001 11:39:10 -0000 1.2 --- slash_sql.class 11 Dec 2002 19:39:56 -0000 1.3 *************** *** 9,12 **** --- 9,35 ---- var $database_class = "slashDB"; var $database_table = "active_sessions"; + + /** + * customizes class names and loads the class definitions + * + * @param string classnames (as many as you want) + * @return void + */ + function loadClasses() { + $arr = func_get_args(); + foreach($arr as $class) { + $this->$class = pslGetClass($this->$class); + loadClass($this->$class); + } + } + + /** + * constructor + */ + function slash_sql() { + $this->loadClasses("database_class"); + } + } + ?> Index: tz.class =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/tz.class,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** tz.class 3 Sep 2002 15:06:08 -0000 1.1 --- tz.class 11 Dec 2002 19:39:56 -0000 1.2 *************** *** 224,228 **** function get_select_form($action_url='',$method='GET') { $action_url || $action_url = $GLOBALS['HTTP_SERVER_VARS']['PHP_SELF']; ! $tpl = new Template($this->templatedir); // $tpl->debug=true; $tpl->set_file('form','tz_form_native.tpl'); --- 224,228 ---- function get_select_form($action_url='',$method='GET') { $action_url || $action_url = $GLOBALS['HTTP_SERVER_VARS']['PHP_SELF']; ! $tpl = pslNew("Template",$this->templatedir); // $tpl->debug=true; $tpl->set_file('form','tz_form_native.tpl'); *************** *** 341,345 **** function get_confirm_form($ary,$accept_url="",$reject_url='') { $reject_url || $reject_url = $GLOBALS['HTTP_SERVER_VARS']['PHP_SELF']; ! $tpl = new Template($this->templatedir); $tpl->set_file('form','tz_form_confirm.tpl'); $tpl->set_file('current_time','tz_show.tpl'); --- 341,345 ---- function get_confirm_form($ary,$accept_url="",$reject_url='') { $reject_url || $reject_url = $GLOBALS['HTTP_SERVER_VARS']['PHP_SELF']; ! $tpl = pslNew("Template",$this->templatedir); $tpl->set_file('form','tz_form_confirm.tpl'); $tpl->set_file('current_time','tz_show.tpl'); Index: tz_functions.inc =================================================================== RCS file: /cvsroot/phpslash/phpslash-ft/class/tz_functions.inc,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** tz_functions.inc 3 Sep 2002 15:06:08 -0000 1.1 --- tz_functions.inc 11 Dec 2002 19:39:56 -0000 1.2 *************** *** 24,28 **** } elseif ($_TZ['native']) { ! $tz = new tz_env($tz_name); return $tz->valid; } --- 24,28 ---- } elseif ($_TZ['native']) { ! $tz = pslNew("tz_env",$tz_name); return $tz->valid; } *************** *** 35,39 **** /* First try a file. */ ! $tz = new tz_file($tz_name); if ($tz->valid) { return true; --- 35,39 ---- /* First try a file. */ ! $tz = pslNew("tz_file",$tz_name); if ($tz->valid) { return true; *********... [truncated message content] |