WebsiteBaker Logo
  • *
  • Templates
  • Help
  • Add-ons
  • Download
  • Home
*
Welcome, Guest. Please login or register.

Login with username, password and session length
 

News


WebsiteBaker 2.13.6 is now available!


Will it continue with WB? It goes on! | Geht es mit WB weiter? Es geht weiter!
https://forum.websitebaker.org/index.php/topic,32340.msg226702.html#msg226702


The forum email address board@websitebaker.org is working again
https://forum.websitebaker.org/index.php/topic,32358.0.html


R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WB
https://forum.websitebaker.org/index.php/topic,32355.0.html


* Support WebsiteBaker

Your donations will help to:

  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!

You can donate by clicking on the button below.


  • Home
  • Help
  • Search
  • Login
  • Register

  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.10.x) »
  • Modules »
  • Modul Jobs error
  • Print
Pages: [1]   Go Down

Author Topic: Modul Jobs error  (Read 16641 times)

Offline rumen

  • Posts: 480
  • Gender: Male
Modul Jobs error
« on: September 25, 2018, 10:50:31 AM »
Hello, I have error in module jobs. I'm running WB 2.12 error message:

Code: [Select]
Warning: require(/opt/lampp/htdocs/config.php): failed to open stream: Няма такъв файл или директория in /opt/lampp/htdocs/212/modules/jobs/update.php on line 16

Fatal error: require(): Failed opening required '/opt/lampp/htdocs/config.php' (include_path='.:/opt/lampp/lib/php') in /opt/lampp/htdocs/212/modules/jobs/update.php on line 16

Line 16:
Code: [Select]
require($_SERVER['DOCUMENT_ROOT'].'/config.php');
What can be wrong?

Regards,

Rumen
Logged

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: Modul Jobs error
« Reply #1 on: September 25, 2018, 11:00:14 AM »
Line 16 expects your WB to be installed in the root of the webspace.

Just replace line 16 with:
Code: [Select]
require('../../config.php');
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline jacobi22

  • Betatester
  • **
  • Posts: 5920
Re: Modul Jobs error
« Reply #2 on: September 25, 2018, 11:00:36 AM »
maybe your DOCUMENT_ROOT  ;-)

for example: if you work in a subfolder from your domain, it's possible, that your DOCUMENT_ROOT is not the WB-Root-Folder

to your special case:
compare the error messages

path to the file / path to WB is

/opt/lampp/htdocs/212/modules/jobs/update.php or /opt/lampp/htdocs/212/

your document-root is
/opt/lampp/htdocs/config.php

i'm missing the 212-folder
change it in your upgrade.php to

require('../../config.php');

Ruud was faster  (Y)
Logged

Offline rumen

  • Posts: 480
  • Gender: Male
Re: Modul Jobs error
« Reply #3 on: September 25, 2018, 05:38:54 PM »
I got same error

Code: [Select]
Warning: require(/opt/lampp/htdocs../../config.php): failed to open stream: No such file or directory in /opt/lampp/htdocs/212/modules/jobs/update.php on line 17

Fatal error: require(): Failed opening required '/opt/lampp/htdocs../../config.php' (include_path='.:/opt/lampp/lib/php') in /opt/lampp/htdocs/212/modules/jobs/update.php on line 17

It is set

Code: [Select]
require($_SERVER['DOCUMENT_ROOT'].'../../config.php');
It is row 17 because I keep copy of the original (as always) on row 16

Code: [Select]
// require($_SERVER['DOCUMENT_ROOT'].'/config.php');   ORIGINAL
If it is necessary I can move it to the host and try there.
Logged

Offline jacobi22

  • Betatester
  • **
  • Posts: 5920
Re: Modul Jobs error
« Reply #4 on: September 25, 2018, 06:45:25 PM »
see answer from Ruud

replace line 16 with

Code: [Select]
require('../../config.php');
dont use $_SERVER['DOCUMENT_ROOT'] in a sub-folder for the locale test's or you have to correct the path everytime

this works on your locale server:
Code: [Select]
require($_SERVER['DOCUMENT_ROOT'].'/212/config.php'); but not longer, if you move from your locale server to another one
Logged

Offline rumen

  • Posts: 480
  • Gender: Male
Re: Modul Jobs error
« Reply #5 on: September 25, 2018, 08:38:01 PM »
Thanks, it works now!   

I got the logic.
Logged

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.10.x) »
  • Modules »
  • Modul Jobs error
 

  • SMF 2.0.19 | SMF © 2017, Simple Machines
  • XHTML
  • RSS
  • WAP2