Welcome to Geeklog, Anonymous Thursday, March 28 2024 @ 05:01 pm EDT

Geeklog Forums

Question about $mode in databases.php


Status: offline

tomath2o

Forum User
Newbie
Registered: 12/31/03
Posts: 10
confused
Hello,

I am trying to get the DB Backups function to work as admin.

When I click it, it doesn't give an error, but no backup is created.
I think I have the config.php entries for mysqldump and
backup path correct.

The problem appears to be that the code in databases.php for
doing the backup is never getting reached.

I put some debug in the code above the line

if ($mode == $LANG_DB_BACKUP['do_backup']) {

to print out the values of these 2 variables --
and it seems that $mode is not set.
Also, debug below this line is never reached.

When I do mouse-over of the DB Backups link,
it points directly to databases.php.

But I don't see anywhere that $mode is set in the code.

I guess this is something to do with HTTP forms,
which frankly I do not understand very well.

Can someone explain to me how $mode is being set?
And more importantly, why my backups don't seem to work?


 Quote

Status: offline

Chalkhillian

Forum User
Chatty
Registered: 09/23/02
Posts: 67
When you say that it doesn't give an error - have you checked your logs? There are logs in Geeklog and there are logs in your root directory (1 level higher than your public directory. Usually between those two sets of logs there will be a clue as to what is going on (or not ....)
 Quote

Status: offline

tomath2o

Forum User
Newbie
Registered: 12/31/03
Posts: 10
Quote by Chalkhillian: - have you checked your logs? There are logs in Geeklog and there are logs in your root directory (1 level higher than your public directory.


The logs don't seem to give much...

The log at /usr/local/geeklog/logs/error.log has only a message
about an invalid directory, which I fixed already.
(I moved all my geeklog filles except the public_html dir
off the web server tree.)

I am not sure what other log you mean.

Maybe the Apache log at /var/logs/httpd/error.log?
That gives only a message about favicon.ico being
missing.

Tom



 Quote

Status: offline

Turias

Forum User
Full Member
Registered: 10/20/03
Posts: 807
You say that $mode isn't set? The [SUBMIT] button for doing the backup has the following HTML code:

Text Formatted Code
<input type="submit" name="mode" value="Do Backup">
 


If you push it, $mode should be "Do Backup". Does your source on that page look different?
 Quote

Status: offline

tomath2o

Forum User
Newbie
Registered: 12/31/03
Posts: 10
dizzy
Quote by Turias:
If you push it, $mode should be "Do Backup". Does your source on that page look different?


No, it is the same.

The problem turned out to be my incorrect configuration.
I didn't have register_globals On in php.ini. Oops!

I had it On in my work site, where I originally installed geeklog, but not in my home site, where I was testing it for the browser/server/cookie problem you can read about in the Installation forum.
The home site is where I was trying to do the backup.

Thanks for your help.




 Quote

All times are EDT. The time is now 05:01 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content