Kryptronic Software Support Forum

You are viewing this forum as a guest. Login to an existing account, or create a new account, to reply to topics and to create new topics.

#26 02-16-2011 03:42:39

west4
Member
From: UK
Registered: 04-16-2008
Posts: 639
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Hi,

Anyone got this working with Joomla integration?

Or no of a tweak to get it to work... It nearly works but just shows the first level sub categories only.

Cheers,
Bruce.


I'd rather have a full bottle in front of me, than a full frontal labotomy.

Offline

 

#27 02-16-2011 11:27:17

dh783
Moderator
From: Avondale, Arizona
Registered: 04-06-2005
Posts: 6233
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Was it working before you setup joomla?

You wouldn't have it set to only show the first sub categories? This would be controled by the new field located at System Dashboard > Store > Component > Settings > Catalog Global Displays (if you created it).

John

Offline

 

#28 02-17-2011 03:48:41

west4
Member
From: UK
Registered: 04-16-2008
Posts: 639
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Hi John,

No... I installed ccp7 and joomla together as a complete install so never had a pre joomla version.
I set the 'only show first sub category' yes...but I thought that this setting would only show the main categories plus the first level categories, not just the first categories with no main categories. Anyway it only shows the first first category not all the first categories, hope that was clear...lol.

I think you may have to tweak the setting in one of the joomla scripts in ccp7?

I will test a bit more for you.
the link for the test site is at badgesforschools.com

Cheers,
Bruce.


I'd rather have a full bottle in front of me, than a full frontal labotomy.

Offline

 

#29 02-25-2011 05:13:30

west4
Member
From: UK
Registered: 04-16-2008
Posts: 639
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Hi,

Well this fails with joomla integration enabled, It only shows the first sub menu of the first menu with a sub menu.

Any one got this working? or can help?

Cheers,
Bruce.


I'd rather have a full bottle in front of me, than a full frontal labotomy.

Offline

 

#30 03-22-2011 15:19:46

amdowney
Member
From: UK-Warwickshire
Registered: 09-21-2007
Posts: 507
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

OK so I too previoulsy have been using a javascript pop out menu which is having some confilct in the new CCP7.

I also wrote a small php script which can be called by skin.php to generate a HTML List dynamically with sub categories.

Surely calling this from the skin is better than messing with core files. When updates arrive you'll loose your menu?

Am gonna check what CSS menus I can use this time to create the pop out menu from the included skin code. This will mean less javascipt to call and less tampering with main files...

Offline

 

#31 03-22-2011 19:53:41

vbsaltydog
Member
From: Florida
Registered: 05-02-2005
Posts: 947
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

amdowney wrote:

I also wrote a small php script which can be called by skin.php to generate a HTML List dynamically with sub categories.

You are doing an include of a standalone php script in the skin.php file? If this is the case then it would behave the same as placing the external php code right in the skin.php and since the skin.php files are not overwritten by CCP updates, you would be safe to do this. The only issue with that logic is having the needed info in the CORE_Display object at the time that you run your external php script in order to output your menu.

amdowney wrote:

Surely calling this from the skin is better than messing with core files.

If it can be done from the skin.php file.

amdowney wrote:

When updates arrive you'll loose your menu?

Answered in my first response paragraph.


Latest CCP 7 XMods Available:


Offline

 

#32 03-23-2011 04:46:49

amdowney
Member
From: UK-Warwickshire
Registered: 09-21-2007
Posts: 507
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Am I missing something, why is the CORE_Display required?

I completely bypass the Kryptronic menu output code with the following (in a skin.php include):

Code:

<div class="skin_fenavh">Categories</div>
<br />
<ul id="flyout">
  <?



$site="http://www.agwoodcare.co.uk";

$sql="SELECT * FROM ecom_cat order by sortorder";
$result=mysql_query($sql);               
while($row = mysql_fetch_array($result))
  {
     
  if($row["splashdisp"] == 1) //if a main category
    {
     
     printf("<li><a href=\"%s/ecom-cat/%s.html\"><b>%s</b></a>",$site, $row["id"], $row["name"]); //print main category with SEO enabled
//printf("<li><a href=\"index.php?app=ecom&ns=cat&ref=%s\">%s</a>",$row["id"], $row["name"]); //print main category with SEO disabled
     $list = $row["xcat"];
     if($list != "") //if sub categories is not empty
       {
         $array = explode(',', $list);
         echo"<ul>";
         foreach ($array as $value)
           {
            $value = str_replace (" ", "", $value); //remove spaces
            $sql2="SELECT * FROM ecom_cat where id = '$value' ";
          $result2=mysql_query($sql2);
            $row2 = mysql_fetch_array($result2);
               
            printf("<li><a href=\"%s/ecom-cat/%s.html\"><b>%s</b></a>",$site, $row2["id"], $row2["name"]); //print category with SEO enabled
            //printf("<li><a href=\"index.php?app=ecom&ns=cat&ref=%s\">%s</a>",$row2["id"], $row2["name"]); //print category with SEO disabled
            
            $list2 = $row2["xcat"];           
            if($list2 != "") //if 2nd sub categories is not empty
             {               
              $array2 = explode(',', $list2);
                 echo"<ul>";
              foreach ($array2 as $value)
                {
                $value2 = str_replace (" ", "", $value); //remove spaces
                $sql3="SELECT * FROM ecom_cat where id = '$value2' ";
              $result3=mysql_query($sql3);
                $row3 = mysql_fetch_array($result3);
                printf("<li><a href=\"%s/ecom-cat/%s.html\"><b>%s</b></a></li>\n",$site, $row3["id"], $row3["name"]);  //print category with SEO enabled
            //printf("<li><a href=\"index.php?app=ecom&ns=cat&ref=%s\">%s</a>",$row3["id"], $row3["name"]); //print category with SEO disabled
                }
             echo"</ul>";
            //<li><a href="ecom-cat/ $row["id"] .html"> $row["name"] </a></li>
              }
            echo "</li>";
           }
            
         echo"</ul>";
       }
     echo "</li>";
    }
  }
?>
</ul>

As you can see this directly queries the categories table in the database only displaying the main categories marked in the admin and displaying the subcategories as required.

Then I'm testing cssmenus.co.uk, which means the only other things that needs doing is the adding of a CSS file just for the menu. (I had to remove overflow: hidden; from the all.css file for the left column)

It needs a bit of front end formatting but it works for me!

Last edited by amdowney (03-23-2011 04:53:19)

Offline

 

#33 03-23-2011 04:56:56

vbsaltydog
Member
From: Florida
Registered: 05-02-2005
Posts: 947
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

CORE_Display is not required if you bypass the CCP skinwidgets category function in the skin.php even though skin.php is a part of the CORE_Display class. Your method works if you dont mind combining logic code and presentation code together.


Latest CCP 7 XMods Available:


Offline

 

#34 03-23-2011 05:09:02

vbsaltydog
Member
From: Florida
Registered: 05-02-2005
Posts: 947
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

I currently have a pure CSS flyout menu XMOD under development that can be seen at http://www.onlineskateboardstore.com for anyone that wants one. It should be ready for release in a few days.


Latest CCP 7 XMods Available:


Offline

 

#35 07-18-2011 13:20:46

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Hi VB, I'd like to know more about your CSS flyout menu

Thanks

Offline

 

#36 08-07-2011 12:30:03

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

I used the ideas provided by amdowney above to create a flyout menu and it works nicely.

I had a few issues with a dynamic image slideshow whereby the flyout menu items disappeared behind the slideshow images, but that was cured by setting a higher z-index for the menu.

I have stumbled into another issue regarding viewing the website on a tablet computer.

The one I used was an Android based ASUS eeepad, and because these machines don't do "hover" events in the way a mouse can, the flyout menus are not usable beyond each main category item because as soon as the touch screen detects a touch on the menu (the flyout does appear) but the tablet assumes a link has been clicked and it is activated.

So, based on the above code of  amdowney, the main menu item goes to a listing of all the main categories rather than to the specific category of the menu item.

Can anyone assist making the adjustment required to go to an individual catagory rather than the list of all of them?

Thanks

Offline

 

#37 08-08-2011 08:04:54

jojo
Member
Registered: 05-02-2011
Posts: 25

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

magwa - I'm guessing you mean that when SEO is enabled from amdowney's menu you are getting the problem.

In the three lines where it appears, when SEO is enabled change the lines..

<a href=\"%s/ecom-cat/%s.html\">

to

<a href=\"%s/ecom-catshow/%s.html\">

Offline

 

#38 08-08-2011 16:29:30

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Thanks jojo - I had missed that.

Offline

 

#39 08-12-2011 05:44:43

west4
Member
From: UK
Registered: 04-16-2008
Posts: 639
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Hi,

Anyone got this working with Joomla integration?

Or no of a tweak to get it to work... It nearly works but just shows the first level sub categories only.

Cheers,
Bruce.


I'd rather have a full bottle in front of me, than a full frontal labotomy.

Offline

 

#40 09-01-2011 17:12:52

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

I've run into another problem.

I had amdowney's suggestion working great with default SEO turned on.
but with the HDSEO MOd turned on the menu doesn't pickup the newer rewritten URL's

any suggestions?

Offline

 

#41 09-02-2011 13:37:11

dh783
Moderator
From: Avondale, Arizona
Registered: 04-06-2005
Posts: 6233
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

magwa,

That is because the mod that amdowney has implemented doesn't use the HESEO script in the CORE_Display to build the urls, it building them as standard html links. To get them in HDSEO formate you would either have to hard code the mode to build them that way, or the best way is to use ccp link building which would run the links thru the CORE_Display script and build the links according to ccps settings. This would call for pulling or setting up to use CORE_DIsplay (if not already present) and using $this->link_namespace() to build the links thus using ccp settings on how the url should look.
The original subject of this post uses this method of link building so if you have SEO or the HDSEO mod activated then it will build the url accordingly, if the menu display that vbsaltydog uses this method then it too would build the links according to ccp settings. This is an answer to amdownings question of:

amdowny wrote:

Am I missing something, why is the CORE_Display required?

because with out it, or something like the code in the mod to detect and build the HDSEO urls needed, building the links will be all the same type.

To answer an older question of why mod the core scripts for this type of menu, all I can say is that it was done that way to cut down on the server processing time. Since ccp will run these scripts anyway, why spend the time to build the menu display just to throw it out and start over again, causing more processing and database calls to do what was already or could have been done in the original scripts, yes it might get overwritten in an update but the overall day-to-day processing time is less.
As to the java script process I did it that way because I was spending a great deal of time trying to come up with a total ccs menu that would act the way I wanted it to, it just was easier to find a the java script that I did and use it than to keep spending the time to do the total css style. If someone has a total css version that works like the java style then I will update the original post, but as of yet I haven't seen one, even vbsaltydogs menu as far as I can see from his test site only does one fly-out:

main_menu
          sub_cat1

and not

main_menu
         cat1
                sub_cat1
                       sub_cat1
         cat2

I am not saying that it doesn't work as it works well for the one level that I see, if it does work on three levels then I will apologize but so far I haven't seen it do more than the one level on any browser that I have tested it on. The code for amdowneys looks like it would work well too but since I don't see any code for more than what would build the main_menu and one sub_cat (the main menu items would contain the first level category information or it's subcategories but nothing futhur). In the original title of this posting I tried to convay that the original mod discussed would drill down three levels into any main category and its subcategories, meaning as an example on my site I have a main category of Audio that has a subcategory of Shure Microphones which has a subcategory of Shure Wireless Systems which has a subcategory of Shure PG Series which then displays the products to select form. This gives the menu layout look of

Audio
     Shure Micriophones
              Shure Wired Microphones
              Shure Wiresless Systems
                       Shure PG Series
                       Shure PGX Series
                       Shure SLX Series
                       etc...(3 more subcats)
               Accessories
     etc...(more subcategories of the main)
next main category

this allows one to get to the Shure PG Series category in one click in stead of the oringal 4 need to reach that category using the default ccp menu, thus making it simpler for the customer but allows me to be more specific in categorizing items.

John

Last edited by dh783 (09-02-2011 13:38:58)

Offline

 

#42 09-02-2011 16:42:03

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

John, thanks for your detailed reply. It has given me food for thought.

I liked the menu amdowney suggested because it was very easy to put together, but I must admit the deeper levels yours goes to is very appealing, although I'm not so keen on adjusting anything in the core that might get overwritten.

Overall I'm reaching the stage of simply not bothering with rewriting seo url's beyond the default kryptronic seo setup as the huge amount of work involved with HDSEO mod seems disproportionate to any benefit.

Offline

 

#43 09-03-2011 08:20:21

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

John, would I be right in thinking your menu system would pickup HDSEO urls?

If that is correct I'll have a go at it.
I'm sure if I make careful notes any updates overwriting the mod can be reapplied later.

Offline

 

#44 09-03-2011 08:39:06

dh783
Moderator
From: Avondale, Arizona
Registered: 04-06-2005
Posts: 6233
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Yes it does, but just because the URL is in the HDSEO formate it will not change the display name for menu item, that is still what is in the categories display name.

John

Offline

 

#45 09-03-2011 09:55:11

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Thanks John - I will give it a go and see how it turns out.

Offline

 

#46 09-03-2011 17:14:22

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

John

Thanks to your detailed instructions (very important for me) it has taken me less than an hour to setup your menu on my site. Everything seems good so far.

May I offer you my sincere thanks for your efforts and willingness to share.

Offline

 

#47 09-10-2011 05:13:29

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

John

I've just realised that my minicart disappeared.
It returns when I undo the mod in skinwidgets.php by revertying to original file backup.

Any ideas?

Offline

 

#48 09-10-2011 05:23:13

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

John

Somehow I had completely missed out the * Function: minicart * section in the newer skinwidgets.php

A comparison between the current live file and the backup original threw some light on things.

All appears well now.

Offline

 

#49 09-21-2011 04:06:07

magwa
Member
Registered: 09-22-2007
Posts: 321

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

John, is there a way to amend this so I could have short menu names and long page titles?

For instance, if my page title (picked up from display name) was * Widget *, I would see * Widget * as the corresponding menu item.

However, I would like the menu item to remain as * Widget * but have my page title as * Widget for Birthdays or Anniversaries * - this longer title would be messy as a menu item.

Offline

 

#50 09-21-2011 07:47:10

dh783
Moderator
From: Avondale, Arizona
Registered: 04-06-2005
Posts: 6233
Website

Re: Mod::Dynamic FrontEnd Menu with 3 Sub-Categories Display for ccp7.

Check the forum for changing the meta title and or meta name, I believe that I posted one a long time ago, but it is possible as I have my site doing just that currently.

Look at this post .

John

Last edited by dh783 (09-21-2011 07:52:07)

Offline

 

Board footer