Loading...
 

Image Directory Revamp

Tiki img directory consolidation.

Revamp finished and part of Tiki9

Goal

  • Stage 1: to have a clean, organized structure to find things where they are expected - DONE
  • Stage 2: delete unnecessary, unused files - partly DONE, still many unused files left

Timeline

  • lets agree first on how it should be, than figure out how to do
  • March 2nd - 4th: make it happen for Tiki9 (trunk now)
  • Document the changes made: Update docs for Tiki 9 -> Tiki9

Number of references in all the files

Some grepping stats (revision 39998 after clearing Tiki cache):

luci@w7-vbox-ubuntu:/var/www/tikitrunk$ grep -Ro --exclude-dir=\.svn 'img\/' * | wc -l
1029
luci@w7-vbox-ubuntu:/var/www/tikitrunk$ grep -Ro --exclude-dir=\.svn 'images\/' * | wc -l
1448
luci@w7-vbox-ubuntu:/var/www/tikitrunk$ grep -Ro --exclude-dir=\.svn 'pics\/' * | wc -l
4574

Revamped img dir structure proposal

  • img/
    • img/avatars/
    • img/flags/
    • img/icons/
    • img/smiles/
    • img/tiki/
    • img/trackers/
    • img/webmail/
    • img/wiki/
    • img/wiki_up/

Issues / Questions / Concerns

  • things might get temporarily broken in trunk but on the long run we should get through this
  • afraid if the “icon themes” override functionality will be preserved (see for example Strasa theme) — luci
  • what happens if there is wiki page created named “images” and rewrite rules are on via .htaccess - it is very possible case. Will the images be still readable or broken ? would not it be better to use the img dir or pics dir instead ? — luci
    • OK. Just tried and it reveals, that if one creates page named “Images”, he/she cannot access the created page after save using the SEFURL, because Tiki thinks it is the images/ dir and there is the index.php redirect to Tiki index page. — luci
      • luci: Only one problem remains with the images dir - now when it is gone i would expect that my test wiki page named “images” will be working but i get error instead redirecting me from http://localhost/tikitrunk/images to http://localhost/tikitrunk/images/ and the error is: “Page not found images/” and the theme is completely broken
        • gezza: on my localhost with SefURL on “tikitrunk/images” is being displayed fine
  • just spotted it: what about lib/images/icons/ ? — luci
  • known issue - Xavi reported his custom icons use old paths to pics/ and he gets PHP error now - will need php upgrade script created in installer/schema/ to replace the paths in tiki_preferences tool_icon

Things to Check

  • Now we have just some things to check remaining:
    • rewrite rules in .htaccess
    • is there any Tiki 9 specific profile using the old paths on http://profiles.tiki.org?
    • is there any Theme on themes.tiki.org using the old paths?
    • are there any possible use cases causing trouble after upgrade?
      • custom toolbar icons created at /tiki-admin_toolbars.php get broken after update if they point to the legacy pics/icons folder. Related data is stored in tiki_preferences table with pref name tool_icons.
    • does fresh install work fine?

Overview

Current pathCurrent number of picsProposalDone in trunk
EXISTING DIRECTORIES
/images87move to /imgYes
/img26leave as it isYes
/img/avatars0leave as it isYes
/img/flags252leave as it isYes
/img/graph4move files to /img and DELETEYes
/img/icn34DELETEYes
/img/icons310leave as it isYes
/img/icons2164move files to /img/icons and DELETEYes
/img/mytiki16move files to /img/icons/large/ and DELETEYes
/img/smiles24leave as it isYes
/img/tiki7leave as it isYes
/img/trackers0leave as it isYes
/img/webmail14leave as it isYes
/img/wiki0leave as it isYes
/img/wiki_up0leave as it isYes
/pics6move to /img/ and DELETEYes
/pics/icons212move to /img/iconsYes
/pics/icons/mime39move to /img/icons/mime and DELETEYes
/pics/large111move to /img/icons/large and DELETEYes
/pics/sprite2move to /img/icons/sprite and DELETEYes

Important files to check

./lib/init/smarty.php:26:			'styles/strasa/pics/icons/',
./lib/init/smarty.php:27:			'styles/coelesce/pics/icons/',
./lib/init/smarty.php:28:			'styles/darkroom/pics/icons/',
./lib/init/smarty.php:29:			'styles/thenews/pics/icons/',
./lib/init/smarty.php:30:			'styles/tikinewt/pics/icons/',
./lib/init/smarty.php:31:			'styles/twist/pics/icons/',
./lib/init/smarty.php:38:			'pics/',
./lib/init/smarty.php:39:			'pics/icons',
./lib/init/smarty.php:40:			'pics/icons/mime',
./lib/init/smarty.php:41:			'pics/large',
./lib/prefs/menus.php:20:			'default' => 'pics/large',
./lib/smarty_tiki/function.icon.php:58:	$basedirs = array('pics/icons', 'images', 'img/icons', 'pics/icons/mime');
./lib/smarty_tiki/function.icon.php:71:		if ( isset($params['_defaultdir']) && $params['_defaultdir'] == 'pics/large' ) {
./lib/smarty_tiki/function.icon.php:79:		if ( $params['_defaultdir'] == 'pics/large' ) {

./lib/smarty_tiki/modifier.iconify.php 29: 	$icon = file_exists("pics/icons/mime/$ext.png") ? $ext : 'default';

33: '_id' => 'pics/icons/mime/'.$icon.'.png',

Change description

File system changes

r39999 - r40040

DB changes

No change

Background information

[+]

Alias

Keywords

The following is a list of keywords that should serve as hubs for navigation within the Tiki development and should correspond to documentation keywords.

Each feature in Tiki has a wiki page which regroups all the bugs, requests for enhancements, etc. It is somewhat a form of wiki-based project management. You can also express your interest in a feature by adding it to your profile. You can also try out the Dynamic filter.

Accessibility (WAI & 508)
Accounting 7.x
Administration
Ajax 2.x
Articles & Submissions
Backlinks
Banner
Batch 6.x
BigBlueButton audio/video/chat/screensharing (5.x)
Blog
Bookmark
Browser Compatibility
Calendar
Category
Chat
Comment
Communication Center
Consistency
Contacts Address book
Contact us
Content template
Contribution 2.x
Cookie
Copyright
Credits 6.x
Custom Home (and Group Home Page)
Database MySQL - MyISAM
Database MySQL - InnoDB
Date and Time
Debugger Console
Directory (of hyperlinks)
Documentation link from Tiki to doc.tiki.org (Help System)
Docs 8.x
DogFood
Draw 7.x
Dynamic Content
Preferences
Dynamic Variable
External Authentication
FAQ
Featured links
Feeds (RSS)
File Gallery
Forum
Friendship Network (Community)
Group
Help
History
Hotword
HTML Page
i18n (Multilingual, l10n, Babelfish)
Image Gallery
Import-Export
Install
Integrator
Interoperability
Inter-User Messages
InterTiki
jQuery
Kaltura video management
Karma
Live Support
Logs (system & action)
Lost edit protection
Mail-in
Map
Menu
Meta Tag
Missing features
Visual Mapping 3.x
Mobile Tiki and Voice Tiki
Mods
Modules
MultiTiki
MyTiki
Newsletter
Notepad
OS independence (Non-Linux, Windows/IIS, Mac, BSD)
Organic Groups (Self-managed Teams)
Payment 5.x
Performance Speed / Load / Compression / Cache
Permission
Poll
Profiles
Quiz
Rating
Realname
Report
Revision Approval
Score
Search engine optimization (SEO)
Search
Security
Semantic links 3.x
Share
Shopping Cart 5.x
Shoutbox
Site Identity
Slideshow
Smarty Template
Social Networking
Spam protection (Anti-bot CATPCHA)
Spellcheck
Spreadsheet
Staging and Approval
Stats
Survey
Syntax Highlighter (Codemirror)
Tablesorter
Tags 2.x
Task
Tell a Friend, alert + Social Bookmarking
Terms and Conditions
Theme
TikiTests 2.x
Timesheet
Token Access
Toolbar (Quicktags)
Tours
Trackers
TRIM
User Administration
User Files
User Menu
Watch
WebHelp
Webmail and Groupmail
WebServices 3.x
Wiki 3D
Wiki History, page rename, etc
Wiki plugins extends basic syntax
Wiki syntax text area, parser, etc
Wiki structure (book and table of content)
Workspace and perspectives 4.x
WYSIWTSN 4.x
WYSIWYCA
WYSIWYG 2.x
XMLRPC




Useful Tools