News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Resetting Forum...

Started by Kindred, February 14, 2012, 01:17:08 PM

Previous topic - Next topic

NiceLittleMonkey

Kindred, as per our conversation in my other thread I just prepared a test_reset.zip package and corrected the path from...:

zip_extract('test_reset.zip','/home/turtleshell/www/test/');

...to:

zip_extract('test_reset.zip','C:/wamp/www/rcforum/');

When I run it on my Windows desktop on a local WAMP server I get the following error and looking at the smf files none of them has been changed:

QuoteThis script resets all files to the default installation from the file "test_reset.zip" (which is a pared down version of the "Large Upgrade Package" from SMF.)
This script will also remove all installed themes other than the default, reset all packages to "not installed" and reset all member options to the default settings for the default theme.
Remember: This will not remove any mod DATA from the database, nor will it delete the mod-specific FILES

Resetting error logs

Resetting installed packages

Finding and removing all themes except for the default theme (Curve)

Removing (2) Core Theme
from /var/www/web16/web/Themes/core

( ! ) SCREAM: Error suppression ignored for
( ! ) Fatal error: Call to undefined function deltree() in C:\wamp\www\rcforum\reset_site_21.php on line 77
Call Stack
#   Time   Memory   Function   Location
1   0.0005   732616   {main}( )   ..\reset_site_21.php:0

The error...:

SCREAM: Error suppression ignored for

...seem to go away if I change the path to...:

zip_extract('test_reset.zip','C:\wamp\www\rcforum\');

...but this error remains:

( ! ) Fatal error: Call to undefined function deltree() in C:\wamp\www\rcforum\reset_site_21.php on line 77
Call Stack
# Time Memory Function Location
1 0.0006 732984 {main}( ) ..\reset_site_21.php:0


Any suggestions, please?  :)



Kindred

ummm... yeah.

I built the script for linux/apache servers...

Windows uses the other-way slashes... and apparently doesn't like the deltree command.
hrmm...
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Arantor

Does the script include Subs-Package.php? That's where deltree() is stored. Perhaps it's an older version of SMF that has it somewhere else/does something different.

And actually, PHP on Windows doesn't care too much about the different slashes.

Kindred

hmmm... interesting on the slashes. I've had nothing but trouble  with them between windows and linux.

wel, my script includes SSI in order to get paths and use the smfFunc parsing

I thought deltree was a standard php command anyway...



BTW: Removed my specific path...  corrected to use the defained variable $reset_path instead
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

NiceLittleMonkey

Must be some kind of restriction on the Linux server where one of my sites are hosted. Getting these errors when running your script:

[Fri Feb 15 19:14:34 2013] [error] [client 93.163.xxx.xxx] File does not exist: /var/www/web117/web/repair_settings.php
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.english.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.english.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.english.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/index.template.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 1869
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/index.english.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/index.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Modifications.english.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Modifications.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/index.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/index.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Modifications.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Modifications.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Optimus.english.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Optimus.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Optimus.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Optimus.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/Optimus.english.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 2002
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/Scrolling.template.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 1869
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/css/portal.css) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 1852
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/images/sp) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Subs-Portal.php on line 114
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/Portal.template.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Load.php on line 1869
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Subs-Portal.php on line 813
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Warning:  file_exists() [function.file-exists]: open_basedir restriction in effect. File(/var/www/web16/web/Themes/core/languages/SPortal.danish-utf8.php) is not within the allowed path(s): (/var/www/web117) in /var/www/web117/web/Sources/Subs-Portal.php on line 813
[Fri Feb 15 19:14:36 2013] [error] [client 93.163.xxx.xxx] PHP Fatal error:  Call to undefined function deltree() in /var/www/web117/web/reset_site_21.php on line 77

Arantor

Eh, it's not configured properly

/var/www/web16 is one site, /var/web/117 is another. One is not allowed to access the files of the other. That's what the error is telling you.

The script is trying to clean up /var/www/web16 but it's running from within /var/www/web117

NiceLittleMonkey

#26
Yeah, I see that now. Sorry...  :P

.

NiceLittleMonkey

Kindred > I have a question for you, but first an explanation:

The forum was "reset" manually by deleting almost all files (except settings.php and .bak) from the www folder and uploading the files from the large upgrade package (minus upgrade.php and *.sql). Then all the mod tables in the database were removed manually as well. The database list no installed Packages either and all database maintenance task are working. The forum is up and running perfectly now, so that's good.

Looking through your fine script (and maybe only really understanding about 50% of it :-[ ) I was wondering if the script could be modified to only remove  hooks for the removed mods and nothing else? I should mention that before the "reset" we used the Core Theme, and after the "reset" I switched to the Curve Default Theme and even deleted the Core Theme:

echo 'Remove any hooks for the removed mods<br /><br />';
  $integrate_columns = array('integrate_actions', 'integrate_admin_areas', 'integrate_bbc_buttons', 'integrate_bbc_codes', 'integrate_core_features', 'integrate_load_permissions', 'integrate_menu_buttons', 'integrate_pre_include', 'integrate_profile_areas');
  foreach ($integrate_columns as $column)
    $request = $smcFunc['db_query']('', 'DELETE FROM {db_prefix}settings WHERE variable LIKE {string:variable}', array('variable' => $column));
 


Is there still a need to clean up any hooks or is that not important now that the theme has changed?



Kindred

#28
yes... the hooks are stored in the "settings" table,


You can manually look for anything in that table with a name LIKE %integrate% and remove them...
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Arantor

Since when have any hooks ever been in the themes table?

Kindred

argh.... not enough sleep....   the settings table. corrected the original response.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

NiceLittleMonkey

#31
Thank you, Gentlemen. So, I looked through the smf_settings table (SELECT * FROM `smf_settings`;) and could immediately see a lot of fields from different mods and packages installed over time and also the %integrate% hooks you mentioned.

If I understand you correctly, I can simply compare the content of my forum smf_settings table to the content of a freshly installed smf_settings table and delete what should not be there?:


smfVersion;2.0.2
news;
enotify_life;15000
compactTopicPagesContiguous;7
compactTopicPagesEnable;1
enableStickyTopics;1
todayMod;2
karmaMode;0
karmaTimeRestrictAdmins;1
enablePreviousNext;1
pollMode;1
enableVBStyleLogin;1
enableCompressedOutput;1
karmaWaitTime;1
karmaMinPosts;0
karmaLabel;Karma:
karmaSmiteLabel;[smite]
karmaApplaudLabel;[applaud]
attachmentSizeLimit;1
attachmentPostLimit;1
attachmentNumPerPostLimit;1
attachmentDirSizeLimit;1
attachmentUploadDir;/var/www/web16/web/attachments
attachmentExtensions;gif,jpg,png
attachmentCheckExtensions;1
attachmentShowImages;1
attachmentEnable;0
attachmentEncryptFilenames;1
attachmentThumbnails;1
attachmentThumbWidth;250
attachmentThumbHeight;250
censorIgnoreCase;1
mostOnline;55
mostOnlineToday;17
mostDate;1340567552
allow_disableAnnounce;1
trackStats;1
userLanguage;1
titlesEnable;0
topicSummaryPosts;15
enableErrorLogging;1
max_image_width;800
max_image_height;800
onlineEnable;1
cal_enabled;
cal_maxyear;2020
cal_minyear;2008
cal_daysaslink;0
cal_defaultboard;36
cal_showholidays;0
cal_showbdays;2
cal_showevents;2
cal_showweeknum;0
cal_maxspan;7
smtp_host;
smtp_port;25
smtp_username;
smtp_password;
mail_type;0
timeLoadPageEnable;0
totalMembers;133
totalTopics;373
totalMessages;4074
simpleSearch;0
censor_vulgar;
censor_proper;
enablePostHTML;1
theme_allow;0
theme_default;1
theme_guests;1
enableEmbeddedFlash;1
xmlnews_enable;1
xmlnews_maxlen;255
hotTopicPosts;20
hotTopicVeryPosts;30
registration_method;1
send_validation_onChange;1
send_welcomeEmail;1
allow_editDisplayName;1
allow_hideOnline;1
guest_hideContacts;1
spamWaitTime;5
pm_spam_settings;100,0,60
reserveWord;0
reserveCase;0
reserveUser;1
reserveName;1
reserveNames;Admin
Webmaster
Moderator
Guest
root
Bot
rcforum
RCForum
rc-forum
RC-Forum
Administrator
autoLinkUrls;1
banLastUpdated;1339858402
smileys_dir;/var/www/web16/web/Smileys
smileys_url;http://rc-forum.dk/Smileys
avatar_directory;/var/www/web16/web/avatars
avatar_url;http://rc-forum.dk/avatars
avatar_max_height_external;160
avatar_max_width_external;160
avatar_action_too_large;option_html_resize
avatar_max_height_upload;160
avatar_max_width_upload;160
avatar_resize_upload;1
avatar_download_png;1
failed_login_threshold;10
oldTopicDays;120
edit_wait_time;120
edit_disable_time;0
autoFixDatabase;1
allow_guestAccess;1
time_format;%d-%m-%Y, %H:%M:%S
number_format;1234.00
enableBBC;1
max_messageLength;20000
signature_settings;1,300,8,2,5,990,200,0:abbr,acronym,anchor,bdo,black,blue,code,code,flash,ftp,ftp,glow,green,html,hr,iurl,iurl,li,list,list,ltr,me,move,nobbc,php,pre,rtl,s,shadow,sub,sup,table,td,time,tr,tt,u,white
autoOptMaxOnline;0
defaultMaxMessages;15
defaultMaxTopics;20
defaultMaxMembers;50
enableParticipation;1
recycle_enable;1
recycle_board;5
maxMsgID;4399
enableAllMessages;100
fixLongWords;0
knownThemes;1
who_enabled;1
time_offset;0
cookieTime;60
lastActive;30
smiley_sets_known;default,aaron,akyhne
smiley_sets_names;Alienine's Set
Aaron's Set
Akyhne's Set
smiley_sets_default;default
cal_days_for_index;365
requireAgreement;1
unapprovedMembers;0
default_personal_text;
package_make_backups;1
databaseSession_enable;1
databaseSession_loose;1
databaseSession_lifetime;2880
search_cache_size;50
search_results_per_page;30
search_weight_frequency;30
search_weight_age;25
search_weight_length;20
search_weight_subject;15
search_weight_first_message;10
search_max_results;150
search_floodcontrol_time;15
permission_enable_deny;0
permission_enable_postgroups;0
mail_next_send;0
mail_recent;0000000000|0
settings_updated;1361089678
next_task_time;1361095200
warning_settings;0,20,0
password_strength;0
admin_features;cp,sp
last_mod_report_action;1361089175
pruningOptions;30,180,180,180,30,0
cache_enable;1
reg_verification;1
visual_verification_type;0
enable_buddylist;1
birthday_email;nite0859
dont_repeat_theme_core;1
dont_repeat_smileys_20;1
dont_repeat_buddylists;1
attachment_image_reencode;1
attachment_image_paranoid;0
attachment_thumb_png;0
avatar_reencode;0
avatar_paranoid;0
global_character_set;UTF-8
default_timezone;Europe/Copenhagen
memberlist_updated;1361024445
latestMember;150
latestRealName;Per O
rand_seed;1848281352
mostOnlineUpdated;2013-02-17
notify_new_registration;1
calendar_updated;1361089116
gallery_max_height;1600
gallery_max_width;1600
gallery_min_height;0
gallery_min_width;0
gallery_max_filesize;524288
gallery_who_viewing;0
gallery_set_commentsnewest;1
gallery_commentchoice;1
gallery_resize_image;1
gallery_set_count_child;1
gallery_show_ratings;1
gallery_index_recent;1
gallery_index_mostviewed;1
gallery_index_toprated;0
gallery_index_mostcomments;1
gallery_set_images_per_page;100
gallery_set_images_per_row,;4
gallery_thumb_width;200
gallery_thumb_height;200
gallery_set_t_views;1
gallery_set_t_filesize;1
gallery_set_t_date;1
gallery_set_t_comment;1
gallery_set_t_username;1
gallery_set_t_rating;0
gallery_jpeg_compression;80
gallery_index_showtop;0
gallery_set_cat_width;120
gallery_set_cat_height;120
gallery_set_show_quickreply;1
gallery_set_img_size;0
gallery_set_img_prevnext;1
gallery_set_img_desc;0
gallery_set_img_title;0
gallery_set_img_views;1
gallery_set_img_poster;1
gallery_set_img_date;1
gallery_set_img_showfilesize;0
gallery_set_img_showrating;0
gallery_set_img_keywords;0
gallery_set_water_enabled;0
gallery_set_water_image;
gallery_set_water_percent;0
gallery_set_water_text;
gallery_set_water_textcolor;#FFFFFF
gallery_set_water_halign;right
gallery_set_water_valign;bottom
gallery_index_showusergallery;1
gallery_shop_commentadd;0
gallery_shop_picadd;0
gallery_set_t_title;1
gallery_set_showcode_bbc_image;0
gallery_set_showcode_directlink;1
gallery_set_showcode_htmllink;0
gallery_set_nohighslide;2
gallery_set_disp_maxwidth;800
gallery_set_disp_maxheight;800
gallery_set_water_textfont;Forgottb.ttf
gallery_set_water_textsize;50
gallery_set_enable_multifolder;1
gallery_folder_id;1
gallery_setviewscountonce;1
gallery_ratings_require_comment;0
gallery_user_no_password;1
gallery_user_no_private;1
gallery_allow_mature_tag;0
gallery_make_medium;0
gallery_medium_width;600
gallery_medium_height;600
gallery_set_images_per_row;4
gallery_import_tag;1
spider_name_cache;a:19:{i:1;s:6:"Google";i:2;s:6:"Yahoo!";i:3;s:3:"MSN";i:4;s:15:"Google (Mobile)";i:5;s:14:"Google (Image)";i:6;s:16:"Google (AdSense)";i:7;s:16:"Google (Adwords)";i:8;s:15:"Yahoo! (Mobile)";i:9;s:14:"Yahoo! (Image)";i:10;s:12:"MSN (Mobile)";i:11;s:11:"MSN (Media)";i:12;s:4:"Cuil";i:13;s:3:"Ask";i:14;s:5:"Baidu";i:15;s:9:"Gigablast";i:16;s:15:"InternetArchive";i:17;s:5:"Alexa";i:18;s:6:"Omgili";i:19;s:9:"EntireWeb";}
class_ipn_disable_price_security;1
disabled_profile_fields;icq,msn,aim,yim,gender,website,warning_status
registration_fields;location
search_pointer;6
cal_allow_unlinked;1
cal_allowspan;1
queryless_urls;1
search_enable_captcha;0
guests_report_require_captcha;0
disableHostnameLookup;1
countChildPosts;1
class_sandbox;0
class_set_title;Classifieds
class_set_thumb_height;200
class_set_thumb_width;200
class_set_listings_per_page;50
class_set_count_child;0
class_set_commentsnewest;1
class_set_whosviewing;1
class_set_contact_email;[email protected]
class_set_copy_sales_email;1
class_set_t_picture;1
class_set_t_price;1
class_set_t_date;0
class_set_t_comment;0
class_set_paypal;
class_set_whoisviewing;0
class_hash;Jun:04:09:0510571
class_catlist_postedby;1
class_catlist_showimage;1
class_catlist_currentprice;0
class_catlist_numofbids;0
class_catlist_listingdate;1
class_catlist_listingend;1
class_catlist_comments;1
class_catlist_views;1
class_catlist_timeleft;0
class_d_listing_numofbids;0
class_d_listing_listingdate;1
class_d_listing_reserve;0
class_d_listing_timeleft;0
class_d_listing_views;0
class_d_listing_keywords;0
class_d_listing_numpicstoshow;10
class_index_recent;1
class_index_mostviewed;1
class_index_mostcomments;0
class_index_featured;0
class_index_showtop;0
class_set_currency;DKK
class_max_height;1600
class_max_width;1600
class_max_filesize;524288
class_hidebidhistory;1
class_expireremove;1
class_hidebidhistory_all;0
class_setviewscountonce;1
class_showrss_bycat;0
class_set_snipebid_minutes;0
class_set_snipebid_minutes_add;5
class_d_listing_timeleft2;1
class_set_listing_owners_viewers;0
class_set_index_no_subcats;0
class_set_date_format_mdy;d/m/Y
class_set_date_format_hia;h
class_set_allow_remote_images;1
class_set_allow_members_to_delete_listings;1
class_set_require_price;0
class_set_auto_recycle_listing_ended;1
class_set_auto_recycle_auction_ended;1
class_set_auto_accept_bid;0
class_set_intergrate_boardindex;1
class_set_hide_paypal_fields;1
class_set_show_cat_latest_listings;0
class_index_show_recent_items_comments;10
class_index_show_recent_bids;0
class_index_show_recent_bids_items;10
class_set_trader_feedback;0
class_set_cloud_tags_per_row;5
class_set_cloud_tags_to_show;50
class_set_cloud_max_font_size_precent;250
class_set_cloud_min_font_size_precent;100
class_index_show_tag_cloud;0
class_set_resize_image;1
class_share_addthis;0
class_share_twitter;0
class_share_facebook;1
class_set_water_enabled;1
class_set_water_image;http://www.rc-forum.dk
class_set_water_percent;0
class_set_water_text;RC-Forum.dk
class_set_water_textcolor;#FFFFFF
class_set_water_halign;right
class_set_water_valign;bottom
class_set_water_textfont;Forgottb.ttf
class_set_water_textsize;45
class_set_allow_creditsystem;0
class_set_default_pic_id;36
class_set_layout_simplehomepage;1
class_share_googleplus;0
class_index_block_items;4
class_set_hidesendfriend;0
class_import_tag;1
class_nextcheck;1360954225
search_index;fulltext
search_force_index;1
qa_verification_number;1
recaptcha_theme;clean
recaptcha_enabled;0
class_index_show_recent_comments;0
number_recent_topics;50
number_recent_topics_interval;10
integrate_admin_areas;Tapatalk_add_admin_areas,optimus_admin_areas
integrate_modify_modifications;
enable_transparent_avatars;1
avatar_transparency_level;25
trader_approval;0
trader_feedbackperpage;10
trader_use_pos_neg;0
trader_membergroupspm;1
integrate_pre_include;$sourcedir/Subs-Tapatalk.php,$sourcedir/Subs-Optimus.php,$sourcedir/Subs-Scrolling.php
integrate_load_permissions;
integrate_load_theme;optimus_home,scrolling_load_theme
2sichat_mn_heart;10000
2sichat_cw_heart;5000
2sichat_purge;3
2sichat_gad_lang;dk
2sichat_gad_trans;0
2sichat_ico_myspace;0
2sichat_ico_twit;0
2sichat_ico_fb;0
2sichat_board_index;everywhere
2sichat_theme;default
2sichat_live_online;1
2sichat_list_type;1
integrate_profile_areas;
tapatalkEnabled;1
tp_pushEnabled;1
tp_guestOkayEnabled;1
tp_tapatalkNotifierForChromeEnabled;1
tp_register_page_url;index.php?action=register
integrate_menu_buttons;optimus_operations,scrolling_menu_buttons
integrate_buffer;optimus_buffer
optimus_description;Åbent RC forum drevet af frivillige entusiaster, hvor du kan dele din interesse for RC med ligesindede. Her snakkes om biler, fly, helikoptere, både og alt andet som vedrører RC. Besøg vores markedsplads, og se også de flotte brugergallerier.
optimus_templates;a:2:{s:5:"board";a:3:{s:4:"name";s:12:"{board_name}";s:4:"page";s:14:" - page {#} - ";s:4:"site";s:12:"{forum_name}";}s:5:"topic";a:3:{s:4:"name";s:12:"{topic_name}";s:4:"page";s:14:" - page {#} - ";s:4:"site";s:27:"{board_name} - {forum_name}";}}
optimus_meta;a:0:{}
optimus_ignored_actions;admin,bookmarks,credits,helpadmin,pm,printpage
optimus_search_stats;1
disabledBBC;email,email,flash,ftp,ftp,iurl,iurl,move,nobbc,shadow
disableCustomPerPage;1
package_server;localhost
package_port;21
enable_adk_snow_effect;1
ADK_SeVelo;median
ADK_SeChart;1
ADK_Secolor;F7F7F7
gallery_show_unviewed_items;0
enableReportPM;1
hitStats;1
admin_notes;http://iplocation.truevue.org/
enotify_refresh;5000
enotify_pms;1
enotify_replies;1
enotify_exp;48
fmenu_heading1;Samarbejdspartnere
fmenu_title1;RCMagasin.dk
fmenu_enabled;1
integrate_bbc_buttons;
fmenu_url1;http://rcmagasin.dk/
fmenu_title6;RCMagasin.dk
fmenu_url6;http://rcmagasin.dk/
fmenu_title11;RCMagasin.dk
fmenu_url11;http://rcmagasin.dk/
fmenu_title16;RCMagasin.dk
fmenu_url16;http://rcmagasin.dk/
fmenu_title21;RCMagasin.dk
fmenu_url21;http://rcmagasin.dk/
disabled_status_bbc;flash,img,table,code,quote,list,orderlist,hr
profile_statuses_limit_pages;3
profile_statuses_maxlen;50
profile_statuses_enable;1
articleavatar;1
disqus_allow;1
disqus_id;rcforum
sp_version;2.3.5
sp_smf_version;2
sp_portal_mode;1
sp_disableForumRedirect;1
showleft;1
showright;1
leftwidth;200
rightwidth;200
sp_enableIntegration;1
sp_adminIntegrationHide;0
sp_resize_images;1
portaltheme;2
disallow_sendBody;0
relatedTopicsCount;5
relatedIndex;fulltext
enable_default_avatar;1
default_male_avatar_url;
default_avatar_url;
sp_maintenance;0
optimus_forum_index;http://rc-forum.dk/index.php?action=forum
optimus_board_description;1
optimus_topic_description;1
optimus_404_status;1
spider_mode;1
disableTemplateEval;1
topbottomEnable;1
enableErrorQueryLogging;1

SoLoGHoST

Quote2- truncates/removes the package list from the DB (thus marking all packages as "uninstalled")

and

Quoteit does NOT:
delete mod specific installed files (i.e. mymod.php)
remove mod specific installed tables or columns from the database

Ok, well, than how are they supposed to uninstall any Mods after doing a reset?  Or was this your intention, to just start all over with a hell of a Modded Site, that shows no mods to the user?

Kindred

SoLoGHoST,

what my script does is uninstall the mods.
Yes, it leaves tables and files. specific to the mod (the files because it's a bother to track them down, and those get replaced if you reinstall anyway and the tables are left, quite on purpose, beause when/if you reinstall the mod, you have the data fro the previous install preserved...) so what?   The mods themselves are still uninstalled and the site is not "modded". There are no hooks active and there are no SMF core files modified. For all intents, the mods don't exist.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

SoLoGHoST

I follow you now, you removed hooks (cept, it seems like you're unable to remove the more complicated ones), and replaced all files with the original.

Might I just say, what if you were to filter out all Non-SMF files, cept that of the attachments and avatars directory, ofcourse and delete them also?  For example, it wouldn't be that difficult to build an array of the file structure, for each path within the zip file that you want to replace with, than you could build another array of all of the filepaths on the server, and doing an array_diff to it to sort out all paths that should be removed (that Mods have created).  That would get rid of the non-SMF files easily, but than, maybe you could provide an interface for filepaths that the user would like to keep (that array would just be merged into the first array).  For the database, you can do the same thing, dropping tables that aren't SMF tables, and removing columns in SMF tables that aren't there by default.

Anyways, just a thought.  But yeah, extra files on the server and database tables would not normally affect SMF alone, unless the Mods are altering the original SMF Database Tables dramatically.

But yeah, probably too much work to do that could bring about errors in the database.  And yeah, probably a good idea to keep the database as is, for when they install the mod again (if they do).  But the files could be wiped out easily...

SoLoGHoST

Also, had look at it, and just 1 suggestion I'd like to add.  Before you do anything, maybe you could place a check to be sure that the ZipArchive class exists, otherwise, if it doesn't exist for some reason, the users forum will be screwed up.

Suggested Code at top, before you begin anything...

if (!class_exists('ZipArchive'))
die('Sorry, but we are not able to continue without the ZipArchive class');


And nice one!

NiceLittleMonkey

Quote from: NiceLittleMonkey on February 17, 2013, 03:53:08 AM
Thank you, Gentlemen. So, I looked through the smf_settings table (SELECT * FROM `smf_settings`;) and could immediately see a lot of fields from different mods and packages installed over time and also the %integrate% hooks you mentioned.

If I understand you correctly, I can simply compare the content of my forum smf_settings table to the content of a freshly installed smf_settings table and delete what should not be there?

Don't mean to push and sorry for the newbie questions  :-[, but is it correct that I should compare the content of my forum smf_settings table to the content of a freshly installed smf_settings table and delete what should not be there?

Kindred

no... you don't need to do that...    Do what I said to find LIKE %integrate% and remove them everything else can stay
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

NiceLittleMonkey

Thank you.

It's just that I see a lot of fields in `smf_settings` that I positively know belonged to previously installedmods/packages. Here are some random examples:


  • enotify_life;15000
  • recaptcha_theme;clean
  • 2sichat_mn_heart;10000
  • sp_version;2.3.5

Arantor

They won't hurt being there, just taking up a little bit of space. If you were really paranoid you could clean house but honest it's not really worth the effort.

It'd be nice if mods could clean house properly when uninstalling, it isn't *that* hard to do. (Better would be if SMF could have some facility for mods to say what settings should be cleaned up.)

Advertisement: