Jump to content
Latest News: (loading..)
Sign in to follow this  
iankil

[Contribution] Mindsparx admin

Recommended Posts

The requested URL /store/admin/FILENAME_STATS_LOW_STOCK was not found on this server.

 

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request

 

 

 

 

Any help here?!?!?

Share this post


Link to post
Share on other sites

anyone else having problems with administrators.php ???

 

im getting the following error on new install;

 

 

 

1146 - Table 'db285264814.TABLE_ADMINISTRATORS' doesn't exist

 

select id, user_name from TABLE_ADMINISTRATORS order by user_name

 

[TEP STOP]

 

any help please?

Share this post


Link to post
Share on other sites
anyone else having problems with administrators.php ???

 

im getting the following error on new install;

 

 

 

1146 - Table 'db285264814.TABLE_ADMINISTRATORS' doesn't exist

 

select id, user_name from TABLE_ADMINISTRATORS order by user_name

 

[TEP STOP]

 

any help please?

 

only happens when i try to use administrators.php everything else seems fine.

 

 

also the "log out" menu item is missing...

Share this post


Link to post
Share on other sites
only happens when i try to use administrators.php everything else seems fine.

 

 

also the "log out" menu item is missing...

 

 

administrators problem fixed now.

 

still cant get logoff to work but never mind....

 

is it possible to change the styling of the "order totals" box??

 

from;

Your Order Total is:

Pending: £160.00, Processing: £55.00, Delivered: £0.00, Please Call: £0.00, On Hold: £0.00, On Order: £0.00, Today: £106.00

 

to:

Your Order Total is:

Pending: £160.00,

Processing: £55.00,

Delivered: £0.00,

Please Call: £0.00,

On Hold: £0.00,

On Order: £0.00,

Today: £106.00

 

?? any help appreciated.!

Share this post


Link to post
Share on other sites

Hi

I am new to oscommerce and I liked the contribution of mindsparx admin, I have donloaded the latest version which i think only works for oscommerce version 3 , but at the moment i have version 2.2 , because when I looked to the install instraction which i quote " Mindsparx Admin version 3.0 for OSCommerce v3.0 Alpha created by Janne.kilpio @ mindsparx.org

 

Mindsparx_admin was originally created for oscommerce v2.2 RC 2a, and for those who is used to the look of mindsparx_admin, here is one for v3.0 Alpha

 

 

The install is easy, just follow the instructions below

 

 

in admin/index.php

 

look for:

require('templates/default.php');

 

change that to:

 

require('templates/mindsparx_admin.php');

 

 

 

 

Upload all new files and you are done ;)

 

there is a support forum for mindsparx_admin 2.1 here, http://forums.oscommerce.com/index.php?showtopic=324354

 

 

/Janne.K

 

 

Need a professional oscommerce template? visit mindsparx.org

"

 

so I looked for the: require('templates/default.php'); in admin/index.php BUT I cant find it also for the 2nd step I could n't find the required phrace.

 

so I searched for old version of mindsparx Admin and found one , whichnisnunder this link : http://addons.oscommerce.com/info/6440 and the date is 22 Dec 2008 .

please advice me if what I am doing is correct or can you tell me where I got it wrong.?

 

if what I am doing is correct then realy I find it very hard to implement this step wich is the last one which is about "ading your own links "

 

"

Adding your own links

 

All links is moved to the header and if you need to add your own it has to be rewriten, for examle when you install a new module

and it requires a link in for example catalog.php like this (Featured products)

 

'<a href="' . tep_href_link(FILENAME_FEATURED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_F=hange it to this:

<a href="<?php echo tep_href_link(FILENAME_FEATURED, 'selected_box=catalog')?>"><?php echo BOX_CATALOG_FEATURED_PRODUCTS ?></a>

 

Note! 'selected_box=catalog' can be what ever the link requires

 

 

 

And links that´s going in to the configuration drop needs the id that´s going in to the database

for example (Featured products) the database looks like this:

 

**********************

INSERT INTO configuration_group (configuration_group_id, configuration_group_title, configuration_group_description,

sort_order, visible) values ('39','Featured', 'Featured Products Display', '339', '1');

**********************

 

note the value "39" that´s what we are looking for, now create your configuration link for Featured products like this:

 

<a href="<?php echo tep_href_link(FILENAME_CONFIGURATION, 'gID=39&selected_box=configuration')?>"><?php echo BOX_CATALOG_FEATURED_PRODUCTS ?></a>

 

 

Now add your links in your admin header and in what ever dropdown you need them in ;)

as you can see it requires that you have basic understanding in doing this or it wont work.

 

 

 

***********************************************************************

 

Here is some usefull header links for various contributions:

 

 

Order editor:

<a href="<?php echo tep_href_link(FILENAME_CONFIGURATION, 'gID=72&selected_box=configuration')?>"><?php echo BOX_CONFIGURATION_ORDER_EDITOR?></a>

 

 

Optional related products

For config dropdown

<a href="<?php echo tep_href_link(FILENAME_CONFIGURATION, 'gID=6125&selected_box=configuration')?>"><?php echo BOX_CATALOG_CATEGORIES_RELATED_PRODUCTS?></a>

For other dropdown

<a href="<?php echo tep_href_link(FILENAME_RELATED_PRODUCTS, 'selected_box=catalog')?>"><?php echo BOX_CATALOG_CATEGORIES_RELATED_PRODUCTS ?></a>

 

 

Featured products

For config dropdown

<a href="<?php echo tep_href_link(FILENAME_CONFIGURATION, 'gID=39&selected_box=configuration')?>"><?php echo BOX_CATALOG_FEATURED_PRODUCTS ?></a>

For other dropdown

<a href="<?php echo tep_href_link(FILENAME_FEATURED, 'selected_box=catalog')?>"><?php echo BOX_CATALOG_FEATURED_PRODUCTS ?></a>

 

 

Star product

<a href="<?php echo tep_href_link(FILENAME_STAR_PRODUCT, 'selected_box=catalog')?>"> <?php echo STAR_PRODUCT ?> </a>

 

 

Products extra categories

<a href="<?php echo tep_href_link(FILENAME_CATEGORIES_EXTRA, 'selected_box=tools')?>"><?php echo BOX_CATALOG_CATEGORIES_EXTRA_DESCRIPTION ?></a>

 

 

Extra infopages

<a href="<?php echo tep_href_link(FILENAME_PAGE_MANAGER, 'selected_box=tools')?>"><?php echo BOX_TOOLS_PAGE_MANAGER ?></a>

 

 

 

 

I think that´s all

your admin´s been officially pimped! "

 

 

please help me with some hints how to implements the above step because is not clear for me how to implement it

Share this post


Link to post
Share on other sites

Maybe it's better to use this version if you have version 2.2 of your shop. I had no problems installing this version

Edited by Clau123

Share this post


Link to post
Share on other sites

Sorry for my bad speack english. Habitually, I speack french.

 

I used the version of ReyBlack for MindSparx admin.

 

My problem is the following one.

I try to install the contribution " Store Mode V1.3 ". The problem it is, that after the installation, I do not manage to see the space of the configuration of the " Store mode " in the admin.

Here is codes them modifying the admin in mysql and configuration.php:

 

# NEW RECORDS FOR: STORE MODE ADDON
# THE CONFIGURATION GROUP SORT ORDER MAY BE CHANGED
INSERT INTO configuration_group (configuration_group_id, configuration_group_title, configuration_group_description, sort_order, visible) VALUES (1501, 'Store Mode', 'Open, Closed, or Maintenance Mode', '30', '1');
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added) VALUES ('Current Store Mode', 'STORE_MODE', 'Open', '<b>Open</b>: fully functional store<br><b>Closed</b>: checkout is disabled<br><b>Maintenance</b>: redirected to maintenance page', '1501', '1', 'tep_cfg_select_option(array(\'Open\', \'Closed\', \'Maintenance\'), ', now(), now());
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added) VALUES ('Offline Warning', 'OFFLINE_WARNING', 'false', 'If enabled when the store is in Open mode, a message will display at the top of each catalog page warning your customers that the store will be going offline. This message is configurable in your language file.', '1501', '2', 'tep_cfg_select_option(array(\'true\', \'false\'), ', now(), now());
INSERT INTO configuration VALUES (NULL, 'Store Offline (Date/Time)', 'OFFLINE_DATE_TIME', 'Date and Time', 'Set the date and time which you desire your store to be offline [closed or maintenance].<br><br>mm/dd/yyyy at hh:mm am/pm<br>', 1501, 3, now(), now(), NULL, NULL);
INSERT INTO configuration VALUES (NULL, 'Store Online (Date/Time)', 'ONLINE_DATE_TIME', 'Date and Time', 'Set the date and time which you desire your store to return online [open].<br><br>mm/dd/yyyy at hh:mm am/pm<br>', 1501, 4, now(), now(), NULL, NULL);
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added) VALUES ('Maintenance Page', 'MAINTENANCE_FILENAME', 'index_maintenance.php', 'This is the webpage to which users will be redirected while the store is offline for maintenance.<br><br>filename.php or filename.html<br>', '1501', '5', now(), now());
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added, use_function) VALUES ('Maintenance Mode: Testing', 'MAINTENANCE_TESTING', 'false', 'This temporarily disables the automatic ip detection so that you may view the maintenance page from the customers point of view for testing purposes.', '1501', '6', 'tep_cfg_select_option(array(\'true\', \'false\'), ', now(), now(), NULL);
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added, use_function) VALUES ('Maintenance Mode: Hide Header', 'HEADER_OFF', 'false', 'This hides the header when displaying the maintenance page.<br><br>true = hide | false = show', '1501', '7', 'tep_cfg_select_option(array(\'true\', \'false\'), ', now(), now(), NULL);
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added, use_function) VALUES ('Maintenance Mode: Hide Column Left', 'COLUMN_LEFT_OFF', 'false', 'This hides the left column when displaying the maintenance page.<br><br>true = hide | false = show', '1501', '8', 'tep_cfg_select_option(array(\'true\', \'false\'), ', now(), now(), NULL);
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added, use_function) VALUES ('Maintenance Mode: Hide Column Right', 'COLUMN_RIGHT_OFF', 'false', 'This hides the right column when displaying the maintenance page.<br><br>true = hide | false = show', '1501', '9', 'tep_cfg_select_option(array(\'true\', \'false\'), ', now(), now(), NULL);
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added, use_function) VALUES ('Maintenance Mode: Hide Footer', 'FOOTER_OFF', 'false', 'This hides the footer when displaying the maintenance page.<br><br>true = hide | false = show', '1501', '10', 'tep_cfg_select_option(array(\'true\', \'false\'), ', now(), now(), NULL);
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, last_modified, date_added, use_function) VALUES ('Maintenance Mode: Hide Prices', 'PRICES_OFF', 'false', 'This hides the product prices when displaying the maintenance page.<br><br>true = hide | false = show', '1501', '11', 'tep_cfg_select_option(array(\'true\', \'false\'), ', now(), now(), NULL);
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added) VALUES ('Admin IP Address', 'OFFLINE_IP_ADDRESS', 'Your Current IP', 'This IP address will be able to access the site while everyone else is redirected to the maintenance page.<br><br>Though your current ip address should be detected automatically, you can discover it at <b>www.find-ip-address.org</b><br>', '1501', '12', now(), now());

 

**********
* STEP 9 *
**********

in catalog/admin/configuration.php

Find this:

 if (tep_not_null($action)) {
switch ($action) {
  case 'save':
	$configuration_value = tep_db_prepare_input($HTTP_POST_VARS['configuration_value']);
	$cID = tep_db_prepare_input($HTTP_GET_VARS['cID']);

	tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = '" . tep_db_input($configuration_value) . "', last_modified = now() where configuration_id = '" . (int)$cID . "'");

	tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gID=' . $HTTP_GET_VARS['gID'] . '&cID=' . $cID));
	break;
}
 }

REPLACE with this:

// BOF: Store Mode
 if (tep_not_null($action)) {
switch ($action) {
  case 'save':
	$configuration_value = tep_db_prepare_input($HTTP_POST_VARS['configuration_value']);
	$cID = tep_db_prepare_input($HTTP_GET_VARS['cID']);

	tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = '" . tep_db_input($configuration_value) . "', last_modified = now() where configuration_id = '" . (int)$cID . "'");

	// set the OFFLINE_WARNING to false if STORE_MODE is set to Closed or Maintenance
	if ( (OFFLINE_WARNING == 'true') && (STORE_MODE != 'Open') ) {
	  tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = 'false', last_modified = '" . NOW . "' where configuration_key = 'OFFLINE_WARNING'");
	}

	tep_redirect(tep_href_link(FILENAME_CONFIGURATION, 'gID=' . $HTTP_GET_VARS['gID'] . '&cID=' . $cID));
	break;
}
 }

// Add for getting the actual IP (when not a fixed ip)
 if (MAINTENANCE_TESTING == 'true') {
$IP_Admin = 'testing';
tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = '" . $IP_Admin . "' where configuration_key = 'OFFLINE_IP_ADDRESS'");
 } else {
if ($HTTP_GET_VARS['gID'] == '1501') {
  $IP_Admin = tep_db_prepare_input(getenv(REMOTE_ADDR));
  $IP_Admin_DB_query = tep_db_query ("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'OFFLINE_IP_ADDRESS'");
  $IP_Admin_DB = tep_db_fetch_array($IP_Admin_DB_query);
  if ($IP_Admin_DB['configuration_value'] != $IP_Admin) {
	tep_db_query("update " . TABLE_CONFIGURATION . " set configuration_value = '" . $IP_Admin . "' where configuration_key = 'OFFLINE_IP_ADDRESS'");
  }
}
 }
// EOF: Store Mode


** NOTE: The first block of code will automaticly set Admin->Configuration->Store Mode->Offline Warning
	 to 'false' after you set the Admin->Configuration->Current Store Mode to "Closed" or "Maintenance"
	 This way you will NOT forget to do it yourself and you'll avoid customer confusion.

** NOTE: If you don't have a fixed IP number, the second block of code will get
	 the actual IP of your admin computer and write it to the database.

 

Thank you for your help and for your understanding.

Share this post


Link to post
Share on other sites

Great contribution.

 

I am having problems with the drop down boxes working when on ssl. Seems to work ok in i.e. 7 but not in i.e 8. Anybody else noticed this?

 

Webpage error details

 

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; GTB6; InfoPath.1; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)

Timestamp: Thu, 28 May 2009 11:29:49 UTC

 

 

Message: Object expected

Line: 115

Char: 2

Code: 0

URI: hxxps://blabla/admin/mindspar...ddsmoothmenu.js

 

In fact ive just noticed this problem when trying to insert a codebox on the forums with invalid argument errors! Maybe its the new buggy ie thats the problem.

 

Rich

Edited by smithy32

Share this post


Link to post
Share on other sites

I am working with the mindsparx admin for a couple of weeks now, and I'm very satisfied with the contrib.

 

I only have 1 small problem that I can't solve:

 

I have almost 2000 products in my store and some of them show up on multiple categories. When I try to run some reports that show all the products, like category product foldout list, then the lower part of the list is not visible anymore in Internet Explorer, it just dissapears out of the Mindsparc block. If there is a button below, it's also gone.

 

At the same time I get a few or a lot of black stripes under the header

 

The strange thing is that on my Imac in Safari, I don't have this problem. It just shows the complete list and missing buttons and no black stripes.

 

But I'm working more on my Windows computer with my sites than on my Mac, so I love to solve this thing.

 

Do you know what I can do to fix this?

Share this post


Link to post
Share on other sites

Hello All,

Sorry that i haven’t answered any questions for a while but i have been busy with other projects, but the problem with disappearing text in explorer is probably a simple fix,

Try to delete the height (height="800px") for the table in header.php i think that’s the problem.

/Janne.K


My contributions

Mindsparx admin for 2.2

Mindsparx admin for 2.3

Mindsparx admin for 3.0

Mindsparx specials 2.2

Starproduct pimped for 2.2

Starproduct pimped for 2.3

Mindsparx template osc Sport 2.2

Mindsparx template Horizon 2.3

+ a few more...

Share this post


Link to post
Share on other sites

Hello Janne,

 

I made it height="" en that is working. Thanks. I can use a lot more of the contribs I build in now.

 

Claudia

Share this post


Link to post
Share on other sites

Hi Janne,

 

I did an upgrade to version 2.1 but now I have the following missing gif buttons in the error log for both bling and blue templates:-

 

buttons/english/button_customer_exclusions.gif

buttons/english/button_shipping_zone_exclusions.gif

buttons/english/button_category_exclusions.gif

buttons/english/button_manufacturer_exclusions.gif

buttons/english/button_product_exclusions.gif

buttons/english/button_new_coupon.gif

buttons/english/button_new_testimonial.gif

 

I used the PSD files to try and create them but I don't have the font that you are using and no matter what I try, I can't get the buttons to look like your originals. They either end up too big or too tiny. Perhaps my skills with PS is seriously lacking.

 

Could you be kind enough to make them and upload it here for the rest of us, please?

 

Thank you kindly.

Share this post


Link to post
Share on other sites

Hi Janne,

 

Forgot to add that I am also seeing missing file in admin/includes/stylesheet.

 

Now I know that I have rename it to styleshhet_old.css following your installation instruction so, should I be getting this error?

 

Thanks once again.

Share this post


Link to post
Share on other sites

Hello Janne

 

Firstly, let me tell you - if there was such a thing like on OSC-OSCAR ... you'd need to be the first to receive it and I'd like to hand it over personally.

 

A great contribution and an even greater Admin-Panel !!! Thanks a ... times (feel free to add the number you like) :)

 

Janne, I face the same issue as lyonsperf. I have installed your latest 2.1 version though. I looked but I can't find the guide on how to add to the menu and crate sub-menus. For instance, POLL - usually needs its one menu and has two sub-menus, now it doesn't appear, however.

 

Again, thanks for this wonderful admin panel (I like it better than the store front now - lol)

 

Best regards

 

 

 

hello

 

lyonsperf,

 

i liked the idea of submenus so i changed the contribution and installed a new dropdown menu that supports multi levels...

So instead of adding more dropdowns you can add them as submenues and save some space.

 

For those who has installed 2.0 or Stephans fantastic theme, i have added upgrade instructions.

 

i havn't updated the demo yet but here is a picture of what it can do.

 

img1.gif

 

There is a short guide on how to add submenus in the new download, and the code in admin/boxes/ has instructions on how to create subs.

 

I hope you find this usefull, if not.. use 2.0 ;)

 

 

/Janne.K

Share this post


Link to post
Share on other sites

Haha, where can i pick up my Oscar? i really want one...

 

ivyfleur, no need to rename the styleshhet.css its just done so you know that it has been moved to the new folder. And about the buttons, try to enable/disable the button function in the header.php file and see if its still there.

 

I´m abit bussy at the moment but i´ll try to add the buttons asap. The font used for the buttons is a font that most of you have , "Tahoma" dont have any smooth or similar just plain text like the screen below

 

screen1.jpg

 

 

Wemseo

 

The new menu that allows you to create submenus is a bit weird in Firefox so i recommend all new users to install the 2.0 version

 

But if you really need subs then 2.1 is the one to use. I have explained in a previous page how to ad them, have a look here http://forums.oscommerce.com/index.php?sho...24354&st=80

To add submenues is complicated, and i couldnt find a easy way to do this... but ones you know how to add them ist easy :)

 

 

/Janne.K


My contributions

Mindsparx admin for 2.2

Mindsparx admin for 2.3

Mindsparx admin for 3.0

Mindsparx specials 2.2

Starproduct pimped for 2.2

Starproduct pimped for 2.3

Mindsparx template osc Sport 2.2

Mindsparx template Horizon 2.3

+ a few more...

Share this post


Link to post
Share on other sites

Hi Janne.K,

 

Problems solved. Once I saw your PSD layout image above, I managed to create all those missing buttons. All errors are now gone.

 

Once again thanks so much.

 

Regards.

Share this post


Link to post
Share on other sites

Thank you so much for a wonderful conrtibution.

 

I'm not sure if this is an issue with the package or not. But I installed your contribution on first. works great. Then I attempted to install contribution "Unique Order Number." To my surprise the orders don't show up in my admin panel when viewing orders that customers just purchased. But the funny thing is that they do show up in my database with their unqiue order id's. Any thoughts on how I can bring this to light?

 

kenz

Share this post


Link to post
Share on other sites
Thank you so much for a wonderful conrtibution.

 

I'm not sure if this is an issue with the package or not. But I installed your contribution on first. works great. Then I attempted to install contribution "Unique Order Number." To my surprise the orders don't show up in my admin panel when viewing orders that customers just purchased. But the funny thing is that they do show up in my database with their unqiue order id's. Any thoughts on how I can bring this to light?

 

kenz

 

 

It looks like that contribution requires the editing of orders.php and only asks me to replace every int)$oID to $oID, which is what i did. but now, no orders show up on orders.php

I only have order editor as the other contribution installed.

 

kenz

Share this post


Link to post
Share on other sites
It looks like that contribution requires the editing of orders.php and only asks me to replace every int)$oID to $oID, which is what i did. but now, no orders show up on orders.php

I only have order editor as the other contribution installed.

 

kenz

 

 

I even followed the addition guide to replace the (int)$oID found on index.php and still no luck. please help!

Share this post


Link to post
Share on other sites
I even followed the addition guide to replace the (int)$oID found on index.php and still no luck. please help!

 

Found my mistake - didn't install database stuff correctly - my bad

Share this post


Link to post
Share on other sites

Hi,

 

I install de contribuition and seens to work well. Only the log out don't show and the Administratos bottom don't work.

 

When I go do admin page it never shows the login menu? What I need to do?

 

Regards,

Share this post


Link to post
Share on other sites

:(Sorry,

 

I have no clue how it could have worked out for you. I tried several times, followed step by step and it just never worked

 

here is my "catalog.php" code

<?php
/*
 $Id: catalog.php 1739 2007-12-20 00:52:16Z hpdl $

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2002 osCommerce

 Released under the GNU General Public License
*/
?>
<!-- catalog //-->

<?php
 $heading = array();
 $contents = array();

 $heading[] = array('text'  => BOX_HEADING_CATALOG,
				 'link'  => tep_href_link(FILENAME_CATEGORIES, 'selected_box=catalog'));
 /*This is for your subcategories. If you are installing a contribution and want the menu item to show up as a submenu in your navigationbar, just add your submenu link here. for example, if you install a contribution like header tags SEO that requires a new link in the header bar or your old column left, then you can add it in a existing box like "tools" and instead of adding links to the main links ($contents[]) below, just add them in $catalogSub1 or $catalogSub2 etc...

Then you need to add the variable to the main links ($contents[]) and its done like this:
Choose what link you want your submeny to appare after and add for example $catalogSub1. (note the dot after the variable) after any '</a>' . like this:

'<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a>' .$subcategory1. 
*/

  /*subcategories start 
	you can create as many subs you need, just copy the code below and change $catalogSub1 to $catalogSub2 etc...*/
 $catalogSub1= '</li><li><a class="menuBoxContentLink" href="#">'.BOX_HEADING_HEADER_TAGS_SEO.'</a>
	<ul>
		<li><a href="' . tep_href_link(FILENAME_HEADER_TAGS_SEO, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_HEADER_TAGS_ADD_A_PAGE . '</a></li>
		<li><a href="' . tep_href_link(FILENAME_HEADER_TAGS_FILL_TAGS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_HEADER_TAGS_FILL_TAGS . '</a></li>
		<li><a href="' . tep_href_link(FILENAME_HEADER_TAGS_TEST, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_HEADER_TAGS_TEST . '</a></li>	  
	</ul>
</li><li>';
/*	if you want to create deeper submenus just add the code below after any </li> above and you will have a sub menu in your submenu

<li><a class="menuBoxContentLink" href="#">deeper category</a>
	<ul>
		<li><a href="#" class="menuBoxContentLink">deep sub1</a>				</li>
	</ul>
</li>
 subcategories end*/

//  if ($selected_box == 'catalog') {

// Add your old links here start
$contents[] = array('text'  => '<a href="' . tep_href_link(FILENAME_CATEGORIES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS . '</a>' .
							   '<a href="' . tep_href_link('easypopulate.php', '', 'NONSSL') . '" class="menuBoxContentLink">Easy Populate</a>' .
							   '<a href="' . tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS_ATTRIBUTES . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_MANUFACTURERS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_MANUFACTURERS . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_REVIEWS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_REVIEWS . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_SPECIALS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_SPECIALS . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_DEFINE_MAINPAGE, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_DEFINE_MAINPAGE . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a>');
// Add your old links here end

 // }

 //$box = new box;
// echo $box->menuBox($heading, $contents);

 foreach($contents as $value) {	  
  echo '<li>'.$value['text'].'</li>';
}
?>

<!-- catalog_eof //-->

 

No matter whether I just add another box as another subcategory, or I try to create a "deeper" (second level) category, I just don't get it done. ... Let's say - e.g. I have a "Polls" box and that is the polls.php

<!-- polls //-->
	  <tr>
		<td>
<?php
 $heading = array();
 $contents = array();

 $heading[] = array('align' => 'left',
						   'text'  => BOX_HEADING_POLLS,
						   'link'  => tep_href_link(FILENAME_POLLS, tep_get_all_get_params(array('selected_box')) . 'selected_box=polls') );

 if ($selected_box == 'polls') {
$contents[] = array('align' => 'left',
							 'text'  => '<a href="' . tep_href_link(FILENAME_POLLS, 'action=config', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_POLLS_CONFIG . '</a><BR><a href="' . tep_href_link(FILENAME_POLLS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_POLLS_POLLS . '</a>');

}
 $box = new box;
 echo $box->menuBox($heading, $contents);
?>
		</td>
	  </tr>
<!-- polls-eof //-->

 

How could I create a subcategory for the poll (alternatively, add a subcategory and have the poll as a "DEEPER" [second level] category then?

 

Thanks

 

 

 

Wooow! :D

 

Its working!

 

Now I understand!

 

Many thanx for your help!

 

lol

 

Cheers, Acid

Share this post


Link to post
Share on other sites

Hmm ...

 

It seams I'm definitely missing something because I have no /admin/boxes/ at all?!?!? Any idea how and where I can get my hands on the missing directory?

 

Thanks

 

 

 

 

Hi!

 

Sorry about that but my word understandig in English is not the best !

I dont understand all content of the guide.

I cant make corectly working submenus.

 

If you can please put here one example box code wich have 1-2 submenu.

Maybe I can understand that fast when I see the example.

 

Thank you!

 

Sorry for my English....

 

 

Cheers, Acid

Share this post


Link to post
Share on other sites

OK ... I'm almost there

I got the "deeper sub-menu working..., the only thing is - I have a Double-Up on the link (the red arrow in the picture shows the double-up)

SUBMENU.gif

 

and here is my code ...

<?php
/*
 $Id: tools.php 1739 2007-12-20 00:52:16Z hpdl $

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2002 osCommerce

 Released under the GNU General Public License
*/
?>
<!-- tools //-->

<?php
 $heading = array();
 $contents = array();

 $heading[] = array('text'  => BOX_HEADING_TOOLS,
				 'link'  => tep_href_link(FILENAME_BACKUP, 'selected_box=tools'));
 /*This is for your subcategories. If you are installing a contribution and want the menu item to show up as a submenu in your navigationbar, just add your submenu link here. for example, if you install a contribution like header tags SEO that requires a new link in the header bar or your old column left, then you can add it in a existing box like "tools" and instead of adding links to the main links ($contents[]) below, just add them in $catalogSub1 or $catalogSub2 etc...

Then you need to add the variable to the main links ($contents[]) and its done like this:
Choose what link you want your submeny to appare after and add for example $catalogSub1. (note the dot after the variable) after any '</a>' . like this:

'<a href="' . tep_href_link(FILENAME_PRODUCTS_EXPECTED, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_PRODUCTS_EXPECTED . '</a>' .$subcategory1. 
*/

  /*subcategories start 
	you can create as many subs you need, just copy the code below and change $catalogSub1 to $catalogSub2 etc...*/
 $toolsSub1= '</li><li><a class="menuBoxContentLink" href="#">'.BOX_HEADING_HEADER_TAGS_SEO.'</a>
	<ul>
		<li><a href="' . tep_href_link(FILENAME_HEADER_TAGS_SEO, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_HEADER_TAGS_ADD_A_PAGE . '</a></li>
		<li><a href="' . tep_href_link(FILENAME_HEADER_TAGS_FILL_TAGS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_HEADER_TAGS_FILL_TAGS . '</a></li>
		<li><a href="' . tep_href_link(FILENAME_HEADER_TAGS_TEST, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_HEADER_TAGS_TEST . '</a></li>
	</ul>
</li><li>';

$toolsSub2= '</li><li><a class="menuBoxContentLink" href="#">'.POLLS.'</a>
				<ul>
					<li><a href="' . tep_href_link(FILENAME_POLLS, 'action=config', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_POLLS_CONFIG . '</a></li>
					<li><a href="' . tep_href_link(FILENAME_POLLS, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_POLLS_POLLS . '</a></li>
				</ul>
			</li><li>';

/*	if you want to create deeper submenus just add the code below after any </li> above and you will have a sub menu in your submenu

<li><a class="menuBoxContentLink" href="#">deeper category</a>
	<ul>
		<li><a href="#" class="menuBoxContentLink">deep sub1</a>				</li>
	</ul>
</li>
 subcategories end*/

 // if ($selected_box == 'tools') {

  // Add your old links here start
$contents[] = array('text'  => '<a href="' . tep_href_link(FILENAME_BACKUP) . '" class="menuBoxContentLink">' . BOX_TOOLS_BACKUP . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_BANNER_MANAGER) . '" class="menuBoxContentLink">' . BOX_TOOLS_BANNER_MANAGER . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_CACHE) . '" class="menuBoxContentLink">' . BOX_TOOLS_CACHE . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_DEFINE_LANGUAGE) . '" class="menuBoxContentLink">' . BOX_TOOLS_DEFINE_LANGUAGE . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_PAGE_MANAGER) . '" class="menuBoxContentLink">' . BOX_TOOLS_PAGE_MANAGER . '</a>' .
			   '<a href="' . tep_href_link(FILENAME_FILE_MANAGER) . '" class="menuBoxContentLink">' . BOX_TOOLS_FILE_MANAGER . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_MAIL) . '" class="menuBoxContentLink">' . BOX_TOOLS_MAIL . '</a>' .

			   '<a href="' . tep_href_link(FILENAME_POLLS) . '" class="menuBoxContentLink">' . POLLS . '</a>' . $toolsSub2. 

							   '<a href="' . tep_href_link(FILENAME_SEO_ASSISTANT) . '" class="menuBoxContentLink">' . BOX_TOOLS_SEO_ASSISTANT . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_NEWSLETTERS) . '" class="menuBoxContentLink">' . BOX_TOOLS_NEWSLETTER_MANAGER . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_SERVER_INFO) . '" class="menuBoxContentLink">' . BOX_TOOLS_SERVER_INFO . '</a>' .
							   '<a href="' . tep_href_link(FILENAME_WHOS_ONLINE) . '" class="menuBoxContentLink">' . BOX_TOOLS_WHOS_ONLINE . '</a>');	  
  // Add your old links here end


// }

// $box = new box;
// echo $box->menuBox($heading, $contents);


foreach($contents as $value) {	  
  echo '<li>'.$value['text'].'</li>';
}
?>

<!-- tools_eof //-->

 

Could I get a last push please, to help me iron it out? :rolleyes:

THANK you

 

PS: I'm still not sure if I really miss a part of the directory or was /admin/boxes/ just a typo?

 

 

 

Hmm ...

 

It seams I'm definitely missing something because I have no /admin/boxes/ at all?!?!? Any idea how and where I can get my hands on the missing directory?

 

Thanks

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×