Rename admin folder + php notice/warnings

ThemeBurn SupportForumsOpenCart ThemesShoppica 2 OpenCart ThemeRename admin folder + php notice/warnings

This topic has been marked as not resolved.

Hi,

I have renamed the admin folder and applied the changes in the config.php file. I want to know if I need to edit any shoppica file due to the new admin folder name?

Also , I’m getting the following php notices and warning in the error file:

PHP Notice: Undefined index: HTTP_HOST in …/public_html/index.php on line 173
PHP Notice: Undefined index: HTTP_HOST in …/public_html/system/library/currency.php on line 45
PHP Notice: Undefined index: HTTP_HOST in …/public_html/tb_themes/shoppica2/library/Context.php on line 73
PHP Warning: parse_url(http://) [function.parse-url]: Unable to parse URL in …/public_html/tb_themes/shoppica2/library/Utils.php on line 89
PHP Notice: Undefined index: HTTP_HOST in …/public_html/tb_themes/shoppica2/library/Context.php on line 74
PHP Warning: parse_url(https://) [function.parse-url]: Unable to parse URL in …/public_html/tb_themes/shoppica2/library/Utils.php on line 89
PHP Notice: Undefined index: HTTP_HOST in …/public_html/tb_themes/shoppica2/library/Context.php on line 80
PHP Notice: Undefined index: HTTP_USER_AGENT in …/public_html/tb_themes/shoppica2/library/Utils.php on line 7

How can I solve the above issues?

Thanks!

  • This reply was modified 3291 days ago by  dafre.
  • This reply was modified 3291 days ago by  dafre.
 dafre
June 12, 2012 at 2:59 am #10208

Are you accessing the site by IP or by domain name ?

June 13, 2012 at 11:12 am #10270

I access the site by the domain name

 dafre
June 15, 2012 at 1:52 am #10381

After some investigation I guess the php notices and warnings come from a bot access , I’m getting the warning/notice 1 or 2 times per day and I checked the access log yesterday it occurred at the same time a bot made a HEAD request , all other bots in the log make GET requests.

I don’t have access logs from other days but I will block that bot to confirm if it’s what causing the php warnings/notices. I also added a rewrite rule in the .htaccess file to redirect all access to the site via IP to the domain name. If I still get the warning /notices I will post here.

What about the admin directory rename? do I have to edit any shoppica file?

Thanks!

 dafre
June 15, 2012 at 1:35 pm #10398
You will need to register in order to post topics and read replies in the ThemeBurn.com support forums!
June 18, 2012 at 12:40 pm #10484

It was working without modifications to tb_themes\shoppica2\config.php

After I edited tb_themes\shoppica2\config.php ‘admin’ to the folder name I’m using the layout broke and I got over a hundred “PHP Notice: Undefined index:” in the error log for every page visited in the site.

I had to edit tb_themes\shoppica2\config.php back to ‘admin’

 dafre
June 18, 2012 at 9:10 pm #10525

The ‘admin_folder’ value is used only in the Shoppica CP and represents the name of the tb_themes/shoppica2/admin. I thought you want to change this folder too.

Sorry for misleading you, you don’t have to edit the ‘admin_foler’ value if you want to change the default opencart admin folder.

Best Regards,
ThemeBurn team

June 19, 2012 at 9:50 am #10535

Hello,
I am using Shoppica 2.1.2 on OpenCart 1.5.3.1.
Front store crashed this evening by itself but happily I had a backup and could get it to work.
But I kept the broken site to investigate what was the problem. After checking error log I found this error message: (My admin is working fine)
2012-07-18 22:46:17 – PHP Notice: Undefined index: host in /home5/***/public_html/store4/tb_themes/shoppica2/library/Utils.php on line 87
2012-07-18 22:46:17 – PHP Warning: stripos() [function.stripos]: needle is not a string or an integer in /home5/***/public_html/store4/tb_themes/shoppica2/library/Utils.php on line 95
I didn’t change anything and it happened all of sudden.
Can you please help me? I have a blank store because of this error.
Not related: If I want to have your help as freelancer what should I do?
Thanks,
-Matt

July 19, 2012 at 8:26 am #11525

@kamyabi,

try to replace the tb_themes\shoppica2\library\Context.php with the attached one to see if this fixes your issues. Anyway, this cannot be the reason you’re seeing a blank page.

Regards,
ThemeBurn team

July 23, 2012 at 12:28 pm #11663
Viewing 9 posts - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.