vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Template Backup System! (https://vborg.vbsupport.ru/showthread.php?t=33072)

Wolf42 05-30-2002 05:48 PM

Thanks FireFly! :D

www.tourc.ca 05-31-2002 02:35 PM

I just switched servers and the template backup system doesn't work the same on the new server....

if there are no files in the templates directory, the backup system work fine.

but if there are existing files with the same name and I try to do a backup to overwrite the files I get the following messages!

Warning: SAFE MODE Restriction in effect. The script whose uid is 503 is not allowed to access ./templates/alinks.html owned by uid 0 in /home/virtual/site1/fst/var/www/html/forums/admin/adminfunctions.php on line 150

Warning: SAFE MODE Restriction in effect. The script whose uid is 503 is not allowed to access ./templates/alinks.html owned by uid 0 in /home/virtual/site1/fst/var/www/html/forums/admin/adminfunctions.php on line 158

Warning: fopen("./templates/alinks.html","w") - Success in /home/virtual/site1/fst/var/www/html/forums/admin/adminfunctions.php on line 158

Warning: Supplied argument is not a valid File-Handle resource in /home/virtual/site1/fst/var/www/html/forums/admin/adminfunctions.php on line 160

Warning: Supplied argument is not a valid File-Handle resource in /home/virtual/site1/fst/var/www/html/forums/admin/adminfunctions.php on line 162

this repeats over and over for each file it seems!

any ideas would be appreciated. for now I just ftp and delete all previous files before doing backup

-dave

Admin 05-31-2002 02:41 PM

Seems to be caused by running in safe mode, ask your host to turn it off.

www.tourc.ca 05-31-2002 02:49 PM

what happens if I am my host... is it easy to turn off or do I start searchin the net..

BTW great hack (like all of your hacks) and talk about support! I was barley done the post :)

thanks

Admin 05-31-2002 02:55 PM

This is the part that controls Safe Mode in php.ini:
Code:

;
; Safe Mode
;
safe_mode = Off

; By default, Safe Mode does a UID compare check when
; opening files. If you want to relax this to a GID compare,
; then turn on safe_mode_gid.
safe_mode_gid = Off

; When safe_mode is on, UID/GID checks are bypassed when
; including files from this directory and its subdirectories.
; (directory must also be in include_path or full path must
; be used when including)
safe_mode_include_dir =                                                               

; When safe_mode is on, only executables located in the safe_mode_exec_dir
; will be allowed to be executed via the exec family of functions.
safe_mode_exec_dir =

; open_basedir, if set, limits all file operations to the defined directory
; and below.  This directive makes most sense if used in a per-directory
; or per-virtualhost web server configuration file.
;
;open_basedir =

; Setting certain environment variables may be a potential security breach.
; This directive contains a comma-delimited list of prefixes.  In Safe Mode,
; the user may only alter environment variables whose names begin with the
; prefixes supplied here.  By default, users will only be able to set
; environment variables that begin with PHP_ (e.g. PHP_FOO=BAR).
;
; Note:  If this directive is empty, PHP will let the user modify ANY
; environment variable!
safe_mode_allowed_env_vars = PHP_

; This directive contains a comma-delimited list of environment variables that
; the end user won't be able to change using putenv().  These variables will be
; protected even if safe_mode_allowed_env_vars is set to allow to change them.
safe_mode_protected_env_vars = LD_LIBRARY_PATH

You can either turn it completely off by setting safe_mode to Off:
Code:

safe_mode = Off
Or leave it on, but turn this setting off:
Code:

safe_mode_gid = Off
This should fix the errors you are getting.

Henry-RS 06-03-2002 01:13 AM

VERY USEFUL! Just installed lesane's hack with it. :D

Jawelin 06-03-2002 08:17 AM

Hi, Chen.
A (simple) request: could it be possible to export - export only (not needed import...) - ALL TEMPLATES including default ones, for example with a differend prefix, suffix or directory ?
I mean, if a template exists with more templatesetids (tipically 1 and -1), could it be possible to export both to different targets ?

Obviously, this feature should be very very useful when upgrading VB, to perform an easier check of changes in the '-1' set, otherwise not exported...

Thanks a lot.
LMK

Bye

kippesp 06-03-2002 02:57 PM

[QUOTE]Originally posted by Jawelin
[B]Hi, Chen.
A (simple) request: could it be possible to export - export only (not needed import...) - ALL TEMPLATES including default ones, for example with a differend prefix, suffix or directory ?
I mean, if a template exists with more templatesetids (tipically 1 and -1), could it be possible to export both to different targets ?

Jawelin 06-03-2002 03:07 PM

[QUOTE]Originally posted by kippesp
Default templates can already be exported. After you've upgraded your PHP files, add a new template set. Then export the new set.

Darren Lewis 06-03-2002 09:44 PM

Just reinstalled this hack (with the new tbs.php) and all works fine on V2.2.6 with PHP4.1.2.

Darren.


All times are GMT. The time now is 07:20 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01300 seconds
  • Memory Usage 1,738KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete