Forums / All Other Contributions/Addons / Editable Home Page Centerboxes [Support]

Editable Home Page Centerboxes [Support]

Views: 50,592

Results 321 to 340 of 347
6 Jan 2019, 12:23 AM
#321
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Editable Home Page Centerboxes [Support]

v155f php7.1

I am having a problem with adding Structured Data Markup code in a middlebox - when I add the code the box disappears completely, i.e. not just the text but the space the box consumes. The code is the whole html 'document' as marked up using Google Markup Tool.

(possibly unrelated however something I have encountered for a while now has been the non acceptance of header title codes higher than h4, i.e. h1,2 and 3 results in the text between <h> and </h> disappearing altogether - not important as the above, just thought it worth mentioning)

any assistance would be appreciated.
cheers,
Mike

6 Jan 2019, 1:31 AM
#322
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

Please ignore the Markup section of the previous post - I originally used JSON-LD and that didn't work but then regenerated the text using Microdata and that didn't work either so contacted my host - seems there were some mod_security issues that have now been whitelisted - I used Microdata after that and it works fine.

Interestingly with the JSON-LD version I was getting a 403 Forbidden when trying to add the content to an EZ page as a trial - this was the response from the host;
"Mixed Content: The page at 'https://www.harmonyballpendant.com/about-our-harmony-necklaces-ezp-29.html' was loaded over HTTPS, but requested an insecure script 'http://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js'. This request has been blocked; the content must be served over HTTPS.
You should just need to load that file over https://"

Should that java script address be HTTPS (??)

Also ignore the <h> header statement above - having a bad day! Sorry for the unnecessary interruption.

cheers,
Mike

6 Jan 2019, 1:37 AM
#323
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Editable Home Page Centerboxes [Support]

Yes it does appear that your javascript file is attempting to be loaded via http: on an https: page, that is something that would need to be addressed by either removing the http: part leaving behind the double forward slashes and everything behind it or changing http: to https:. You can search your site for hardcoded http: links using the tools->developers tool kit and searching all files for http: (this is to include javascript files as well.

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

6 Jan 2019, 1:50 AM
#324
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

mc12345678:

Yes it does appear that your javascript file is attempting to be loaded via http: on an https: page, that is something that would need to be addressed by either removing the http: part leaving behind the double forward slashes and everything behind it or changing http: to https:. You can search your site for hardcoded http: links using the tools->developers tool kit and searching all files for http: (this is to include javascript files as well.

many thanks MC

24 Jan 2019, 6:55 AM
#325
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

I am trying to utilize these middle boxes on other pages. I currently use one box on the main page in location 3, Below New, Specials, Featured etc. centerboxes.

In admin/configuration I changed to 0 for ALL pages and then selected location 9 for a box (Categories - Always Show on Main Page is set to No) and entered some text in that box in define pages editor but I am not seeing that box show up on any pages which I expected it should - have I missed something? from the configuration instructions in readme ... If you use the position settings 8 or 9 for a box, it will appear on all pages regardless of other settings. (all pages I believe only includes home and category pages?) ... I'm not seeing any error logs.

cheers, Mike

P.S. I found this in the readme however I am not sure that it applies to the above, albeit would it be relevant if I wanted to include a box in an EZ page?;

If you want to add new locations where middleboxes can be displayed, you will need to insert a
get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>
statement in the desired location, with the new location number (8 or higher) in place of the X and the comment text you want to use to identify the middlebox group in the page's HTML source.
Then you will need to modify the SQL to update the middlebox location settings in the admin menu, adding the new locations, and run the SQL in Tools > Install SQL Patches.

Alternatively, you can simply move one of the existing
get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>
function statements from a location you do not need to a new location or file where you want to use it. This requires no SQL modifications, though the admin setting descriptions will not describe your new location. 
13 Feb 2019, 3:28 AM
#326
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

shags38:

I am trying to utilize these middle boxes on other pages. I currently use one box on the main page in location 3, Below New, Specials, Featured etc. centerboxes.

In admin/configuration I changed to 0 for ALL pages and then selected location 9 for a box (Categories - Always Show on Main Page is set to No) and entered some text in that box in define pages editor but I am not seeing that box show up on any pages which I expected it should - have I missed something? from the configuration instructions in readme ... If you use the position settings 8 or 9 for a box, it will appear on all pages regardless of other settings. (all pages I believe only includes home and category pages?) ... I'm not seeing any error logs.

cheers, Mike

P.S. I found this in the readme however I am not sure that it applies to the above, albeit would it be relevant if I wanted to include a box in an EZ page?;

If you want to add new locations where middleboxes can be displayed, you will need to insert a
get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>
statement in the desired location, with the new location number (8 or higher) in place of the X and the comment text you want to use to identify the middlebox group in the page's HTML source.
Then you will need to modify the SQL to update the middlebox location settings in the admin menu, adding the new locations, and run the SQL in Tools > Install SQL Patches.

Alternatively, you can simply move one of the existing
get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>
function statements from a location you do not need to a new location or file where you want to use it. This requires no SQL modifications, though the admin setting descriptions will not describe your new location.


Using admin > configuration > Editable Centerboxes - Centerboxes **on pages other than home page** works fine in v1.5.1 but I cannot get it to work in v1.5.5f - has anyone got it working satisfactorily in 155f? - if so was there a fix you used or was the plugin installed as downloaded? Not sure if I may have missed a file merge or something.

cheers, Mike
14 Feb 2019, 11:37 AM
#327
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Editable Home Page Centerboxes [Support]

shags38:

I am trying to utilize these middle boxes on other pages. I currently use one box on the main page in location 3, Below New, Specials, Featured etc. centerboxes.

In admin/configuration I changed to 0 for ALL pages and then selected location 9 for a box (Categories - Always Show on Main Page is set to No) and entered some text in that box in define pages editor but I am not seeing that box show up on any pages which I expected it should - have I missed something? from the configuration instructions in readme ... If you use the position settings 8 or 9 for a box, it will appear on all pages regardless of other settings. (all pages I believe only includes home and category pages?) ... I'm not seeing any error logs.

cheers, Mike

P.S. I found this in the readme however I am not sure that it applies to the above, albeit would it be relevant if I wanted to include a box in an EZ page?;

If you want to add new locations where middleboxes can be displayed, you will need to insert a
get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>
statement in the desired location, with the new location number (8 or higher) in place of the X and the comment text you want to use to identify the middlebox group in the page's HTML source.
Then you will need to modify the SQL to update the middlebox location settings in the admin menu, adding the new locations, and run the SQL in Tools > Install SQL Patches.

Alternatively, you can simply move one of the existing
get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>
function statements from a location you do not need to a new location or file where you want to use it. This requires no SQL modifications, though the admin setting descriptions will not describe your new location.


To identify an included middle box to a given "number", if you notice in the other examples the pattern:
<?php $box_loc = '1';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '2';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '3';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>

Each of the $box_loc variables relates back to MIDDLEBOX_NUMBER_1, MIDDLEBOX_NUMBER_2, and MIDDLEBOX_NUMBER_3 respectively.

Boxes 8 and 9 are not currently in the template files and must be added where desired.  To identify a box to be of group 8 or 9 (or above if additional have been added), need to include the below where it is desired to display the content associated with the box:
<?php $box_loc = '8';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>

And wherever that particular group has been added for display it will be displayed.  The incorporation points provided in the existing template files are basically examples or starting points to see operation.  Like all things ZC their placement location can be modified to suit.  Just remember if $box_loc >= 8, then it will be displayed whether the current page is the homepage or not.

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

12 Aug 2020, 12:04 AM
#328
rlexyd avatar

rlexyd

Zen Follower

Join Date:
Nov 2006
Location:
Sydney, Australia
Posts:
487
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

Is this Mod still current, I would like to install this for a new 1.5.7 instalation and not sure if it's compatible since the last responce was from 2019?! I just need a few main images on my front page.

*Zen Cart eCommerce Solution - Putting the Dream of Owning an Online Business within reach of anyone!

13 Aug 2020, 6:09 PM
#329
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Editable Home Page Centerboxes [Support]

rlexyd:

Is this Mod still current, I would like to install this for a new 1.5.7 instalation and not sure if it's compatible since the last responce was from 2019?! I just need a few main images on my front page. So I've looked through the fileset and it doesn't appear that there is anything that specifically needs updating/revision for ZC V1.5.7. The associated template files haven't been modified in several years (longer than before the last edit to the module) and I didn't really see anything in the associated display module that would be php 7.x problematic, though there might be some sort of "strict" processing issues as a possibility during initial install if the database is not populated before the files being placed. The only thing that really may be an issue is that the installer is similar to others that may present a problem with at least one other plugin because the two use a similar variable causing the variable to lose meaning for the other plugin.

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

14 Aug 2020, 1:37 AM
#330
rlexyd avatar

rlexyd

Zen Follower

Join Date:
Nov 2006
Location:
Sydney, Australia
Posts:
487
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

Thank you for your response.
Will try it on a blank website and see how it goes, will report if any issues develop.
Thanks again.

*Zen Cart eCommerce Solution - Putting the Dream of Owning an Online Business within reach of anyone!

3 Oct 2020, 10:48 PM
#331
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

v1.5.5f westminster_new template

Hello MC - I do not seem to be able to get <h3>heading</h3> to work in the middle box on the main page - <h2>heading</h2> works fine but h3 results in a whitespace - is there somewhere I can attempt to adjust code to fix this?
cheers,
Mike

4 Oct 2020, 8:21 AM
#332
simon1066 avatar

simon1066

Totally Zenned

Join Date:
Feb 2009
Location:
UK
Posts:
1,326
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

shags38:

v1.5.5f westminster_new template

Hello MC - I do not seem to be able to get <h3>heading</h3> to work in the middle box on the main page - <h2>heading</h2> works fine but h3 results in a whitespace - is there somewhere I can attempt to adjust code to fix this?
cheers,
Mike

While I'm unfamiliar with this mod, it appears that the H3 heading 'We put the Choice and Variety back into Clip On Earrings' is not displaying because it is the same colour (white) as the background (white).

I would look at this code in stylesheet_middleboxes.css

.middleboxContainer h3,
.middleboxContainer h3 a {
 color:#ffffff;
}

Simon

28 Jan 2021, 6:43 AM
#333
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

v1.5.7b PHP 7.3 responsive classic template

I would like to use this plugin again (have for years) - previously in v1.5.5f / westminster_new

I AM HOPELESS AT MERGNG FILES .... it has been my biggest issue over the years in not merging correctly and creating problems - so it is terrifying to see lots of colored lines on each side of the ledger when comparing the template files from this plugin and responsive classic in two of the three files - I dread even attempting it (if it is something that I regard as simple and obvious enough I will attempt it, but that is a big 'if')

2 questions;

  1. if I am only ever going to use just one box on the main page, not anywhere else, can I install just a merged includes/templates/my template/templates/tpl_index_default.php and ignore the other two template files - the merge for tpl_index_default is simplistic so I think (caveat) I can mage that one.
    In looking at my equivalent files in v1.5.5f where I had this plugin installed I only had tpl_index_default merged and not the other two, that I can see, and (eventually, with lots of help and extreme tolerance from mc12345678) I had it working well on the home page - all other files were installed.

  2. if not, then is it possible to get some guidance on merging the other two files?

includes/templates/mytemplate/common/tpl_main_page.php
the following I think should be copied across to the existing site file;

<?php $box_loc = '8';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '9';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <!--bof- parse time display --> <?php if (DISPLAY_PAGE_PARSE_TIME == 'true') { ?> <div class="smallText center">Parse Time: <?php echo $parse_time; ?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div> <?php } ?> <!--eof- parse time display --> ########################################

includes/templates/my template/templates/tpl_index_categories.php
the following I think should be copied across to the existing site file;

<!-- deprecated - to use - uncomment <?php if (TEXT_MAIN) { ?> <div id="" class="content"><?php echo TEXT_MAIN; ?></div> <?php } ?>--> <!-- deprecated - to use - uncomment <?php if (TEXT_INFORMATION) { ?> <div id="" class="content"><?php echo TEXT_INFORMATION; ?></div> <?php } ?>--> <?php $box_loc = '4';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '5';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '6';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '7';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> </div> ####################___

the rest of what I see as variations appear to my untrained eye to just be changes in versions between 2012 and 2016 / 2020

I am trying harder these days to do my own problem solving before jumping headlong into the forum for help - but this is really scary to me.

cheers,
Mike

28 Jan 2021, 8:05 AM
#334
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Location:
Croatia
Posts:
1,805
Plugin Contributions:
22

Re: Editable Home Page Centerboxes [Support]

Here's a version with 1.5.7b files all merged. Give it a try.

My site - Pro ZC Help
My portfolio | My plugins

28 Jan 2021, 9:12 AM
#335
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Editable Home Page Centerboxes [Support]

shags38:

v1.5.7b PHP 7.3 responsive classic template

I would like to use this plugin again (have for years) - previously in v1.5.5f / westminster_new

I AM HOPELESS AT MERGNG FILES .... it has been my biggest issue over the years in not merging correctly and creating problems - so it is terrifying to see lots of colored lines on each side of the ledger when comparing the template files from this plugin and responsive classic in two of the three files - I dread even attempting it (if it is something that I regard as simple and obvious enough I will attempt it, but that is a big 'if')

2 questions;

  1. if I am only ever going to use just one box on the main page, not anywhere else, can I install just a merged includes/templates/my template/templates/tpl_index_default.php and ignore the other two template files - the merge for tpl_index_default is simplistic so I think (caveat) I can mage that one.
    In looking at my equivalent files in v1.5.5f where I had this plugin installed I only had tpl_index_default merged and not the other two, that I can see, and (eventually, with lots of help and extreme tolerance from mc12345678) I had it working well on the home page - all other files were installed.

  2. if not, then is it possible to get some guidance on merging the other two files?

includes/templates/mytemplate/common/tpl_main_page.php
the following I think should be copied across to the existing site file;

<?php $box_loc = '8';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '9';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <!--bof- parse time display --> <?php if (DISPLAY_PAGE_PARSE_TIME == 'true') { ?> <div class="smallText center">Parse Time: <?php echo $parse_time; ?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div> <?php } ?> <!--eof- parse time display --> ######################################## ``` > includes/templates/my template/templates/tpl_index_categories.php > the following I think should be copied across to the existing site file; > ``` <!-- deprecated - to use - uncomment <?php if (TEXT_MAIN) { ?> <div id="" class="content"><?php echo TEXT_MAIN; ?></div> <?php } ?>--> <!-- deprecated - to use - uncomment <?php if (TEXT_INFORMATION) { ?> <div id="" class="content"><?php echo TEXT_INFORMATION; ?></div> <?php } ?>--> <?php $box_loc = '4';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '5';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '6';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> <?php $box_loc = '7';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?> </div> ####################___ ``` > the rest of what I see as variations appear to my untrained eye to just be changes in versions between 2012 and 2016 / 2020 > > > > I am trying harder these days to do my own problem solving before jumping headlong into the forum for help - but this is really scary to me. > > cheers, > Mike GOOD SLEUTHING!

So, you obviously figured out some file differences. Specifically differences that would (could) change what the page(s) display.

Some of the identified differences though are actually changes that were made to the Zen Cart template and have nothing to do with this plugin. I guess I actually should say that some of those changes do not impact the intended use of the plugin.

So, to back out from that a little, you only ever really, truly, fully need to install the software that is necessary to get the result you need/want. Now, huge caveat there, anything other than a full package may cause questions to be asked the next time around if there are not good notes/documentation... for example, right now are asking why do your current files (those becoming "old") only incorporate a portion of this plugin and is it possible to continue to operate that way?

Welp, think you have your answer, don't you?

From the template changes identified above, the "two" lines where '$box_loc =' and the require just after it are needed to display the box that is assigned to the location identified by that number. Any <?php and/or ?> surrounding that are needed based on where in the page content they are being placed. Content between those tags is php while outside of it is the html space.

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

28 Jan 2021, 6:54 PM
#336
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

balihr:

Here's a version with 1.5.7b files all merged. Give it a try.

Thanks Leonard - that is very generous of you mate!

So looking at mc12345678 response following yours I am encouraged to try doing a merge myself mainly because I need to have a go - I can do so confidently now in the knowledge that I have the pre-merged files from you should I stuff it up :smile:

I really do appreciate your thoughtfulness in sending that file.

thanks very much,
Mike

28 Jan 2021, 7:01 PM
#337
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

mc12345678:

GOOD SLEUTHING!

So, you obviously figured out some file differences. Specifically differences that would (could) change what the page(s) display.

Some of the identified differences though are actually changes that were made to the Zen Cart template and have nothing to do with this plugin. I guess I actually should say that some of those changes do not impact the intended use of the plugin.

So, to back out from that a little, you only ever really, truly, fully need to install the software that is necessary to get the result you need/want. Now, huge caveat there, anything other than a full package may cause questions to be asked the next time around if there are not good notes/documentation... for example, right now are asking why do your current files (those becoming "old") only incorporate a portion of this plugin and is it possible to continue to operate that way?

Welp, think you have your answer, don't you?

From the template changes identified above, the "two" lines where '$box_loc =' and the require just after it are needed to display the box that is assigned to the location identified by that number. Any <?php and/or ?> surrounding that are needed based on where in the page content they are being placed. Content between those tags is php while outside of it is the html space.

Thanks for the encouragement MC ... and the explanation. You will note in my reply to balihr (Leonard) that I will confidently now try a merge myself - I need to for my own education I suppose and confidence going forward - having his pre-merged files gives me a fallback position should I need it, using his files as a reference.

very much appreciated,
Mike

29 Jan 2021, 6:12 AM
#338
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

**"the best laid plans of men and mice are often torn assunder" **(not sure who the author is)

my day got even worse - had completed this post in its entirety bar the sign off when my computer froze - even the hammer I have with "IT Tool" engraved on the handle didn't work :smile:

So it has been an epic fail trying to get this plgin installed correctly. I am not sure where the issue lies but have spent about 6 hours so far trying to get a result so now I need some advice please.

All of the following has been done in a site copy in a folder in the root.

Putting aside the fact that I did a merge of tpl_index_default.php it turns out not to be the issue - I moved this file to below all the center box instances (featured, new, specials etc.) and removed all other instances of the code for other middle boxes and then inserted the code to show news_box below it;

<?php $box_loc = '1';//middlebox group require($template->get_template_dir('tpl_middleboxes.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_middleboxes.php'); ?>

Will try to keep this short but say enough that you can follow what the issues are and what I have done;

  1. the page is blank below the end of main page text - with my merged tpl_index_default the footer shows - with the file from balihr the footer disappears.
    I used the all the rest of the files including the reamining template balihr kindly provided (for expediency)
  2. admin/tools/define pages editor does not show any instances of middleboxes
  3. when I installed using the install.sql it showed 27 instances successful.
  4. tried a few different things like using the stock plugin files (3.1.0) from my pc I had used on previous versions but used the merged templates as described above
  5. at various stages I decided to check my database tables - the first instance showed only one (1) line in configuration table (middlebox sidebox 9) and nothing else.
  6. I ran uninstall.sql then reinstalled
  7. Then reloaded the plugin files a few times alternating tpl_index_default versions and admin files from my stock and that in the files from balihr
  8. the issue persisted so I checked database tables one last time after myriads of trial and error attempts - this time again only (1) line showed in configuration Middlebox 1 - Location MIDDLEBOX_NUMBER_1
  9. there remains a green section at the top of the admin page that shows Updated sort order configuration for Editable Center Boxes and Installed Editable Center Boxes v1.5.3 - the files I have been using as has balihr are version 3.1.0 .... and that green notification will not disappear even when I log out and log back in.
  10. throughout this whole saga there have been 14 instances of the same myDEBUG error - which is understandable - see below
[29-Jan-2021 14:54:21 Australia/Sydney] Request URI: /SiteCopy/, IP address: 115.166.19.58
#1 constant() called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php:29]
#2 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php) called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php:89]
#3 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php) called at [/SiteCopy/includes/modules/pages/index/main_template_vars.php:232]
#4 require(/SiteCopy/includes/modules/pages/index/main_template_vars.php) called at [/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php:142]
#5 require(/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php) called at [/SiteCopy/index.php:94]
--> PHP Warning: constant(): Couldn't find constant FILENAME_DEFINE_MIDDLEBOX_1 in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 29.

[29-Jan-2021 14:54:21 Australia/Sydney] Request URI: /SiteCopy/, IP address: 115.166.19.58
#1 constant() called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php:40]
#2 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php) called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php:89]
#3 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php) called at [/SiteCopy/includes/modules/pages/index/main_template_vars.php:232]
#4 require(/SiteCopy/includes/modules/pages/index/main_template_vars.php) called at [/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php:142]
#5 require(/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php) called at [/SiteCopy/index.php:94]
--> PHP Warning: constant(): Couldn't find constant BOX_HEADING_MIDDLEBOX1 in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 40.

[29-Jan-2021 14:54:21 Australia/Sydney] Request URI: /SiteCopy/, IP address: 115.166.19.58
#1 require() called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php:42]
#2 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php) called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php:89]
#3 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php) called at [/SiteCopy/includes/modules/pages/index/main_template_vars.php:232]
#4 require(/SiteCopy/includes/modules/pages/index/main_template_vars.php) called at [/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php:142]
#5 require(/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php) called at [/SiteCopy/index.php:94]
--> PHP Warning: require(includes/languages/english/html_includes/.php): failed to open stream: No such file or directory in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 42.

[29-Jan-2021 14:54:21 Australia/Sydney] PHP Fatal error: require(): Failed opening required 'includes/languages/english/html_includes/.php' (include_path='.:/opt/alt/php73/usr/share/pear') in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 42
 

I am at a loss to understand why the configuration files aren't loading - whether from my files or from balihr. Any ideas of what I should be looking at or for?
I figure that I should a) run unistall.sql, b) check database to ensure tables have been dropped, c) then delete every file associated with the plugin, d) then reinstall (whilst holding my rabbit foot very tightly)

cheers, Mike

29 Jan 2021, 1:10 PM
#339
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

So I decided to uninstall the plugin and start afresh - ran uninstall.sql - then deleted all files relating to the plugin - then reinstalled all the files.

Now I cannot get to the admin page, error [WARNING: An Error occurred, please refresh the page and try again.If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.]

I can access a backup copy that will restore the 'test site folder' to a point prior to these actions which will take me back to where I was in the previous post. So have that as a fallback - just wanted to table this first for comment.

myDEBUG error;

[29-Jan-2021 23:22:11 Australia/Sydney] Request URI: /SiteCopy/dazzlers/index.php?cmd=login&camefrom=index.php, IP address: 115.166.19.58
#1 trigger_error() called at [/includes/classes/db/mysql/query_factory.php:170]
#2 queryFactory->show_error() called at [/includes/classes/db/mysql/query_factory.php:142]
#3 queryFactory->set_error() called at [/includes/classes/db/mysql/query_factory.php:269]
#4 queryFactory->Execute() called at [/SiteCopy/dazzlers/includes/functions/admin_access.php:918]
#5 zen_register_admin_page() called at [/SiteCopy/dazzlers/includes/installers/middle_boxes/1_5_3.php:92]
#6 include(/SiteCopy/dazzlers/includes/installers/middle_boxes/1_5_3.php) called at [/SiteCopy/dazzlers/includes/init_includes/init_middle_boxes.php:85]
#7 require_once(/SiteCopy/dazzlers/includes/init_includes/init_middle_boxes.php) called at [/includes/autoload_func.php:37]
#8 require(/includes/autoload_func.php) called at [/SiteCopy/dazzlers/includes/application_top.php:37]
#9 require(/SiteCopy/dazzlers/includes/application_top.php) called at [/SiteCopy/dazzlers/login.php:8]
#10 require(/SiteCopy/dazzlers/login.php) called at [/SiteCopy/dazzlers/index.php:11]
--> PHP Fatal error: 1062:Duplicate entry 'EditableCenterboxesConfig' for key 'page_key' :: INSERT INTO admin_pages
SET page_key = 'EditableCenterboxesConfig',
language_key = 'BOX_TOOLS_EDITABLE_CENTER_BOXES_BOXES_CONFIG',
main_page = 'FILENAME_CONFIGURATION',
page_params = 'gID=33',
menu_key = 'configuration',
display_on_menu = 'Y',
sort_order = 33 ==> (as called by) /SiteCopy/dazzlers/includes/functions/admin_access.php on line 918 <== in /includes/classes/db/mysql/query_factory.php on line 170.

So configure_group 33 has the following data;

configuration_group_id	int(11)	
33
configuration_group_title	varchar(64)	
Editable Center Boxes Config
configuration_group_description	varchar(255)	
Set Editable Center Boxes Configuration Options
sort_order	int(5)	
	
33
visible	int(1)	
	
1

in database configuration there are 13 lines associated to configure_group 33 - they are **all **related to tracking users, there are none relating to middleboxes (e.g. ZEN_CONFIG_SHOW_USER_TRACKING_CATEGORY, CONFIG_USER_TRACKING_TRACK_TYPE_RECORD, USER_TRACKING_WHOIS_URL etc.)

30 Jan 2021, 2:27 AM
#340
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: Editable Home Page Centerboxes [Support]

update

  1. restored the test folder to a point prior to any attempts to install this plugin
  2. removed configuration_table 33 which was a legacy from the 1.5.5f site version (likely unneccesary but did no harm)
  3. installed all plugin files (essentially into a clean site) - used all balihr files unchanged
  4. had to run install.sql twice to get admin/configuration/editable centerboxes to eventually show
  5. ALL configuration settings are showing in database (finally)

current status

  1. admin and site access work
  2. no middleboxes in admin/tools/define pages editor
  3. no box shows on the page
  4. myDEBUG error as below
[30-Jan-2021 12:44:07 Australia/Sydney] Request URI: /SiteCopy/, IP address: 115.166.19.58
#1 constant() called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php:29]
#2 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php) called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php:89]
#3 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php) called at [/SiteCopy/includes/modules/pages/index/main_template_vars.php:232]
#4 require(/SiteCopy/includes/modules/pages/index/main_template_vars.php) called at [/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php:142]
#5 require(/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php) called at [/SiteCopy/index.php:94]
--> PHP Warning: constant(): Couldn't find constant FILENAME_DEFINE_MIDDLEBOX_1 in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 29.

[30-Jan-2021 12:44:07 Australia/Sydney] Request URI: /SiteCopy/, IP address: 115.166.19.58
#1 constant() called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php:40]
#2 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php) called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php:89]
#3 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php) called at [/SiteCopy/includes/modules/pages/index/main_template_vars.php:232]
#4 require(/SiteCopy/includes/modules/pages/index/main_template_vars.php) called at [/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php:142]
#5 require(/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php) called at [/SiteCopy/index.php:94]
--> PHP Warning: constant(): Couldn't find constant BOX_HEADING_MIDDLEBOX1 in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 40.

[30-Jan-2021 12:44:07 Australia/Sydney] Request URI: /SiteCopy/, IP address: 115.166.19.58
#1 require() called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php:42]
#2 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php) called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php:89]
#3 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php) called at [/SiteCopy/includes/modules/pages/index/main_template_vars.php:232]
#4 require(/SiteCopy/includes/modules/pages/index/main_template_vars.php) called at [/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php:142]
#5 require(/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php) called at [/SiteCopy/index.php:94]
--> PHP Warning: require(includes/languages/english/html_includes/.php): failed to open stream: No such file or directory in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 42.

[30-Jan-2021 12:44:07 Australia/Sydney] Request URI: /SiteCopy/, IP address: 115.166.19.58
#1 require() called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php:42]
#2 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php) called at [/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php:89]
#3 require(/SiteCopy/includes/templates/responsive_classic_1/templates/tpl_index_default.php) called at [/SiteCopy/includes/modules/pages/index/main_template_vars.php:232]
#4 require(/SiteCopy/includes/modules/pages/index/main_template_vars.php) called at [/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php:142]
#5 require(/SiteCopy/includes/templates/responsive_classic_1/common/tpl_main_page.php) called at [/SiteCopy/index.php:94]
--> PHP Warning: require(includes/languages/english/html_includes/.php): failed to open stream: No such file or directory in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 42.

[30-Jan-2021 12:44:07 Australia/Sydney] PHP Fatal error: require(): Failed opening required 'includes/languages/english/html_includes/.php' (include_path='.:/opt/alt/php72/usr/share/pear') in /SiteCopy/includes/templates/responsive_classic_1/templates/tpl_middleboxes.php on line 42

So 'includes/languages/english/html_includes/.php' referred to above contains the middlebox data - why it is not opening I cannot fathom.

Any ideas please on how this can be resolved?

thanks,
Mike