File tree 3 files changed +26
-1
lines changed
3 files changed +26
-1
lines changed Original file line number Diff line number Diff line change
1
+ config.inc
2
+ data
Original file line number Diff line number Diff line change 17
17
// Include library of functions
18
18
//
19
19
include 'lib/config.inc ' ;
20
- include 'config.inc ' ;
21
20
include 'lib/onlyblog.php ' ;
21
+
22
+ check_config_inc ();
23
+
24
+ include 'config.inc ' ;
22
25
include $ __config ['theme_dir ' ] . "/theme.php " ;
23
26
24
27
blog_init ();
Original file line number Diff line number Diff line change @@ -643,4 +643,24 @@ function search_stub () {
643
643
644
644
return $ output ;
645
645
}
646
+
647
+ //
648
+ // Check for existence of config.inc file in installation directory
649
+ //
650
+ function check_config_inc () {
651
+ if (!file_exists ('config.inc ' )) {
652
+ ?>
653
+ <html>
654
+ <head>
655
+ <title>OnlyBlog Setup</title>
656
+ </head>
657
+ <body>
658
+ <h1>OnlyBlog Setup</h1>
659
+ <b><code>config.inc</code></b> file does not exist. This is a required file. Use <code>sample-config.inc</code> as a reference to create one.<br>
660
+ </body>
661
+ </html>
662
+ <?php
663
+ exit ();
664
+ }
665
+ }
646
666
?>
You can’t perform that action at this time.
0 commit comments